diff options
author | Mike Frysinger <vapier@gentoo.org> | 2013-03-20 06:05:50 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2013-03-20 06:05:50 +0000 |
commit | b061ac0acb656f250feaa4a866c659b1c0eea59f (patch) | |
tree | fb0263ed255e767b91929f6bae9e29696a4789ee /sys-apps/attr | |
parent | Move builtins section before permissions section in /lib/udev/rules.d/50-udev... (diff) | |
download | gentoo-2-b061ac0acb656f250feaa4a866c659b1c0eea59f.tar.gz gentoo-2-b061ac0acb656f250feaa4a866c659b1c0eea59f.tar.bz2 gentoo-2-b061ac0acb656f250feaa4a866c659b1c0eea59f.zip |
Add fix by Riku Voipio for getting syscall numbers from system headers rather than hardcoding the list locally. This fixes the build for hppa, aarch64, and probably others. Noticed in #460702 by Jeroen Roovers.
(Portage version: 2.2.0_alpha164/cvs/Linux x86_64, signed Manifest commit with key FB7C4156)
Diffstat (limited to 'sys-apps/attr')
-rw-r--r-- | sys-apps/attr/ChangeLog | 10 | ||||
-rw-r--r-- | sys-apps/attr/attr-2.4.46-r2.ebuild | 54 | ||||
-rw-r--r-- | sys-apps/attr/files/attr-2.4.46-generic-syscalls.patch | 180 |
3 files changed, 243 insertions, 1 deletions
diff --git a/sys-apps/attr/ChangeLog b/sys-apps/attr/ChangeLog index 9acb922958cb..83d7d01f95a8 100644 --- a/sys-apps/attr/ChangeLog +++ b/sys-apps/attr/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for sys-apps/attr # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/attr/ChangeLog,v 1.143 2013/02/19 04:56:16 zmedico Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-apps/attr/ChangeLog,v 1.144 2013/03/20 06:05:50 vapier Exp $ + +*attr-2.4.46-r2 (20 Mar 2013) + + 20 Mar 2013; Mike Frysinger <vapier@gentoo.org> +attr-2.4.46-r2.ebuild, + +files/attr-2.4.46-generic-syscalls.patch: + Add fix by Riku Voipio for getting syscall numbers from system headers rather + than hardcoding the list locally. This fixes the build for hppa, aarch64, and + probably others. Noticed in #460702 by Jeroen Roovers. 19 Feb 2013; Zac Medico <zmedico@gentoo.org> attr-2.4.46-r1.ebuild: Add ~arm-linux keyword. diff --git a/sys-apps/attr/attr-2.4.46-r2.ebuild b/sys-apps/attr/attr-2.4.46-r2.ebuild new file mode 100644 index 000000000000..d42abbe1d173 --- /dev/null +++ b/sys-apps/attr/attr-2.4.46-r2.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/attr/attr-2.4.46-r2.ebuild,v 1.1 2013/03/20 06:05:50 vapier Exp $ + +EAPI="4" + +inherit eutils toolchain-funcs + +DESCRIPTION="Extended attributes tools" +HOMEPAGE="http://savannah.nongnu.org/projects/attr" +SRC_URI="mirror://nongnu/${PN}/${P}.src.tar.gz" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~arm-linux ~x86-linux" +IUSE="nls static-libs" + +DEPEND="nls? ( sys-devel/gettext ) + sys-devel/autoconf" +RDEPEND="" + +src_prepare() { + epatch "${FILESDIR}"/${PN}-2.4.44-gettext.patch + epatch "${FILESDIR}"/${PN}-2.4.46-config-shell.patch #366671 + epatch "${FILESDIR}"/${PN}-2.4.46-generic-syscalls.patch #460702 + sed -i \ + -e "/^PKG_DOC_DIR/s:@pkg_name@:${PF}:" \ + -e '/HAVE_ZIPPED_MANPAGES/s:=.*:=false:' \ + include/builddefs.in \ + || die "failed to update builddefs" + strip-linguas -u po +} + +src_configure() { + unset PLATFORM #184564 + export OPTIMIZER=${CFLAGS} + export DEBUG=-DNDEBUG + + econf \ + $(use_enable nls gettext) \ + --enable-shared $(use_enable static-libs static) \ + --libexecdir="${EPREFIX}"/usr/$(get_libdir) \ + --bindir="${EPREFIX}"/bin +} + +src_install() { + emake DIST_ROOT="${D}" install install-lib install-dev || die + use static-libs || find "${D}" -name '*.la' -delete + # the man-pages packages provides the man2 files + rm -r "${ED}"/usr/share/man/man2 + + # we install attr into /bin, so we need the shared lib with it + gen_usr_ldscript -a attr +} diff --git a/sys-apps/attr/files/attr-2.4.46-generic-syscalls.patch b/sys-apps/attr/files/attr-2.4.46-generic-syscalls.patch new file mode 100644 index 000000000000..d12fcd29afd1 --- /dev/null +++ b/sys-apps/attr/files/attr-2.4.46-generic-syscalls.patch @@ -0,0 +1,180 @@ +http://lists.nongnu.org/archive/html/acl-devel/2012-12/msg00000.html +https://bugs.gentoo.org/460702 + +--- a/libattr/syscalls.c ++++ b/libattr/syscalls.c +@@ -23,172 +23,10 @@ + + #include <errno.h> + #include <unistd.h> ++#include <sys/syscall.h> + +-#if defined (__i386__) ++#if defined (__NR_setxattr) + # define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 226 +-# define __NR_lsetxattr 227 +-# define __NR_fsetxattr 228 +-# define __NR_getxattr 229 +-# define __NR_lgetxattr 230 +-# define __NR_fgetxattr 231 +-# define __NR_listxattr 232 +-# define __NR_llistxattr 233 +-# define __NR_flistxattr 234 +-# define __NR_removexattr 235 +-# define __NR_lremovexattr 236 +-# define __NR_fremovexattr 237 +-#elif defined (__sparc__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 169 +-# define __NR_lsetxattr 170 +-# define __NR_fsetxattr 171 +-# define __NR_getxattr 172 +-# define __NR_lgetxattr 173 +-# define __NR_fgetxattr 177 +-# define __NR_listxattr 178 +-# define __NR_llistxattr 179 +-# define __NR_flistxattr 180 +-# define __NR_removexattr 181 +-# define __NR_lremovexattr 182 +-# define __NR_fremovexattr 186 +-#elif defined (__ia64__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 1217 +-# define __NR_lsetxattr 1218 +-# define __NR_fsetxattr 1219 +-# define __NR_getxattr 1220 +-# define __NR_lgetxattr 1221 +-# define __NR_fgetxattr 1222 +-# define __NR_listxattr 1223 +-# define __NR_llistxattr 1224 +-# define __NR_flistxattr 1225 +-# define __NR_removexattr 1226 +-# define __NR_lremovexattr 1227 +-# define __NR_fremovexattr 1228 +-#elif defined (__powerpc__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 209 +-# define __NR_lsetxattr 210 +-# define __NR_fsetxattr 211 +-# define __NR_getxattr 212 +-# define __NR_lgetxattr 213 +-# define __NR_fgetxattr 214 +-# define __NR_listxattr 215 +-# define __NR_llistxattr 216 +-# define __NR_flistxattr 217 +-# define __NR_removexattr 218 +-# define __NR_lremovexattr 219 +-# define __NR_fremovexattr 220 +-#elif defined (__x86_64__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 188 +-# define __NR_lsetxattr 189 +-# define __NR_fsetxattr 190 +-# define __NR_getxattr 191 +-# define __NR_lgetxattr 192 +-# define __NR_fgetxattr 193 +-# define __NR_listxattr 194 +-# define __NR_llistxattr 195 +-# define __NR_flistxattr 196 +-# define __NR_removexattr 197 +-# define __NR_lremovexattr 198 +-# define __NR_fremovexattr 199 +-#elif defined (__s390__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 224 +-# define __NR_lsetxattr 225 +-# define __NR_fsetxattr 226 +-# define __NR_getxattr 227 +-# define __NR_lgetxattr 228 +-# define __NR_fgetxattr 229 +-# define __NR_listxattr 230 +-# define __NR_llistxattr 231 +-# define __NR_flistxattr 232 +-# define __NR_removexattr 233 +-# define __NR_lremovexattr 234 +-# define __NR_fremovexattr 235 +-#elif defined (__arm__) +-# define HAVE_XATTR_SYSCALLS 1 +-# if defined(__ARM_EABI__) || defined(__thumb__) +-# define __NR_SYSCALL_BASE 0 +-# else +-# define __NR_SYSCALL_BASE 0x900000 +-# endif +-# define __NR_setxattr (__NR_SYSCALL_BASE+226) +-# define __NR_lsetxattr (__NR_SYSCALL_BASE+227) +-# define __NR_fsetxattr (__NR_SYSCALL_BASE+228) +-# define __NR_getxattr (__NR_SYSCALL_BASE+229) +-# define __NR_lgetxattr (__NR_SYSCALL_BASE+230) +-# define __NR_fgetxattr (__NR_SYSCALL_BASE+231) +-# define __NR_listxattr (__NR_SYSCALL_BASE+232) +-# define __NR_llistxattr (__NR_SYSCALL_BASE+233) +-# define __NR_flistxattr (__NR_SYSCALL_BASE+234) +-# define __NR_removexattr (__NR_SYSCALL_BASE+235) +-# define __NR_lremovexattr (__NR_SYSCALL_BASE+236) +-# define __NR_fremovexattr (__NR_SYSCALL_BASE+237) +-#elif defined (__mips64) +-# define HAVE_XATTR_SYSCALLS 1 +-# ifdef __LP64__ /* mips64 using n64 ABI */ +-# define __NR_Linux 5000 +-# else /* mips64 using n32 ABI */ +-# define __NR_Linux 6000 +-# endif +-# define __NR_setxattr (__NR_Linux + 180) +-# define __NR_lsetxattr (__NR_Linux + 181) +-# define __NR_fsetxattr (__NR_Linux + 182) +-# define __NR_getxattr (__NR_Linux + 183) +-# define __NR_lgetxattr (__NR_Linux + 184) +-# define __NR_fgetxattr (__NR_Linux + 185) +-# define __NR_listxattr (__NR_Linux + 186) +-# define __NR_llistxattr (__NR_Linux + 187) +-# define __NR_flistxattr (__NR_Linux + 188) +-# define __NR_removexattr (__NR_Linux + 189) +-# define __NR_lremovexattr (__NR_Linux + 190) +-# define __NR_fremovexattr (__NR_Linux + 191) +-#elif defined (__mips__) /* mips32, or mips64 using o32 ABI */ +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_Linux 4000 +-# define __NR_setxattr (__NR_Linux + 224) +-# define __NR_lsetxattr (__NR_Linux + 225) +-# define __NR_fsetxattr (__NR_Linux + 226) +-# define __NR_getxattr (__NR_Linux + 227) +-# define __NR_lgetxattr (__NR_Linux + 228) +-# define __NR_fgetxattr (__NR_Linux + 229) +-# define __NR_listxattr (__NR_Linux + 230) +-# define __NR_llistxattr (__NR_Linux + 231) +-# define __NR_flistxattr (__NR_Linux + 232) +-# define __NR_removexattr (__NR_Linux + 233) +-# define __NR_lremovexattr (__NR_Linux + 234) +-# define __NR_fremovexattr (__NR_Linux + 235) +-#elif defined (__alpha__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 382 +-# define __NR_lsetxattr 383 +-# define __NR_fsetxattr 384 +-# define __NR_getxattr 385 +-# define __NR_lgetxattr 386 +-# define __NR_fgetxattr 387 +-# define __NR_listxattr 388 +-# define __NR_llistxattr 389 +-# define __NR_flistxattr 390 +-# define __NR_removexattr 391 +-# define __NR_lremovexattr 392 +-# define __NR_fremovexattr 393 +-#elif defined (__mc68000__) +-# define HAVE_XATTR_SYSCALLS 1 +-# define __NR_setxattr 223 +-# define __NR_lsetxattr 224 +-# define __NR_fsetxattr 225 +-# define __NR_getxattr 226 +-# define __NR_lgetxattr 227 +-# define __NR_fgetxattr 228 +-# define __NR_listxattr 229 +-# define __NR_llistxattr 230 +-# define __NR_flistxattr 231 +-# define __NR_removexattr 232 +-# define __NR_lremovexattr 233 +-# define __NR_fremovexattr 234 + #else + # warning "Extended attribute syscalls undefined for this architecture" + # define HAVE_XATTR_SYSCALLS 0 |