get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 495233,
    "url": "http://patchwork.ozlabs.org/api/patches/495233/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/buildroot/patch/1436905227-26937-5-git-send-email-clayton.shotwell@rockwellcollins.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": "<1436905227-26937-5-git-send-email-clayton.shotwell@rockwellcollins.com>",
    "list_archive_url": null,
    "date": "2015-07-14T20:20:16",
    "name": "[v9,04/15] busybox: applets as individual binaries",
    "commit_ref": null,
    "pull_url": null,
    "state": "changes-requested",
    "archived": false,
    "hash": "adb8cefac6910815a665cc308f7e201081122ad8",
    "submitter": {
        "id": 64481,
        "url": "http://patchwork.ozlabs.org/api/people/64481/?format=api",
        "name": "Clayton Shotwell",
        "email": "clayton.shotwell@rockwellcollins.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/buildroot/patch/1436905227-26937-5-git-send-email-clayton.shotwell@rockwellcollins.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/495233/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/495233/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<buildroot-bounces@busybox.net>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "buildroot@lists.busybox.net"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "buildroot@osuosl.org"
        ],
        "Received": [
            "from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137])\n\tby ozlabs.org (Postfix) with ESMTP id 5545D1402AC\n\tfor <incoming@patchwork.ozlabs.org>;\n\tWed, 15 Jul 2015 06:21:04 +1000 (AEST)",
            "from localhost (localhost [127.0.0.1])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id 9BE65A439E;\n\tTue, 14 Jul 2015 20:21:03 +0000 (UTC)",
            "from fraxinus.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id umhbfixVoTBf; Tue, 14 Jul 2015 20:21:00 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id CCC82A42F9;\n\tTue, 14 Jul 2015 20:20:43 +0000 (UTC)",
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n\tby ash.osuosl.org (Postfix) with ESMTP id 2C8F91CE612\n\tfor <buildroot@lists.busybox.net>;\n\tTue, 14 Jul 2015 20:20:41 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 26ACE26749\n\tfor <buildroot@lists.busybox.net>;\n\tTue, 14 Jul 2015 20:20:41 +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 nq9yE9v1MyS5 for <buildroot@lists.busybox.net>;\n\tTue, 14 Jul 2015 20:20:39 +0000 (UTC)",
            "from da1vs02.rockwellcollins.com (da1vs02.rockwellcollins.com\n\t[205.175.227.29])\n\tby silver.osuosl.org (Postfix) with ESMTPS id 6EDC4264A8\n\tfor <buildroot@buildroot.org>; Tue, 14 Jul 2015 20:20:39 +0000 (UTC)",
            "from ofwda1n02.rockwellcollins.com (HELO\n\tcrulimr02.rockwellcollins.com) ([205.175.227.14])\n\tby da1vs02.rockwellcollins.com with ESMTP; 14 Jul 2015 15:20:38 -0500"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "X-Received": "from thehammer.rockwellcollins.com (unknown [192.168.141.197])\n\tby crulimr02.rockwellcollins.com (Postfix) with ESMTP id 3799860150; \n\tTue, 14 Jul 2015 15:20:38 -0500 (CDT)",
        "From": "Clayton Shotwell <clayton.shotwell@rockwellcollins.com>",
        "To": "buildroot@buildroot.org",
        "Date": "Tue, 14 Jul 2015 15:20:16 -0500",
        "Message-Id": "<1436905227-26937-5-git-send-email-clayton.shotwell@rockwellcollins.com>",
        "X-Mailer": "git-send-email 1.9.1",
        "In-Reply-To": "<1436905227-26937-1-git-send-email-clayton.shotwell@rockwellcollins.com>",
        "References": "<1436905227-26937-1-git-send-email-clayton.shotwell@rockwellcollins.com>",
        "Cc": "Clayton Shotwell <clayton.shotwell@rockwellcollins.com>",
        "Subject": "[Buildroot] [PATCH v9 04/15] busybox: applets as individual binaries",
        "X-BeenThere": "buildroot@busybox.net",
        "X-Mailman-Version": "2.1.18-1",
        "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>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "buildroot-bounces@busybox.net",
        "Sender": "\"buildroot\" <buildroot-bounces@busybox.net>"
    },
    "content": "The individual binaries option of busybox allows for the applets\nthat would usually be symlinks to be built as individual applications\nthat link against a shared library.\n\nThis feature is needed for SELinux to allow the applications to run\nunder the correct SELinux context.\n\nThe patch being added allows the individual applications to be\ninstalled and will be upstreamed to the busybox developers.\n\nThe initial work for this change was done by Thomas Petazzoni\n<thomas.petazzoni@free-electrons.com>.\n\nSigned-off-by: Clayton Shotwell <clayton.shotwell@rockwellcollins.com>\nSigned-off-by: Matthew Weber <matthew.weber@rockwellcollins.com>\nReviewed-by: Samuel Martin <s.martin49@gmail.com>\n\n---\nChanges v8 -> v9:\n  - No changes\n\nChanges v7 -> v8:\n  - Changed individual binaries comment to be !BR2_bfin (Suggested by\n    Samuel)\n\nChanges v6 -> v7:\n  - No changes\n\nChanges v5 -> v6:\n  - No changes\n\nChanges v4 -> v5:\n  - Renamed to follow latest patch naming convention (Matt W.)\n  - Updated to use BR2_STATIC_LIBS instead of old PREFERRED (Matt W.)\n  - Added depends to make sure bfin can't build shared lib\n    busybox lib for individual binary use.  Looks like shared\n    lib creation doesn't error out but the objects don't get\n    placed into the elf.  Then the trylink fails on linking\n    the first individual applet. (Matt W.)\n  - Made suid permissions setting dynamic for applets actually being\n    installed (Clayton S.)\n\nChanges v1 -> v4:\n  - Did not exist\n---\n ...s-Add-installation-of-individual-binaries.patch | 103 +++++++++++++++++++++\n package/busybox/Config.in                          |   9 ++\n package/busybox/busybox.mk                         |  41 ++++++++\n 3 files changed, 153 insertions(+)\n create mode 100644 package/busybox/0002-applets-Add-installation-of-individual-binaries.patch",
    "diff": "diff --git a/package/busybox/0002-applets-Add-installation-of-individual-binaries.patch b/package/busybox/0002-applets-Add-installation-of-individual-binaries.patch\nnew file mode 100644\nindex 0000000..ae0e654\n--- /dev/null\n+++ b/package/busybox/0002-applets-Add-installation-of-individual-binaries.patch\n@@ -0,0 +1,103 @@\n+From 3451b55054a6fe2073a21301938802a27dec835d Mon Sep 17 00:00:00 2001\n+From: Clayton Shotwell <clshotwe@rockwellcollins.com>\n+Date: Mon, 16 Dec 2013 14:45:33 -0600\n+Subject: [PATCH 5/5] applets: Add installation of individual binaries\n+\n+Adding support to install individual binaries if the option is\n+enabled. This also installs the shared libbusybox.so.* library.\n+\n+Signed-off-by: Clayton Shotwell <clshotwe@rockwellcollins.com>\n+---\n+ Makefile.custom    |    4 ++++\n+ applets/install.sh |   26 ++++++++++++++++++++++++--\n+ 2 files changed, 28 insertions(+), 2 deletions(-)\n+\n+diff --git a/Makefile.custom b/Makefile.custom\n+index 6da79e6..e4dc4dc 100644\n+--- a/Makefile.custom\n++++ b/Makefile.custom\n+@@ -23,6 +23,10 @@ ifeq ($(CONFIG_INSTALL_SH_APPLET_SCRIPT_WRAPPER),y)\n+ INSTALL_OPTS:= --scriptwrapper\n+ endif\n+ endif\n++ifeq ($(CONFIG_FEATURE_INDIVIDUAL),y)\n++INSTALL_OPTS:= --binaries\n++LIBBUSYBOX_SONAME:= 0_lib/libbusybox.so.$(BB_VER)\n++endif\n+ install: $(srctree)/applets/install.sh busybox busybox.links\n+ \t$(Q)DO_INSTALL_LIBS=\"$(strip $(LIBBUSYBOX_SONAME) $(DO_INSTALL_LIBS))\" \\\n+ \t\t$(SHELL) $< $(CONFIG_PREFIX) $(INSTALL_OPTS)\n+diff --git a/applets/install.sh b/applets/install.sh\n+index 95b4719..d01c98d 100755\n+--- a/applets/install.sh\n++++ b/applets/install.sh\n+@@ -5,19 +5,26 @@ export LC_CTYPE=POSIX\n+ \n+ prefix=$1\n+ if [ -z \"$prefix\" ]; then\n+-\techo \"usage: applets/install.sh DESTINATION [--symlinks/--hardlinks/--scriptwrapper]\"\n++\techo \"usage: applets/install.sh DESTINATION [--symlinks/--hardlinks/--binaries/--scriptwrapper]\"\n+ \texit 1\n+ fi\n+ \n++# Source the configuration\n++. ./.config\n++\n+ h=`sort busybox.links | uniq`\n+ \n++sharedlib_dir=\"0_lib\"\n++\n+ linkopts=\"\"\n+ scriptwrapper=\"n\"\n++binaries=\"n\"\n+ cleanup=\"0\"\n+ noclobber=\"0\"\n+ case \"$2\" in\n+ \t--hardlinks)     linkopts=\"-f\";;\n+ \t--symlinks)      linkopts=\"-fs\";;\n++\t--binaries)      binaries=\"y\";;\n+ \t--scriptwrapper) scriptwrapper=\"y\";swrapall=\"y\";;\n+ \t--sw-sh-hard)    scriptwrapper=\"y\";linkopts=\"-f\";;\n+ \t--sw-sh-sym)     scriptwrapper=\"y\";linkopts=\"-fs\";;\n+@@ -40,8 +47,9 @@ if [ -n \"$DO_INSTALL_LIBS\" ] && [ \"$DO_INSTALL_LIBS\" != \"n\" ]; then\n+ \tfor i in $DO_INSTALL_LIBS; do\n+ \t\trm -f \"$prefix/$libdir/$i\" || exit 1\n+ \t\tif [ -f \"$i\" ]; then\n++\t\t\techo \"   Installing $i to the target at $prefix/$libdir/\"\n+ \t\t\tcp -pPR \"$i\" \"$prefix/$libdir/\" || exit 1\n+-\t\t\tchmod 0644 \"$prefix/$libdir/$i\" || exit 1\n++\t\t\tchmod 0644 \"$prefix/$libdir/`basename $i`\" || exit 1\n+ \t\tfi\n+ \tdone\n+ fi\n+@@ -68,6 +76,7 @@ install -m 755 busybox \"$prefix/bin/busybox\" || exit 1\n+ \n+ for i in $h; do\n+ \tappdir=`dirname \"$i\"`\n++\tapp=`basename \"$i\"`\n+ \tmkdir -p \"$prefix/$appdir\" || exit 1\n+ \tif [ \"$scriptwrapper\" = \"y\" ]; then\n+ \t\tif [ \"$swrapall\" != \"y\" ] && [ \"$i\" = \"/bin/sh\" ]; then\n+@@ -78,6 +87,19 @@ for i in $h; do\n+ \t\t\tchmod +x \"$prefix/$i\"\n+ \t\tfi\n+ \t\techo \"\t$prefix/$i\"\n++\telif [ \"$binaries\" = \"y\" ]; then\n++\t\t# Copy the binary over rather\n++\t\tif [ -e $sharedlib_dir/$app ]; then\n++\t\t\tif [ \"$noclobber\" = \"0\" ] || [ ! -e \"$prefix/$i\" ]; then\n++\t\t\t\techo \"   Copying $sharedlib_dir/$app to $prefix/$i\"\n++\t\t\t\tcp -pPR $sharedlib_dir/$app $prefix/$i || exit 1\n++\t\t\telse\n++\t\t\t\techo \"  $prefix/$i already exists\"\n++\t\t\tfi\n++\t\telse\n++\t\t\techo \"Error: Could not find $sharedlib_dir/$app\"\n++\t\t\texit 1\n++\t\tfi\n+ \telse\n+ \t\tif [ \"$2\" = \"--hardlinks\" ]; then\n+ \t\t\tbb_path=\"$prefix/bin/busybox\"\n+-- \n+1.7.1\n+\ndiff --git a/package/busybox/Config.in b/package/busybox/Config.in\nindex 6847a60..b3303c0 100644\n--- a/package/busybox/Config.in\n+++ b/package/busybox/Config.in\n@@ -32,6 +32,15 @@ config BR2_PACKAGE_BUSYBOX_SHOW_OTHERS\n \t  Show packages in menuconfig that are potentially also provided\n \t  by busybox.\n \n+config BR2_PACKAGE_BUSYBOX_INDIVIDUAL_BINARIES\n+\tbool \"Individual binaries\"\n+\tdepends on !BR2_STATIC_LIBS\n+\tdepends on !BR2_bfin # libbusybox.so link issue\n+\n+comment \"Busybox individual binaries depends on dynamic libraries\"\n+\tdepends on BR2_STATIC_LIBS\n+\tdepends on !BR2_bfin\n+\n config BR2_PACKAGE_BUSYBOX_WATCHDOG\n \tbool \"Install the watchdog daemon startup script\"\n \thelp\ndiff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk\nindex 6b2abca..4942e75 100644\n--- a/package/busybox/busybox.mk\n+++ b/package/busybox/busybox.mk\n@@ -50,9 +50,37 @@ BUSYBOX_KCONFIG_FRAGMENT_FILES = $(call qstrip,$(BR2_PACKAGE_BUSYBOX_CONFIG_FRAG\n BUSYBOX_KCONFIG_EDITORS = menuconfig xconfig gconfig\n BUSYBOX_KCONFIG_OPTS = $(BUSYBOX_MAKE_OPTS)\n \n+ifeq ($(BR2_PACKAGE_BUSYBOX_INDIVIDUAL_BINARIES),y)\n+define BUSYBOX_PERMISSIONS\n+\t/usr/share/udhcpc/default.script f 755  0  0 - - - - -\n+endef\n+\n+# Set permissions on all applets with BB_SUID_REQUIRE and BB_SUID_MAYBE. The\n+# permissions are pulled from the applets.h file that is generated during\n+# the build and used to determine all of the possible applets. The permissions\n+# file is generated and added to the list of device tables used by makedevs to\n+# set file permissions.\n+define BUSYBOX_MAKEDEV_PERMISSIONS\n+\tif [ -f $(@D)/.buildroot_permissions ]; then \\\n+\t\trm $(@D)/.buildroot_permissions; \\\n+\tfi; \\\n+\ttouch $(@D)/.buildroot_permissions; \\\n+\tfor app in `grep -r -e \"APPLET.*BB_SUID_REQUIRE\\|APPLET.*BB_SUID_MAYBE\" $(@D)/include/applets.h \\\n+\t\t\t| sed -e 's/,.*//' -e 's/.*(//'`; \\\n+\tdo \\\n+\t\ttemp=`grep -w $${app} $(@D)/busybox.links`; \\\n+\t\tif [ -n \"$${temp}\" ]; then \\\n+\t\t\techo \"$${temp} f 4755 0  0 - - - - -\" >> $(@D)/.buildroot_permissions; \\\n+\t\tfi; \\\n+\tdone\n+endef\n+BUSYBOX_POST_INSTALL_TARGET_HOOKS += BUSYBOX_MAKEDEV_PERMISSIONS\n+BR2_ROOTFS_DEVICE_TABLE += $(BUSYBOX_DIR)/.buildroot_permissions\n+else\n define BUSYBOX_PERMISSIONS\n \t/bin/busybox                     f 4755 0  0 - - - - -\n endef\n+endif\n \n # If mdev will be used for device creation enable it and copy S10mdev to /etc/init.d\n ifeq ($(BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV),y)\n@@ -141,6 +169,17 @@ define BUSYBOX_SET_INIT\n endef\n endif\n \n+ifeq ($(BR2_PACKAGE_BUSYBOX_INDIVIDUAL_BINARIES),y)\n+define BUSYBOX_CONFIGURE_INDIVIDUAL_BINARIES\n+\t$(call KCONFIG_ENABLE_OPT,CONFIG_BUILD_LIBBUSYBOX,$(BUSYBOX_BUILD_CONFIG))\n+\t$(call KCONFIG_ENABLE_OPT,CONFIG_FEATURE_INDIVIDUAL,$(BUSYBOX_BUILD_CONFIG))\n+endef\n+\n+define BUSYBOX_INSTALL_INDIVIDUAL_BINARIES\n+\trm -f $(TARGET_DIR)/bin/busybox\n+endef\n+endif\n+\n define BUSYBOX_INSTALL_LOGGING_SCRIPT\n \tif grep -q CONFIG_SYSLOGD=y $(@D)/.config; then \\\n \t\t$(INSTALL) -m 0755 -D package/busybox/S01logging \\\n@@ -199,6 +238,7 @@ define BUSYBOX_KCONFIG_FIXUP_CMDS\n \t$(BUSYBOX_INTERNAL_SHADOW_PASSWORDS)\n \t$(BUSYBOX_SET_INIT)\n \t$(BUSYBOX_SET_WATCHDOG)\n+\t$(BUSYBOX_CONFIGURE_INDIVIDUAL_BINARIES)\n endef\n \n define BUSYBOX_CONFIGURE_CMDS\n@@ -221,6 +261,7 @@ define BUSYBOX_INSTALL_INIT_SYSV\n \t$(BUSYBOX_INSTALL_LOGGING_SCRIPT)\n \t$(BUSYBOX_INSTALL_WATCHDOG_SCRIPT)\n \t$(BUSYBOX_INSTALL_TELNET_SCRIPT)\n+\t$(BUSYBOX_INSTALL_INDIVIDUAL_BINARIES)\n endef\n \n # Checks to give errors that the user can understand\n",
    "prefixes": [
        "v9",
        "04/15"
    ]
}