From 3b5d677a36201cf544338abd04bbb08d6fc1caa8 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Thu, 25 Aug 2011 18:08:43 -0400 Subject: [PATCH] attr: import current stable from upstream Gentoo BUG=None TEST=updated attr, rebuilt x86-alex from source, booted it Change-Id: I31d1ce836ee29531c2ea0b388fb04be425b59a00 Reviewed-on: http://gerrit.chromium.org/gerrit/6738 Reviewed-by: David James Tested-by: Mike Frysinger --- .../sys-apps/attr/attr-2.4.46.ebuild | 53 ++++++++++++++++ .../attr/files/attr-2.4.44-gettext.patch | 63 +++++++++++++++++++ .../attr/files/attr-2.4.46-config-shell.patch | 53 ++++++++++++++++ 3 files changed, 169 insertions(+) create mode 100644 sdk_container/src/third_party/portage-stable/sys-apps/attr/attr-2.4.46.ebuild create mode 100644 sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.44-gettext.patch create mode 100644 sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.46-config-shell.patch diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/attr/attr-2.4.46.ebuild b/sdk_container/src/third_party/portage-stable/sys-apps/attr/attr-2.4.46.ebuild new file mode 100644 index 0000000000..05d6ff0a46 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/attr/attr-2.4.46.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2011 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.ebuild,v 1.6 2011/08/21 13:44:59 nixnut 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" +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 + 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=/usr/$(get_libdir) \ + --bindir=/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 "${D}"/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/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.44-gettext.patch b/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.44-gettext.patch new file mode 100644 index 0000000000..49c2d32bdc --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.44-gettext.patch @@ -0,0 +1,63 @@ +--- include/gettext.h ++++ include/gettext.h +@@ -0,0 +1,10 @@ ++#include ++#ifdef ENABLE_GETTEXT ++# include ++# define _(x) gettext(x) ++#else ++# define _(x) (x) ++# define textdomain(d) do { } while (0) ++# define bindtextdomain(d,dir) do { } while (0) ++#endif ++#include +--- attr/attr.c ++++ attr/attr.c +@@ -26,6 +26,7 @@ + #include + #include + #include ++#include "gettext.h" + + #include + #include "config.h" +--- libattr/attr_copy_file.c.orig 2007-09-20 02:51:37.000000000 -0400 ++++ libattr/attr_copy_file.c 2007-09-20 02:51:51.000000000 -0400 +@@ -19,6 +19,7 @@ + + #if defined (HAVE_CONFIG_H) + #include "config.h" ++#include "gettext.h" + #endif + + #include +--- libattr/attr_copy_fd.c.orig 2007-09-20 02:52:23.000000000 -0400 ++++ libattr/attr_copy_fd.c 2007-09-20 02:52:31.000000000 -0400 +@@ -19,6 +19,7 @@ + + #if defined (HAVE_CONFIG_H) + #include "config.h" ++#include "gettext.h" + #endif + + #include +--- getfattr/getfattr.c.orig 2007-09-20 02:52:49.000000000 -0400 ++++ getfattr/getfattr.c 2007-09-20 02:52:59.000000000 -0400 +@@ -30,6 +30,7 @@ + #include + #include + #include ++#include "gettext.h" + + #include + #include "config.h" +--- setfattr/setfattr.c.orig 2007-09-20 02:53:12.000000000 -0400 ++++ setfattr/setfattr.c 2007-09-20 02:53:20.000000000 -0400 +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include "gettext.h" + + #include + #include "config.h" diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.46-config-shell.patch b/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.46-config-shell.patch new file mode 100644 index 0000000000..b6660e63c0 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/attr/files/attr-2.4.46-config-shell.patch @@ -0,0 +1,53 @@ +https://bugs.gentoo.org/366671 + +From 10bfb16245ec4b55c1f5b6dc5554913bc9b13c9c Mon Sep 17 00:00:00 2001 +From: Mike Frysinger +Date: Mon, 16 May 2011 01:59:52 -0400 +Subject: [PATCH] use SHELL from configure + +If /bin/sh is not a functional enough shell, configure will select a +SHELL of /bin/bash or better. But the current build helpers always +hardcode /bin/sh, so if libtool itself configures itself for /bin/bash, +things will fail when it attempts to do: + SHELL = /bin/sh + LIBTOOL = $(SHELL) .../libtool + ... + eval: 1: base_compile+= -pipe: not found + ... + +So rather than hardcoding SHELL to /bin/sh, set it to @SHELL@ and let +configure find a good value for us. + +Signed-off-by: Mike Frysinger +--- + include/builddefs.in | 1 + + include/buildmacros | 1 - + 2 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/include/builddefs.in b/include/builddefs.in +index d054a56..434ce95 100644 +--- a/include/builddefs.in ++++ b/include/builddefs.in +@@ -46,6 +46,7 @@ MAKE = @make@ + ECHO = @echo@ + SORT = @sort@ + LN_S = @LN_S@ ++SHELL = @SHELL@ + LIBTOOL = @LIBTOOL@ + MAKEDEPEND = @makedepend@ + +diff --git a/include/buildmacros b/include/buildmacros +index ab89182..8efb32e 100644 +--- a/include/buildmacros ++++ b/include/buildmacros +@@ -42,7 +42,6 @@ OBJECTS = $(ASFILES:.s=.o) \ + + INSTALL = $(TOPDIR)/include/install-sh -o $(PKG_USER) -g $(PKG_GROUP) + +-SHELL = /bin/sh + IMAGES_DIR = $(TOPDIR)/all-images + DIST_DIR = $(TOPDIR)/dist + +-- +1.7.5.rc3 +