From a88494686e09ad719c699f281556ef64630e3acf Mon Sep 17 00:00:00 2001 From: Patrick Uiterwijk Date: Feb 22 2018 11:46:30 +0000 Subject: Add typecasting patches for usb IDs Signed-off-by: Patrick Uiterwijk --- diff --git a/systemd-typecast-usbids.patch b/systemd-typecast-usbids.patch new file mode 100644 index 0000000..1ccd3ed --- /dev/null +++ b/systemd-typecast-usbids.patch @@ -0,0 +1,26 @@ +From 68b2813a0b6dcf8ff8f8eb36aa225ae90661e67e Mon Sep 17 00:00:00 2001 +From: Fedora systemd team +Date: Thu, 22 Feb 2018 12:45:31 +0100 +Subject: [PATCH] Typecast USB IDs + +Signed-off-by: Fedora systemd team +--- + src/udev/udev-builtin-hwdb.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/udev/udev-builtin-hwdb.c b/src/udev/udev-builtin-hwdb.c +index ca7f7c2..d3556e4 100644 +--- a/src/udev/udev-builtin-hwdb.c ++++ b/src/udev/udev-builtin-hwdb.c +@@ -77,7 +77,7 @@ static const char *modalias_usb(struct udev_device *dev, char *s, size_t size) { + pn = strtol(p, NULL, 16); + if (pn <= 0) + return NULL; +- snprintf(s, size, "usb:v%04Xp%04X*", vn, pn); ++ snprintf(s, size, "usb:v%04Xp%04X*", (uint16_t)vn, (uint16_t)pn); + return s; + } + +-- +2.16.2 + diff --git a/systemd.spec b/systemd.spec index 88ba98b..94c236a 100644 --- a/systemd.spec +++ b/systemd.spec @@ -48,6 +48,8 @@ i=1; for j in 00*patch; do printf "Patch%04d: %s\n" $i $j; i=$((i+1));done| GIT_DIR=../../src/systemd/.git git diffab -M v233..master@{2017-06-15} -- hwdb/[67]* hwdb/parse_hwdb.py > hwdb.patch %endif +Patch1: systemd-typecast-usbids.patch + Patch0998: 0998-resolved-create-etc-resolv.conf-symlink-at-runtime.patch %global num_patches %{lua: c=0; for i,p in ipairs(patches) do c=c+1; end; print(c);} @@ -709,6 +711,7 @@ fi %changelog * Thu Feb 22 2018 Patrick Uiterwijk - 237-4.git84c8da5 - Add coreutils dep for systemd-libs %post +- Add patch to typecast USB IDs to avoid compile failure * Wed Feb 21 2018 Zbigniew Jędrzejewski-Szmek - 237-3.git84c8da5 - Update some patches for test skipping that were updated upstream