commit:     583631a15d2ebc41d58009434f60897281bcc9c7
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 23 21:24:11 2015 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon Nov 23 21:24:31 2015 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=583631a1

sys-fs/xfsprogs: Bump to version 4.3.0

Package-Manager: portage-2.2.25
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 sys-fs/xfsprogs/Manifest                           |  1 +
 .../xfsprogs/files/xfsprogs-4.3.0-sharedlibs.patch | 80 ++++++++++++++++++
 sys-fs/xfsprogs/xfsprogs-4.3.0.ebuild              | 97 ++++++++++++++++++++++
 3 files changed, 178 insertions(+)

diff --git a/sys-fs/xfsprogs/Manifest b/sys-fs/xfsprogs/Manifest
index 514ee0e..a60ce64 100644
--- a/sys-fs/xfsprogs/Manifest
+++ b/sys-fs/xfsprogs/Manifest
@@ -2,3 +2,4 @@ DIST xfsprogs-3.1.10.tar.gz 1375721 SHA256 
9ec8dc77bf3bc114c3ba89f87316a32e3097e
 DIST xfsprogs-3.1.11.tar.gz 1399833 SHA256 
adf4980177b5c890c1ca86b9c0e3e4d69a3f95bfc01746844280c2393cf4d6be SHA512 
6de16f0904709e53e6ceea8239e23b7e109375733fd712fd97bfbbf74ec7f1376147e61d1fbe498f1d5be2148bf8ca233c0577d5b88e9201bfd4bb87e696c28a
 WHIRLPOOL 
d52f177d172940e46c813575459917d73042739629f83537932eff38b28a524956484ad6ebbbd2d5d698f1a4b60c1a0f127ca1dd22bba86dcd74c5b94bf51962
 DIST xfsprogs-3.2.4.tar.gz 1482424 SHA256 
dde65ead82d3cbfa9b4ded9796b6d22095d7d759a22d41ae6f1a4ec458bb0465 SHA512 
fb1ea5beb933b86970cac198fa4e296457f0f5b30bd72fda54452644730277929dee28f11f35a154910e4a19857455ecffdd21b3df456023e0da95e2fd0aa0eb
 WHIRLPOOL 
dec87905b5a5af053e71e88f1670470c00b94a758dbb77773adbc601db61b4efaaba306f344a4334b11680973d5153fcc7f8b5d59c4698f21d654570e8355fe9
 DIST xfsprogs-4.2.0.tar.gz 1487831 SHA256 
3deab1ad0f4635e54053aa45add27bd48cd87a188c16ac60f4789e01730e5260 SHA512 
1bafa9b8eeb834126d02e6e4d582e3ac637ca81c3dc262e3cd742fcc43679ac11a8aa160964264267bc2793822b6af8de87cc7a09c8a9e28826458b17b430620
 WHIRLPOOL 
a608a1b5cad9d22deb26836432730b47ec7a270bbb0e7ff1e41e5a169b5bae5baf143d63129a0ea1936d73a9c479e8787701f9437fdcea2680a41097d64a3437
+DIST xfsprogs-4.3.0.tar.gz 1496635 SHA256 
3e570ad51153e4be3792f42b2c805ddbd46b55d166eba3102ec87d5006d4cb5c SHA512 
c19c07497eb78dd2beb6dc35b8c21abf5fa3ac164eed32f7b95b71d460c8f08bba5550ecc156fafe412bf1b5452e40180e6fcd439d289a660afd594477f209d2
 WHIRLPOOL 
99661abf6bc31c2ab2e504cdfbcceea2e86b55faed02ec3da0c9d31830b213ae9eb42dc1bcf2612dbbfe2866b538f05f7bb97a60a9ed24a36af0846981825fde

diff --git a/sys-fs/xfsprogs/files/xfsprogs-4.3.0-sharedlibs.patch 
b/sys-fs/xfsprogs/files/xfsprogs-4.3.0-sharedlibs.patch
new file mode 100644
index 0000000..a39af0d
--- /dev/null
+++ b/sys-fs/xfsprogs/files/xfsprogs-4.3.0-sharedlibs.patch
@@ -0,0 +1,80 @@
+--- xfsprogs-4.3.0/include/buildmacros
++++ xfsprogs-4.3.0/include/buildmacros
+@@ -70,18 +70,9 @@
+ # /usr/lib.
+ ifeq ($(ENABLE_SHARED),yes)
+ INSTALL_LTLIB_DEV = \
+-      cd $(TOPDIR)/$(LIBNAME)/.libs; \
+-      ../$(INSTALL) -m 755 -d $(PKG_LIB_DIR); \
+-      ../$(INSTALL) -m 644 -T old_lib $(LIBNAME).lai $(PKG_LIB_DIR); \
+-      ../$(INSTALL) -m 644 $(LIBNAME).lai $(PKG_LIB_DIR)/$(LIBNAME).la ; \
+-      ../$(INSTALL) -m 755 -d $(PKG_ROOT_LIB_DIR); \
+-      ../$(INSTALL) -T so_base $(LIBNAME).lai $(PKG_ROOT_LIB_DIR); \
+-      if [ "x$(shell readlink -f $(PKG_LIB_DIR))" != \
+-           "x$(shell readlink -f $(PKG_ROOT_LIB_DIR))" ]; then \
+-              ../$(INSTALL) -S $(PKG_LIB_DIR)/$(LIBNAME).a 
$(PKG_ROOT_LIB_DIR)/$(LIBNAME).a; \
+-              ../$(INSTALL) -S $(PKG_LIB_DIR)/$(LIBNAME).la 
$(PKG_ROOT_LIB_DIR)/$(LIBNAME).la; \
+-              ../$(INSTALL) -S $(PKG_ROOT_LIB_DIR)/$(LIBNAME).so 
$(PKG_LIB_DIR)/$(LIBNAME).so; \
+-      fi
++      set -e; cd $(TOPDIR)/$(LIBNAME); \
++      $(INSTALL) -m 755 -d $(PKG_LIB_DIR); \
++      env -uDIST_ROOT $(LTINSTALL) $(TOPDIR)/$(LIBNAME)/$(LIBNAME).la 
$(DIST_ROOT)$(PKG_LIB_DIR)/$(LIBNAME).la
+ else
+ INSTALL_LTLIB_DEV = $(INSTALL_LTLIB_STATIC)
+ endif
+--- xfsprogs-4.3.0/libxcmd/Makefile
++++ xfsprogs-4.3.0/libxcmd/Makefile
+@@ -34,6 +34,9 @@
+ 
+ include $(BUILDRULES)
+ 
+-install install-dev: default
++install: default
++
++install-dev: default
++      $(INSTALL_LTLIB_DEV)
+ 
+ -include .ltdep
+--- xfsprogs-4.3.0/libxfs/Makefile
++++ xfsprogs-4.3.0/libxfs/Makefile
+@@ -138,6 +138,7 @@
+ 
+ install-dev: install
+       $(INSTALL) -m 644 $(PKGHFILES) $(PKG_INC_DIR)
++      $(INSTALL_LTLIB_DEV)
+ 
+ # We need to install the headers before building the dependencies.  If we
+ # include the .ltdep file, the makefile decides that it needs to build the
+--- xfsprogs-4.3.0/libxlog/Makefile
++++ xfsprogs-4.3.0/libxlog/Makefile
+@@ -12,6 +12,8 @@
+ 
+ CFILES = xfs_log_recover.c util.c
+ 
++LTLIBS = $(LIBUUID) $(LIBXFS)
++
+ # don't want to link xfs_repair with a debug libxlog.
+ DEBUG = -DNDEBUG
+ 
+@@ -19,6 +21,9 @@
+ 
+ include $(BUILDRULES)
+ 
+-install install-dev: default
++install: default
++
++install-dev: default
++      $(INSTALL_LTLIB_DEV)
+ 
+ -include .ltdep
+--- xfsprogs-4.3.0/Makefile
++++ xfsprogs-4.3.0/Makefile
+@@ -82,6 +82,8 @@
+ quota: libxcmd
+ repair: libxlog
+ copy: libxlog
++libxlog: libxfs
++libxlog-install-dev: libxfs-install-dev
+ 
+ ifeq ($(HAVE_BUILDDEFS), yes)
+ include $(BUILDRULES)

diff --git a/sys-fs/xfsprogs/xfsprogs-4.3.0.ebuild 
b/sys-fs/xfsprogs/xfsprogs-4.3.0.ebuild
new file mode 100644
index 0000000..ec9af10
--- /dev/null
+++ b/sys-fs/xfsprogs/xfsprogs-4.3.0.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit eutils toolchain-funcs multilib
+
+DESCRIPTION="xfs filesystem utilities"
+HOMEPAGE="http://oss.sgi.com/projects/xfs/";
+SRC_URI="ftp://oss.sgi.com/projects/xfs/cmd_tars/${P}.tar.gz
+       ftp://oss.sgi.com/projects/xfs/previous/cmd_tars/${P}.tar.gz";
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc 
~x86"
+IUSE="libedit nls readline static static-libs"
+REQUIRED_USE="static? ( static-libs )"
+
+LIB_DEPEND=">=sys-apps/util-linux-2.17.2[static-libs(+)]
+       readline? ( sys-libs/readline[static-libs(+)] )
+       !readline? ( libedit? ( dev-libs/libedit[static-libs(+)] ) )"
+RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} )
+       !<sys-fs/xfsdump-3"
+DEPEND="${RDEPEND}
+       static? (
+               ${LIB_DEPEND}
+               readline? ( sys-libs/ncurses[static-libs] )
+       )
+       nls? ( sys-devel/gettext )"
+
+pkg_setup() {
+       if use readline && use libedit ; then
+               ewarn "You have USE='readline libedit' but these are exclusive."
+               ewarn "Defaulting to readline; please disable this USE flag if 
you want libedit."
+       fi
+}
+
+src_prepare() {
+       epatch "${FILESDIR}"/${PN}-4.3.0-sharedlibs.patch
+
+       # LLDFLAGS is used for programs, so apply -all-static when USE=static 
is enabled.
+       # Clear out -static from all flags since we want to link against 
dynamic xfs libs.
+       sed -i \
+               -e "/^PKG_DOC_DIR/s:@pkg_name@:${PF}:" \
+               -e "1iLLDFLAGS += $(usex static '-all-static' '')" \
+               include/builddefs.in || die
+       find -name Makefile -exec \
+               sed -i -r -e '/^LLDFLAGS [+]?= -static(-libtool-libs)?$/d' {} +
+
+       # libdisk has broken blkid conditional checking
+       sed -i \
+               -e '/LIB_SUBDIRS/s:libdisk::' \
+               Makefile || die
+
+       # TODO: write a patch for configure.in to use pkg-config for the 
uuid-part
+       if use static && use readline ; then
+               sed -i \
+                       -e 's|-lreadline|\0 -lncurses|' \
+                       -e 's|-lblkid|\0 -luuid|' \
+                       configure || die
+       fi
+}
+
+src_configure() {
+       export DEBUG=-DNDEBUG
+       export OPTIMIZER=${CFLAGS}
+       unset PLATFORM # if set in user env, this breaks configure
+
+       local myconf
+       if use static || use static-libs ; then
+               myconf+=" --enable-static"
+       else
+               myconf+=" --disable-static"
+       fi
+
+       econf \
+               --bindir=/usr/bin \
+               --libexecdir=/usr/$(get_libdir) \
+               $(use_enable nls gettext) \
+               $(use_enable readline) \
+               $(usex readline --disable-editline $(use_enable libedit 
editline)) \
+               ${myconf}
+
+       MAKEOPTS+=" V=1"
+}
+
+src_install() {
+       emake DIST_ROOT="${ED}" install
+       # parallel install fails on this target for >=xfsprogs-3.2.0
+       emake -j1 DIST_ROOT="${ED}" install-dev
+
+       # handle is for xfsdump, the rest for xfsprogs
+       gen_usr_ldscript -a xfs xlog
+       # removing unnecessary .la files if not needed
+       use static-libs || find "${ED}" -name '*.la' -delete
+}

Reply via email to