|
| 1 | +diff --git a/package/swupdate/0001-diskpart-force-kernel-to-reread-partition-table.patch b/package/swupdate/0001-diskpart-force-kernel-to-reread-partition-table.patch |
| 2 | +deleted file mode 100644 |
| 3 | +index 5964d1b9..00000000 |
| 4 | +--- a/package/swupdate/0001-diskpart-force-kernel-to-reread-partition-table.patch |
| 5 | ++++ /dev/null |
| 6 | +@@ -1,32 +0,0 @@ |
| 7 | +-From 305a7a5a74a612801d9df2b2efc86dd952b8c4e7 Mon Sep 17 00:00:00 2001 |
| 8 | +-From: Stefano Babic <sbabic@denx.de> |
| 9 | +-Date: Tue, 9 Jun 2020 13:58:06 +0000 |
| 10 | +-Subject: [PATCH] diskpart: force kernel to reread partition table |
| 11 | +- |
| 12 | +-After writing a partition table to disk, the kernel should be informed |
| 13 | +-(like the partconf tool does), else it is not possible to install images |
| 14 | +-in the new created partitions. |
| 15 | +- |
| 16 | +-Signed-off-by: Stefano Babic <sbabic@denx.de> |
| 17 | +-Signed-off-by: Joris Offouga <offougajoris@gmail.com> |
| 18 | +---- |
| 19 | +- handlers/diskpart_handler.c | 3 ++- |
| 20 | +- 1 file changed, 2 insertions(+), 1 deletion(-) |
| 21 | +- |
| 22 | +-diff --git a/handlers/diskpart_handler.c b/handlers/diskpart_handler.c |
| 23 | +-index 16adc17..372412b 100644 |
| 24 | +---- a/handlers/diskpart_handler.c |
| 25 | +-+++ b/handlers/diskpart_handler.c |
| 26 | +-@@ -273,7 +273,8 @@ static int diskpart(struct img_type *img, |
| 27 | +- /* |
| 28 | +- * Everything done, write into disk |
| 29 | +- */ |
| 30 | +-- ret = fdisk_write_disklabel(cxt); |
| 31 | +-+ ret = fdisk_write_disklabel(cxt) | |
| 32 | +-+ fdisk_reread_partition_table(cxt); |
| 33 | +- |
| 34 | +- handler_exit: |
| 35 | +- if (fdisk_deassign_device(cxt, 0)) |
| 36 | +--- |
| 37 | +-2.25.1 |
| 38 | +- |
| 39 | +diff --git a/package/swupdate/0002-Shellscript-stops-before-completing.patch b/package/swupdate/0002-Shellscript-stops-before-completing.patch |
| 40 | +deleted file mode 100644 |
| 41 | +index d9143889..00000000 |
| 42 | +--- a/package/swupdate/0002-Shellscript-stops-before-completing.patch |
| 43 | ++++ /dev/null |
| 44 | +@@ -1,52 +0,0 @@ |
| 45 | +-From bd08e45d7b25f06da2fc6dc824146b471db5f1f4 Mon Sep 17 00:00:00 2001 |
| 46 | +-From: Stefano Babic <sbabic@denx.de> |
| 47 | +-Date: Tue, 16 Jun 2020 10:29:55 +0200 |
| 48 | +-Subject: [PATCH] Shellscript stops before completing |
| 49 | +- |
| 50 | +-Commit 8fb94d7 reworks the way shell script are called, redirecting |
| 51 | +-stdout and stderr to SWUpdate. A shell script runs then in a child |
| 52 | +-process. Under some circumstances, SWUpdate closes the forked process |
| 53 | +-before the child process completes. |
| 54 | +- |
| 55 | +-Be sure that the child process has terminated before to go on. |
| 56 | +- |
| 57 | +-Signed-off-by: Stefano Babic <sbabic@denx.de> |
| 58 | +-Reported-by: Piotr Piwko <piotr.piwko@gmail.com> |
| 59 | +-Tested-by: Piotr Piwko <piotr.piwko@gmail.com> |
| 60 | +-Signed-off-by: Joris Offouga <offougajoris@gmail.com> |
| 61 | +---- |
| 62 | +- core/pctl.c | 4 ++-- |
| 63 | +- 1 file changed, 2 insertions(+), 2 deletions(-) |
| 64 | +- |
| 65 | +-diff --git a/core/pctl.c b/core/pctl.c |
| 66 | +-index 8b1c667..01ad540 100644 |
| 67 | +---- a/core/pctl.c |
| 68 | +-+++ b/core/pctl.c |
| 69 | +-@@ -263,6 +263,7 @@ int run_system_cmd(const char *cmd) |
| 70 | +- } |
| 71 | +- } else { |
| 72 | +- int fds[2]; |
| 73 | +-+ pid_t w; |
| 74 | +- |
| 75 | +- close(stdoutpipe[PIPE_WRITE]); |
| 76 | +- close(stderrpipe[PIPE_WRITE]); |
| 77 | +-@@ -276,7 +277,6 @@ int run_system_cmd(const char *cmd) |
| 78 | +- * and from stderr (of the child process) as ERROR |
| 79 | +- */ |
| 80 | +- do { |
| 81 | +-- pid_t w; |
| 82 | +- int n1 = 0; |
| 83 | +- struct timeval tv; |
| 84 | +- fd_set readfds; |
| 85 | +-@@ -373,7 +373,7 @@ int run_system_cmd(const char *cmd) |
| 86 | +- } |
| 87 | +- } |
| 88 | +- } while (ret > 0 && n1 > 0); |
| 89 | +-- } while (!WIFEXITED(wstatus)); |
| 90 | +-+ } while (w != process_id); |
| 91 | +- |
| 92 | +- close(stdoutpipe[PIPE_READ]); |
| 93 | +- close(stderrpipe[PIPE_READ]); |
| 94 | +--- |
| 95 | +-2.25.1 |
| 96 | +- |
| 97 | +diff --git a/package/swupdate/Config.in b/package/swupdate/Config.in |
| 98 | +index e87f6958..3f34eb3f 100644 |
| 99 | +--- a/package/swupdate/Config.in |
| 100 | ++++ b/package/swupdate/Config.in |
| 101 | +@@ -68,6 +68,30 @@ config BR2_PACKAGE_SWUPDATE_INSTALL_WEBSITE |
| 102 | + This is necessary if you want to run swupdate with the |
| 103 | + embedded webserver and do not provide an own website to be |
| 104 | + installed to /var/www/swupdate. |
| 105 | ++ |
| 106 | ++config BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_LIB |
| 107 | ++ bool "install client library" |
| 108 | ++ default n |
| 109 | ++ help |
| 110 | ++ Install the shared swupdate client library. |
| 111 | ++ |
| 112 | ++config BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_TOOLS |
| 113 | ++ bool "install client tools" |
| 114 | ++ default n |
| 115 | ++ select BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_LIB |
| 116 | ++ help |
| 117 | ++ Install the provided swupdate client tools. |
| 118 | ++ |
| 119 | ++ swupdate-client, swupdate-sysrestart, swupdate-progress |
| 120 | ++ |
| 121 | ++config BR2_PACKAGE_SWUPDATE_INSTALL_HAWKBIT_TOOLS |
| 122 | ++ bool "install hawkbit tools" |
| 123 | ++ default n |
| 124 | ++ select BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_LIB |
| 125 | ++ help |
| 126 | ++ Install the provided hawkbit client tools. |
| 127 | ++ |
| 128 | ++ swupdate-sendtohawkbit, swupdate-hawkbitcfg |
| 129 | + endif |
| 130 | + |
| 131 | + comment "swupdate needs a toolchain w/ threads" |
| 132 | +diff --git a/package/swupdate/swupdate.hash b/package/swupdate/swupdate.hash |
| 133 | +index 40f978d2..69b15c34 100644 |
| 134 | +--- a/package/swupdate/swupdate.hash |
| 135 | ++++ b/package/swupdate/swupdate.hash |
| 136 | +@@ -1,5 +1,5 @@ |
| 137 | + # Locally calculated |
| 138 | +-sha256 132df2ff1ad41c7aabd0fbef6a23d28607cbd5cad52aab050c4822977a107486 swupdate-2020.04.tar.gz |
| 139 | ++sha256 41763cf9c5da99098639bc35942de7264e4a544c7b307c9f04bdf0d90e7d3346 swupdate-2020.11.tar.gz |
| 140 | + sha256 43492b377cf2fb67942d1dd231146bd4e6578646ad13ef289297c9dd75cbc478 Licenses/Exceptions |
| 141 | + sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 Licenses/gpl-2.0.txt |
| 142 | + sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 Licenses/lgpl-2.1.txt |
| 143 | +diff --git a/package/swupdate/swupdate.mk b/package/swupdate/swupdate.mk |
| 144 | +index d96a0c2e..b46f13f1 100644 |
| 145 | +--- a/package/swupdate/swupdate.mk |
| 146 | ++++ b/package/swupdate/swupdate.mk |
| 147 | +@@ -4,7 +4,7 @@ |
| 148 | + # |
| 149 | + ################################################################################ |
| 150 | + |
| 151 | +-SWUPDATE_VERSION = 2020.04 |
| 152 | ++SWUPDATE_VERSION = 2020.11 |
| 153 | + SWUPDATE_SITE = $(call github,sbabic,swupdate,$(SWUPDATE_VERSION)) |
| 154 | + SWUPDATE_LICENSE = GPL-2.0+ with OpenSSL exception, LGPL-2.1+, MIT |
| 155 | + SWUPDATE_LICENSE_FILES = Licenses/Exceptions Licenses/gpl-2.0.txt \ |
| 156 | +@@ -173,6 +173,16 @@ endef |
| 157 | + |
| 158 | + define SWUPDATE_INSTALL_TARGET_CMDS |
| 159 | + $(INSTALL) -D -m 0755 $(@D)/swupdate $(TARGET_DIR)/usr/bin/swupdate |
| 160 | ++ $(if $(BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_LIB), \ |
| 161 | ++ $(INSTALL) -D -m 0644 $(@D)/libswupdate.so.0.1 $(TARGET_DIR)/usr/lib/; |
| 162 | ++ ln -sf libswupdate.so.0.1 $(TARGET_DIR)/usr/lib/libswupdate.so) |
| 163 | ++ $(if $(BR2_PACKAGE_SWUPDATE_INSTALL_CLIENT_TOOLS), \ |
| 164 | ++ $(INSTALL) -D -m 0755 $(@D)/tools/swupdate-progress $(TARGET_DIR)/usr/bin/swupdate-progress; \ |
| 165 | ++ $(INSTALL) -D -m 0755 $(@D)/tools/swupdate-client $(TARGET_DIR)/usr/bin/swupdate-client; \ |
| 166 | ++ $(INSTALL) -D -m 0755 $(@D)/tools/swupdate-sysrestart $(TARGET_DIR)/usr/bin/swupdate-sysrestart) |
| 167 | ++ $(if $(BR2_PACKAGE_SWUPDATE_INSTALL_HAWKBIT_TOOLS), \ |
| 168 | ++ $(INSTALL) -D -m 0755 $(@D)/tools/swupdate-sendtohawkbit $(TARGET_DIR)/usr/bin/swupdate-sendtohawkbit; \ |
| 169 | ++ $(INSTALL) -D -m 0755 $(@D)/tools/swupdate-hawkbitcfg $(TARGET_DIR)/usr/bin/swupdate-hawkbitcfg) |
| 170 | + $(if $(BR2_PACKAGE_SWUPDATE_INSTALL_WEBSITE), \ |
| 171 | + mkdir -p $(TARGET_DIR)/var/www/swupdate; \ |
| 172 | + cp -dpfr $(@D)/examples/www/v2/* $(TARGET_DIR)/var/www/swupdate) |
0 commit comments