get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/1241515/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 1241515,
    "url": "http://patchwork.ozlabs.org/api/patches/1241515/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/buildroot/patch/20200220160119.3407-1-patrick.havelange@essensium.com/",
    "project": {
        "id": 27,
        "url": "http://patchwork.ozlabs.org/api/projects/27/?format=api",
        "name": "Buildroot development",
        "link_name": "buildroot",
        "list_id": "buildroot.buildroot.org",
        "list_email": "buildroot@buildroot.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20200220160119.3407-1-patrick.havelange@essensium.com>",
    "list_archive_url": null,
    "date": "2020-02-20T16:01:10",
    "name": "[v3,01/10] package/pkg-cargo.mk: Introduce the cargo package infrastructure.",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "f8cb8e2e915138c2bcb1198453c7de08a0e13fbe",
    "submitter": {
        "id": 75424,
        "url": "http://patchwork.ozlabs.org/api/people/75424/?format=api",
        "name": "Patrick Havelange",
        "email": "patrick.havelange@essensium.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/buildroot/patch/20200220160119.3407-1-patrick.havelange@essensium.com/mbox/",
    "series": [
        {
            "id": 159771,
            "url": "http://patchwork.ozlabs.org/api/series/159771/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/buildroot/list/?series=159771",
            "date": "2020-02-20T16:01:10",
            "name": "[v3,01/10] package/pkg-cargo.mk: Introduce the cargo package infrastructure.",
            "version": 3,
            "mbox": "http://patchwork.ozlabs.org/series/159771/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/1241515/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/1241515/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<buildroot-bounces@busybox.net>",
        "X-Original-To": [
            "incoming-buildroot@patchwork.ozlabs.org",
            "buildroot@lists.busybox.net"
        ],
        "Delivered-To": [
            "patchwork-incoming-buildroot@bilbo.ozlabs.org",
            "buildroot@osuosl.org"
        ],
        "Authentication-Results": [
            "ozlabs.org; spf=pass (sender SPF authorized)\n\tsmtp.mailfrom=busybox.net (client-ip=140.211.166.138;\n\thelo=whitealder.osuosl.org;\n\tenvelope-from=buildroot-bounces@busybox.net;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org; dmarc=fail (p=none dis=none)\n\theader.from=essensium.com",
            "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=essensium.com header.i=@essensium.com\n\theader.a=rsa-sha256 header.s=google header.b=UymnlZzP; \n\tdkim-atps=neutral"
        ],
        "Received": [
            "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 48NfV4468lz9sRN\n\tfor <incoming-buildroot@patchwork.ozlabs.org>;\n\tFri, 21 Feb 2020 03:01:48 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 5D6F18756D;\n\tThu, 20 Feb 2020 16:01:45 +0000 (UTC)",
            "from whitealder.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id E-U4tj21cVa9; Thu, 20 Feb 2020 16:01:42 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 2EF5D84332;\n\tThu, 20 Feb 2020 16:01:42 +0000 (UTC)",
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n\tby ash.osuosl.org (Postfix) with ESMTP id 969021BF9B3\n\tfor <buildroot@lists.busybox.net>;\n\tThu, 20 Feb 2020 16:01:40 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 8A430203BA\n\tfor <buildroot@lists.busybox.net>;\n\tThu, 20 Feb 2020 16:01:40 +0000 (UTC)",
            "from silver.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id Jsb6+TqIgczv for <buildroot@lists.busybox.net>;\n\tThu, 20 Feb 2020 16:01:39 +0000 (UTC)",
            "from mail-wm1-f68.google.com (mail-wm1-f68.google.com\n\t[209.85.128.68])\n\tby silver.osuosl.org (Postfix) with ESMTPS id BB32A2034A\n\tfor <buildroot@buildroot.org>; Thu, 20 Feb 2020 16:01:38 +0000 (UTC)",
            "by mail-wm1-f68.google.com with SMTP id a6so2640509wme.2\n\tfor <buildroot@buildroot.org>; Thu, 20 Feb 2020 08:01:38 -0800 (PST)",
            "from ph-ThinkPad-E560.local.ess-mail.com\n\t(ip-188-118-3-185.reverse.destiny.be. [188.118.3.185])\n\tby smtp.gmail.com with ESMTPSA id\n\th5sm5483691wmf.8.2020.02.20.08.01.35\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 20 Feb 2020 08:01:35 -0800 (PST)"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=essensium.com; s=google;\n\th=from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=rmljOPBOQc0pe/Nze/L287kiXF/klL7Xm0209PUfx0E=;\n\tb=UymnlZzPCB2DNmFXUL3TthRfdvdehf0OHvL1cd02b9jaaG3vtMXOhFy6DaV0KFgLSC\n\t+ndbkHx4nwtX86DxQY0gUt873L0nOnunmlwf/49QgA8Vr/v9+vLaIsErrjQ8Epgq8uwb\n\tFRRr6tF6jfF7+KT6pP+SBk76Q8s1/l+rI2D8s1lpnUrbEh2Ntcuw+8OybV+isjTDUAt1\n\tRZwpqiGdcTsypuFBIxEVQfClfBchkj8I7wo+AUX72g6e9EgdZXnc45736ZsZJWuLPlvn\n\tz546NZil1MoExyXV2WE4CX31j+uOxQhde83gjKDr6iywl4hqOBqfWKgILLGsSjs/6y+Y\n\tSDSw==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version\n\t:content-transfer-encoding;\n\tbh=rmljOPBOQc0pe/Nze/L287kiXF/klL7Xm0209PUfx0E=;\n\tb=B11QXZ4fAF2vDwFw7nB7dJnIpPTRWz1MK59FZ2TsgnnNr0U8t+1DZIHR/WEAeWAgbR\n\tyOu86VmiDgz1sBsvTmnYWPMlFuSThyKHvtvQ4ThrldfSlF1JGSYP1wpFQKwQe5hn3nsC\n\tTdwHts5KdGQalBoMCJ8zw69FHKO4yIYegnzmBXcQxipx/RbGYL7kVuhHCh3n/Iz/oASz\n\tNP+/WYyezvOWQNhWMA/bdtdSFgh5gwJsy4TF7TkWaWu2KPrjCgNTRZlHdITlidGFnM1X\n\taRc0GPRH8MnpQonl33d2KZcqBWpe+JEkNDmC48Uy6Nsiu0IIcyhjHxN0/EZFu89TmyeJ\n\tqRwg==",
        "X-Gm-Message-State": "APjAAAU85C037BVMFPX/scsinPlpaR9p0CBtaijXxL0UDi12Zv0WNRr5\n\tAmIcOoh4zDWUmeL1aVpuVWApffqiUO7Gcg==",
        "X-Google-Smtp-Source": "APXvYqwvOuq9BaNXfh0WHdiYFPMwr3/pC0yiv6HeLyVkObVPXEN1atp61iNsVtLMLXttSkpKmc0P1Q==",
        "X-Received": "by 2002:a05:600c:114d:: with SMTP id\n\tz13mr5188451wmz.105.1582214496595; \n\tThu, 20 Feb 2020 08:01:36 -0800 (PST)",
        "From": "Patrick Havelange <patrick.havelange@essensium.com>",
        "To": "buildroot@buildroot.org",
        "Date": "Thu, 20 Feb 2020 17:01:10 +0100",
        "Message-Id": "<20200220160119.3407-1-patrick.havelange@essensium.com>",
        "X-Mailer": "git-send-email 2.20.1",
        "MIME-Version": "1.0",
        "Subject": "[Buildroot] [PATCH v3 01/10] package/pkg-cargo.mk: Introduce the\n\tcargo package infrastructure.",
        "X-BeenThere": "buildroot@busybox.net",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "Discussion and development of buildroot <buildroot.busybox.net>",
        "List-Unsubscribe": "<http://lists.busybox.net/mailman/options/buildroot>,\n\t<mailto:buildroot-request@busybox.net?subject=unsubscribe>",
        "List-Archive": "<http://lists.busybox.net/pipermail/buildroot/>",
        "List-Post": "<mailto:buildroot@busybox.net>",
        "List-Help": "<mailto:buildroot-request@busybox.net?subject=help>",
        "List-Subscribe": "<http://lists.busybox.net/mailman/listinfo/buildroot>,\n\t<mailto:buildroot-request@busybox.net?subject=subscribe>",
        "Cc": "Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>,\n\tPatrick Havelange <patrick.havelange@essensium.com>,\n\tSam Voss <sam.voss@gmail.com>,\n\t\"Yann E . MORIN\" <yann.morin.1998@free.fr>, \n\tThomas Petazzoni <thomas.petazzoni@bootlin.com>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "buildroot-bounces@busybox.net",
        "Sender": "\"buildroot\" <buildroot-bounces@busybox.net>"
    },
    "content": "In order to be package agnostic, the install phase is now using\ncargo instead of install.\nTARGET_CONFIGURE_OPTS is now also set when running cargo in order\nto support cross compiling C code within cargo.\n\nSigned-off-by: Patrick Havelange <patrick.havelange@essensium.com>\n\n---\nchanges:\nv2 -> v3 (Sam Voss)\n - set TARGET_CONFIGURE_OPTS when running cargo\n\nThis is the V3 of the previously posted series :\nhttp://patchwork.ozlabs.org/project/buildroot/list/?series=156166&state=%2A&archive=both\n\nA lot of changes following the buildroot developer meeting's\ndecisions from February 2020.\n\nNeeds to be applied on top of the rust 1.40 bump\n---\n package/Makefile.in  |  1 +\n package/pkg-cargo.mk | 92 ++++++++++++++++++++++++++++++++++++++++++++\n 2 files changed, 93 insertions(+)\n create mode 100644 package/pkg-cargo.mk",
    "diff": "diff --git a/package/Makefile.in b/package/Makefile.in\nindex 285e2837ef..650d7c166e 100644\n--- a/package/Makefile.in\n+++ b/package/Makefile.in\n@@ -426,3 +426,4 @@ include package/pkg-kernel-module.mk\n include package/pkg-waf.mk\n include package/pkg-golang.mk\n include package/pkg-meson.mk\n+include package/pkg-cargo.mk\ndiff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk\nnew file mode 100644\nindex 0000000000..35f7c15ad9\n--- /dev/null\n+++ b/package/pkg-cargo.mk\n@@ -0,0 +1,92 @@\n+################################################################################\n+# Cargo package infrastructure\n+#\n+# This file implements an infrastructure that eases development of package\n+# .mk files for Cargo packages. It should be used for all packages that use\n+# Cargo as their build system.\n+#\n+# See the Buildroot documentation for details on the usage of this\n+# infrastructure\n+#\n+# In terms of implementation, this Cargo infrastructure requires the .mk file\n+# to only specify metadata information about the package: name, version,\n+# download URL, etc.\n+#\n+# We still allow the package .mk file to override what the different steps\n+# are doing, if needed. For example, if <PKG>_BUILD_CMDS is already defined,\n+# it is used as the list of commands to perform to build the package,\n+# instead of the default Cargo behaviour. The package can also define some\n+# post operation hooks.\n+#\n+################################################################################\n+\n+################################################################################\n+# inner-cargo-package -- defines how the configuration, compilation and\n+# installation of a cargo package should be done, implements a few hooks\n+# to tune the build process for cargo specifities and calls the generic\n+# package infrastructure to generate the necessary make targets\n+#\n+#  argument 1 is the lowercase package name\n+#  argument 2 is the uppercase package name, including a HOST_ prefix\n+#             for host packages\n+#  argument 3 is the uppercase package name, without the HOST_ prefix\n+#             for host packages\n+#  argument 4 is the type (target or host)\n+################################################################################\n+\n+define inner-cargo-package\n+\n+# We need host-rustc to run cargo\n+$(2)_DEPENDENCIES += host-rustc\n+\n+$(2)_CARGO_ENV = \\\n+\tCARGO_HOME=$(HOST_DIR)/share/cargo \\\n+\t$(TARGET_CONFIGURE_OPTS)\n+\n+$(2)_CARGO_MODE = $(if $(BR2_ENABLE_DEBUG),debug,release)\n+\n+ifeq ($(4),target)\n+    $(2)_CARGO_TARGET_OPT = --target $$(RUSTC_TARGET_NAME)\n+endif\n+\n+#\n+# Build step. Only define it if not already defined by the package .mk\n+# file.\n+#\n+ifndef $(2)_BUILD_CMDS\n+define $(2)_BUILD_CMDS\n+\t$(TARGET_MAKE_ENV) $$($(2)_CARGO_ENV) \\\n+\t\tcargo build \\\n+\t\t\t--$$($(2)_CARGO_MODE) \\\n+\t\t\t$$($(2)_CARGO_TARGET_OPT) \\\n+\t\t\t--manifest-path $$(@D)/Cargo.toml\n+endef\n+endif\n+\n+#\n+# Target installation step. Only define it if not already defined by\n+# the package .mk file.\n+#\n+ifndef $(2)_INSTALL_TARGET_CMDS\n+define $(2)_INSTALL_TARGET_CMDS\n+\t$(TARGET_MAKE_ENV) $$($(2)_CARGO_ENV) \\\n+\t\tcargo install \\\n+\t\t\t--root $(TARGET_DIR)/usr/ \\\n+\t\t\t--bins \\\n+\t\t\t--path $$(@D) \\\n+\t\t\t$$($(2)_CARGO_TARGET_OPT) \\\n+\t\t\t--force\n+endef\n+endif\n+\n+# Call the generic package infrastructure to generate the necessary\n+# make targets\n+$(call inner-generic-package,$(1),$(2),$(3),$(4))\n+\n+endef\n+\n+################################################################################\n+# cargo-package -- the target generator macro for Cargo packages\n+################################################################################\n+\n+cargo-package = $(call inner-cargo-package,$(pkgname),$(call UPPERCASE,$(pkgname)),$(call UPPERCASE,$(pkgname)),target)\n",
    "prefixes": [
        "v3",
        "01/10"
    ]
}