summaryrefslogtreecommitdiff
path: root/eclass/libtool.eclass
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /eclass/libtool.eclass
reinit the tree, so we can have metadata
Diffstat (limited to 'eclass/libtool.eclass')
-rw-r--r--eclass/libtool.eclass44
1 files changed, 44 insertions, 0 deletions
diff --git a/eclass/libtool.eclass b/eclass/libtool.eclass
new file mode 100644
index 000000000000..2e0f608d342f
--- /dev/null
+++ b/eclass/libtool.eclass
@@ -0,0 +1,44 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+# @ECLASS: libtool.eclass
+# @MAINTAINER:
+# base-system@gentoo.org
+# @BLURB: quickly update bundled libtool code
+# @DESCRIPTION:
+# This eclass patches ltmain.sh distributed with libtoolized packages with the
+# relink and portage patch among others
+#
+# Note, this eclass does not require libtool as it only applies patches to
+# generated libtool files. We do not run the libtoolize program because that
+# requires a regeneration of the main autotool files in order to work properly.
+
+if [[ -z ${_LIBTOOL_ECLASS} ]]; then
+_LIBTOOL_ECLASS=1
+
+DEPEND=">=app-portage/elt-patches-20170422"
+
+inherit toolchain-funcs
+
+# @FUNCTION: elibtoolize
+# @USAGE: [dirs] [--portage] [--reverse-deps] [--patch-only] [--remove-internal-dep=xxx] [--shallow] [--no-uclibc]
+# @DESCRIPTION:
+# Apply a smorgasbord of patches to bundled libtool files. This function
+# should always be safe to run. If no directories are specified, then
+# ${S} will be searched for appropriate files.
+#
+# If the --shallow option is used, then only ${S}/ltmain.sh will be patched.
+#
+# The other options should be avoided in general unless you know what's going on.
+elibtoolize() {
+ type -P eltpatch &>/dev/null || die "eltpatch not found; is app-portage/elt-patches installed?"
+
+ ELT_LOGDIR=${T} \
+ LD=$(tc-getLD) \
+ eltpatch "${@}" || die "eltpatch failed"
+}
+
+uclibctoolize() { die "Use elibtoolize"; }
+darwintoolize() { die "Use elibtoolize"; }
+
+fi