summaryrefslogtreecommitdiff
path: root/sys-fs
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2016-08-09 23:11:45 +0800
committerMike Frysinger <vapier@gentoo.org>2016-08-09 23:15:10 +0800
commitd45e1ea18c1302c70d994efd8651717b536b9961 (patch)
tree8f9b752df181a7fabf38646f4ccef0ad2d5d6e92 /sys-fs
parentnet-libs/gnutls: cleanup (diff)
downloadgentoo-d45e1ea18c1302c70d994efd8651717b536b9961.tar.gz
gentoo-d45e1ea18c1302c70d994efd8651717b536b9961.tar.bz2
gentoo-d45e1ea18c1302c70d994efd8651717b536b9961.zip
sys-fs/xfsprogs: version bump to 4.7.0
Diffstat (limited to 'sys-fs')
-rw-r--r--sys-fs/xfsprogs/Manifest1
-rw-r--r--sys-fs/xfsprogs/files/xfsprogs-4.7.0-libxcmd-link.patch30
-rw-r--r--sys-fs/xfsprogs/files/xfsprogs-4.7.0-sharedlibs.patch81
-rw-r--r--sys-fs/xfsprogs/xfsprogs-4.7.0.ebuild95
4 files changed, 207 insertions, 0 deletions
diff --git a/sys-fs/xfsprogs/Manifest b/sys-fs/xfsprogs/Manifest
index 04a286b6809d..ea7c845313a9 100644
--- a/sys-fs/xfsprogs/Manifest
+++ b/sys-fs/xfsprogs/Manifest
@@ -4,3 +4,4 @@ DIST xfsprogs-3.2.4.tar.gz 1482424 SHA256 dde65ead82d3cbfa9b4ded9796b6d22095d7d7
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
DIST xfsprogs-4.5.0.tar.gz 1524382 SHA256 e49beb314984efbd0d758abb5c6137db3bb60a88e59e1e94c00defb536cf89f8 SHA512 19c95551dc91ec46916f9a7e3d7976907664d32dd5fdc26af0ca62ca74c4b3c10f9e843aac8214ea9d1c0bf140c9f4e321d059808af01a623abedd5067011314 WHIRLPOOL 54d742635df024a63181da76c3220671610068363af85be2677521f20342595a5cebb2fd169945572351901ee2c9384f79f54a381ab3620dde22d863aa66d469
+DIST xfsprogs-4.7.0.tar.gz 1534909 SHA256 88580bb3e6847c3edef436703a4fae403fc19b20739db4c31166ee4b256178d7 SHA512 5184f1dbc3989f3c1f1b103d5cbd70462db107cfe113424166581ebcfaad4041c9c78f5d038f4bd4728ff99a2f9705219582ba9bfd10745354a1cab0b7dfe613 WHIRLPOOL 8157b2e8df5946acacc22ed761e38b382ef464f4984971148069b2f215418f4e23ac142721394439c041c236cbd460e0b56ff071d1c10e343070147709f42af3
diff --git a/sys-fs/xfsprogs/files/xfsprogs-4.7.0-libxcmd-link.patch b/sys-fs/xfsprogs/files/xfsprogs-4.7.0-libxcmd-link.patch
new file mode 100644
index 000000000000..77ded5393d52
--- /dev/null
+++ b/sys-fs/xfsprogs/files/xfsprogs-4.7.0-libxcmd-link.patch
@@ -0,0 +1,30 @@
+From d01d3689fd512811b9d860598ddf26089bb5955c Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Tue, 9 Aug 2016 22:37:45 +0800
+Subject: [PATCH xfsprogs] libxcmd: link against used libs
+
+Since this lib uses symbols from libxfs (platform_findsizes) and many
+symbols from libblkid, link against both. Otherwise, the resulting
+shared lib has missing symbols which makes linking against annoying.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ libxcmd/Makefile | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/libxcmd/Makefile b/libxcmd/Makefile
+index aab8d6d63624..46ba138a37e2 100644
+--- a/libxcmd/Makefile
++++ b/libxcmd/Makefile
+@@ -12,6 +12,8 @@ LT_AGE = 0
+
+ CFILES = command.c input.c paths.c projects.c help.c quit.c topology.c
+
++LTLIBS = $(LIBXFS) $(LIBBLKID)
++
+ ifeq ($(HAVE_GETMNTENT),yes)
+ LCFLAGS += -DHAVE_GETMNTENT
+ endif
+--
+2.9.0
+
diff --git a/sys-fs/xfsprogs/files/xfsprogs-4.7.0-sharedlibs.patch b/sys-fs/xfsprogs/files/xfsprogs-4.7.0-sharedlibs.patch
new file mode 100644
index 000000000000..b5395ffaed6c
--- /dev/null
+++ b/sys-fs/xfsprogs/files/xfsprogs-4.7.0-sharedlibs.patch
@@ -0,0 +1,81 @@
+--- xfsprogs-4.7.0/include/buildmacros
++++ xfsprogs-4.7.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.7.0/libhandle/Makefile
++++ xfsprogs-4.7.0/libhandle/Makefile
+@@ -24,7 +24,6 @@
+ include $(BUILDRULES)
+
+ install: default
+- $(INSTALL_LTLIB)
+
+ install-dev: default
+ $(INSTALL_LTLIB_DEV)
+--- xfsprogs-4.7.0/libxcmd/Makefile
++++ xfsprogs-4.7.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.7.0/libxfs/Makefile
++++ xfsprogs-4.7.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.7.0/libxlog/Makefile
++++ xfsprogs-4.7.0/libxlog/Makefile
+@@ -19,6 +21,9 @@
+
+ include $(BUILDRULES)
+
+-install install-dev: default
++install: default
++
++install-dev: default
++ $(INSTALL_LTLIB_DEV)
+
+ -include .ltdep
+--- xfsprogs-4.7.0/Makefile
++++ xfsprogs-4.7.0/Makefile
+@@ -83,6 +83,8 @@
+ repair: libxlog libxcmd
+ copy: libxlog
+ mkfs: libxcmd
++libxlog: libxfs
++libxlog-install-dev: libxfs-install-dev
+
+ ifeq ($(HAVE_BUILDDEFS), yes)
+ include $(BUILDRULES)
diff --git a/sys-fs/xfsprogs/xfsprogs-4.7.0.ebuild b/sys-fs/xfsprogs/xfsprogs-4.7.0.ebuild
new file mode 100644
index 000000000000..269f2ce63fcc
--- /dev/null
+++ b/sys-fs/xfsprogs/xfsprogs-4.7.0.ebuild
@@ -0,0 +1,95 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+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:0=[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:0=[static-libs] )
+ )
+ nls? ( sys-devel/gettext )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.7.0-sharedlibs.patch
+ "${FILESDIR}"/${PN}-4.7.0-libxcmd-link.patch
+ "${FILESDIR}"/${PN}-4.3.0-cross-compile.patch
+)
+
+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 "${PATCHES[@]}"
+
+ # 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' {} +
+
+ # TODO: Write a patch for configure.ac to use pkg-config for the uuid-part.
+ if use static && use readline ; then
+ sed -i \
+ -e 's|-lreadline|& -lncurses|' \
+ -e 's|-lblkid|& -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 \
+ $(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 handle xcmd xfs xlog
+ # removing unnecessary .la files if not needed
+ use static-libs || find "${ED}" -name '*.la' -delete
+}