From 96d5b611eb730fc37437253fcf3d4920e22f8035 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 20 Sep 2014 21:36:31 +0200 Subject: [PATCH] util-linux: fix musl build (__SWORD_TYPE undefined). --- srcpkgs/util-linux/patches/fix-musl.patch | 20 ++++++++++++++++++++ srcpkgs/util-linux/template | 2 +- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/util-linux/patches/fix-musl.patch diff --git a/srcpkgs/util-linux/patches/fix-musl.patch b/srcpkgs/util-linux/patches/fix-musl.patch new file mode 100644 index 00000000000..e426672183d --- /dev/null +++ b/srcpkgs/util-linux/patches/fix-musl.patch @@ -0,0 +1,20 @@ +Define __SWORD_TYPE for musl. + +--- sys-utils/switch_root.c.orig 2014-09-20 21:33:27.551345526 +0200 ++++ sys-utils/switch_root.c 2014-09-20 21:34:17.958584374 +0200 +@@ -47,6 +47,15 @@ + #define MNT_DETACH 0x00000002 /* Just detach from the tree */ + #endif + ++#ifndef __SWORD_TYPE ++# if __WORDSIZE == 32 /* System word size */ ++# define __SWORD_TYPE int ++# else /* __WORDSIZE == 64 */ ++# define __SWORD_TYPE long int ++# endif ++#endif ++ ++ + /* remove all files/directories below dirName -- don't cross mountpoints */ + static int recursiveRemove(int fd) + { diff --git a/srcpkgs/util-linux/template b/srcpkgs/util-linux/template index c9dab1cd2d3..1f4d6e64db1 100644 --- a/srcpkgs/util-linux/template +++ b/srcpkgs/util-linux/template @@ -1,7 +1,7 @@ # Template file for 'util-linux' pkgname=util-linux version=2.25.1 -revision=1 +revision=2 short_desc="Miscellaneous linux utilities" maintainer="Juan RP " homepage="http://userweb.kernel.org/~kzak/util-linux-ng"