summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Duft <mduft@gentoo.org>2011-08-16 08:45:06 +0000
committerMarkus Duft <mduft@gentoo.org>2011-08-16 08:45:06 +0000
commitea4d6a9305198c00e9274692a5d87eb47cd0cb08 (patch)
treee68cfd366cc6e3d773520b65c3f3d3e1676f48fe /sys-libs/itx-bind
parentVersion bump. Remove old. Add -Wno-comment to build - bug #378099 (diff)
downloadgentoo-2-ea4d6a9305198c00e9274692a5d87eb47cd0cb08.tar.gz
gentoo-2-ea4d6a9305198c00e9274692a5d87eb47cd0cb08.tar.bz2
gentoo-2-ea4d6a9305198c00e9274692a5d87eb47cd0cb08.zip
remove gethostent.o, since this destroys gethostbyname from libc. move to main tree.
(Portage version: 2.2.01.19011-prefix/cvs/Linux i686)
Diffstat (limited to 'sys-libs/itx-bind')
-rw-r--r--sys-libs/itx-bind/ChangeLog17
-rw-r--r--sys-libs/itx-bind/itx-bind-0.1-r2.ebuild93
-rw-r--r--sys-libs/itx-bind/metadata.xml14
3 files changed, 124 insertions, 0 deletions
diff --git a/sys-libs/itx-bind/ChangeLog b/sys-libs/itx-bind/ChangeLog
new file mode 100644
index 000000000000..94832b2e80dd
--- /dev/null
+++ b/sys-libs/itx-bind/ChangeLog
@@ -0,0 +1,17 @@
+# ChangeLog for sys-libs/itx-bind
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/itx-bind/ChangeLog,v 1.1 2011/08/16 08:45:06 mduft Exp $
+
+*itx-bind-0.1-r2 (16 Aug 2011)
+
+ 16 Aug 2011; Markus Duft <mduft@gentoo.org> +itx-bind-0.1-r2.ebuild,
+ +metadata.xml:
+ remove gethostent.o, since this destroys gethostbyname from libc. move to
+ main tree.
+
+*itx-bind-0.1 (15 Jan 2010)
+
+ 15 Jan 2010; Markus Duft <mduft@gentoo.org> +itx-bind-0.1.ebuild,
+ +files/weak.s, +metadata.xml:
+ initial version of itx-bind
+
diff --git a/sys-libs/itx-bind/itx-bind-0.1-r2.ebuild b/sys-libs/itx-bind/itx-bind-0.1-r2.ebuild
new file mode 100644
index 000000000000..f217612b0ce5
--- /dev/null
+++ b/sys-libs/itx-bind/itx-bind-0.1-r2.ebuild
@@ -0,0 +1,93 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/itx-bind/itx-bind-0.1-r2.ebuild,v 1.1 2011/08/16 08:45:06 mduft Exp $
+
+EAPI=2
+
+inherit toolchain-funcs
+
+DESCRIPTION="the bind library for interix"
+HOMEPAGE="http://dev.gentoo.org/~mduft"
+SRC_URI=""
+
+LICENSE="as-is"
+SLOT="0"
+KEYWORDS="-* ~x86-interix"
+IUSE=""
+
+DEPEND=""
+RDEPEND=""
+
+src_install() {
+ # scratch together the pieces of the bind installation from all over the
+ # place on different interix systems, and copy the files to the local
+ # prefix installation.
+
+ if [[ -d /usr/local/bind ]]; then
+ # layout as of vista onwards.
+ local incdir="/usr/local/bind/include"
+ local libdir="/usr/local/lib/bind"
+ else
+ # layout of xp and server 2003
+ local incdir="/usr/local/include/bind"
+ local libdir="/usr/local/lib/bind"
+
+ # windows xp has a silly bug in the installer it seems:
+ [[ -x "${incdir}/sys" ]] || chmod a+x "${incdir}/sys"
+ fi
+
+ insinto /usr/include/bind
+
+ for obj in "${incdir}"/*; do
+ [[ -f "${obj}" ]] && doins "${obj}"
+ [[ -d "${obj}" ]] && doins -r "${obj}"
+ done
+
+ cd "${T}"
+ # wrap some symbols for the sake of configure link test. the libbind names
+ # symbols differently than required (some extra underscores), and renames
+ # them through the headers. however this is not enough, if configure checks
+ # don't include header files ... :(
+ $(tc-getCC) -c "${FILESDIR}"/weak.s
+
+ mkdir "${T}"/link || die "cannot mkdir"
+ cd "${T}"/link
+
+ # now for the _magic_ part...
+ ar -x "${libdir}/libbind.a"
+ # permissions are _totally_ broken here...
+ chmod 666 *.o
+
+ # remove the gethostent.o file, since the contained gethostbyname* functions
+ # seem to not work on older interixen, whereas the libc contained versions
+ # do work well enough.
+ rm gethostent.o
+
+ # find libdb.a from the system - need the _oold_ one...
+ local mydb=
+
+ for mydb in \
+ "/usr/lib/x86/libdb.a" \
+ "/usr/lib/libdb.a"; do
+ if test -f "${mydb}"; then
+ break
+ fi
+ done
+
+ # this needs a _stoneage_ berkeley db, so we really need to take the
+ # systems instead if installing db ourselves. newer db's don't have the
+ # requested symbols (they do support it, but with a different name). Another
+ # option would be to generate wrapper symbols for the things needed, but i'd
+ # rather avoid doing so, since i don't know them all.
+ $(tc-getCC) -shared -Wl,-h,libbind.so.${PV} -o libbind.so.${PV} *.o \
+ ../weak.o "${mydb}" || die "cannot link shared libbind"
+
+ dolib.so libbind.so.${PV}
+
+ # to prevent accidental linking during configure tests of packages which are
+ # not prepared for itx-bind, install things in a separate directory.
+ # packages need to explicitly add this and the include directory for this to
+ # work!
+ dosym ../libbind.so.${PV} /usr/lib/bind/libbind.so
+ dosym ../libbind.so.${PV} /usr/lib/bind/libresolv.so # mean, huh? :)
+}
diff --git a/sys-libs/itx-bind/metadata.xml b/sys-libs/itx-bind/metadata.xml
new file mode 100644
index 000000000000..d7e5191a5c7e
--- /dev/null
+++ b/sys-libs/itx-bind/metadata.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>no-herd</herd>
+<maintainer>
+<email>mduft@gentoo.org</email>
+<name>Markus Duft</name>
+</maintainer>
+<longdescription lang="en">
+ bind library based on the interix' host bind library. the host library
+ is linked into a shared library, wrapping some symbols to more common names
+</longdescription>
+</pkgmetadata>
+