summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Gabert <pappy@gentoo.org>2008-04-27 23:17:42 +0000
committerAlexander Gabert <pappy@gentoo.org>2008-04-27 23:17:42 +0000
commit4fed2dcd241627296aedb63bfaa19c427aa431a8 (patch)
tree830addc317430160bb5def08c148f3755cdd8dd7 /sys-libs
parentStable for HPPA (bug #213588). (diff)
downloadhistorical-4fed2dcd241627296aedb63bfaa19c427aa431a8.tar.gz
historical-4fed2dcd241627296aedb63bfaa19c427aa431a8.tar.bz2
historical-4fed2dcd241627296aedb63bfaa19c427aa431a8.zip
adding test version with depends and rdepend
Package-Manager: portage-2.1.4.4
Diffstat (limited to 'sys-libs')
-rw-r--r--sys-libs/hardened-glibc/Manifest3
-rw-r--r--sys-libs/hardened-glibc/hardened-glibc-2.6.1-r1.ebuild150
-rw-r--r--sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild6
3 files changed, 156 insertions, 3 deletions
diff --git a/sys-libs/hardened-glibc/Manifest b/sys-libs/hardened-glibc/Manifest
index 79ed95c746f9..fc2be90ffcfe 100644
--- a/sys-libs/hardened-glibc/Manifest
+++ b/sys-libs/hardened-glibc/Manifest
@@ -1,5 +1,6 @@
DIST glibc-2.6.1-GENTOOPATCHES.patch.gz 829226 RMD160 c1a2586d3698d70d497213762e1b4612a4d2256c SHA1 4b76792d7c02809105252cba0602c8410cabef02 SHA256 3e8f2de55fd181a550da4306f21aa9387d02ee58f6fefe1dd051b5c5b4919b34
DIST glibc-2.6.1.tar.bz2 15767401 RMD160 a58226e394780a6996d608febf5881134990919e SHA1 85573fee8d79180165e9466a1fc25133b5792190 SHA256 3ded3a3c3ba2cf02d72479a5cc0829c7c261a9d0934e49a79233de9fa276ec22
-EBUILD hardened-glibc-2.6.1.ebuild 3666 RMD160 7b2e6cb750444495148ebeb72da147a042d57a9d SHA1 7460faa2e71fe76dab2bf5293d27c28a7160c99e SHA256 8a647a4dc9ea4d58ef86ae36b88632e3ee14f5acd43048a98c08cde66736eaf2
+EBUILD hardened-glibc-2.6.1-r1.ebuild 3867 RMD160 724c2f870230fb364c04a0db7cf7448b3ce0df6f SHA1 67de8671b8be112b90f51072de88170f1234a725 SHA256 c61a41207e32c080e2c1d2269d4e25cf5f86a9e2b745018d42cbfdc9d8a5d48f
+EBUILD hardened-glibc-2.6.1.ebuild 3734 RMD160 edbde93f56e5287eb48e972b13f4629bfc12bcc3 SHA1 770614adf84e12da34cb82b94a8f8207e9129540 SHA256 be4618a7174d292402a74f146368ad4c801162bb11319ea252deafb50222243d
MISC ChangeLog 282 RMD160 a5a283caadfcefa92457a911427e26afe5923227 SHA1 93c5ce3c189207084dc538caa695346f64306ca8 SHA256 88449ffa8c41cf3d276c12564a948ae32294b2052b4da362ee0571a7f31c74fb
MISC metadata.xml 161 RMD160 600015e5b2643ae38ea2f9e5aaff6d31d42470a8 SHA1 578b6ea4c02d377eb40ee4000df8bc3d97497f82 SHA256 f9146563cc3df2b0d02d2f554c5293d439b56a4d36bc5aed0c66aa83dfb06c2f
diff --git a/sys-libs/hardened-glibc/hardened-glibc-2.6.1-r1.ebuild b/sys-libs/hardened-glibc/hardened-glibc-2.6.1-r1.ebuild
new file mode 100644
index 000000000000..078e9024e8fa
--- /dev/null
+++ b/sys-libs/hardened-glibc/hardened-glibc-2.6.1-r1.ebuild
@@ -0,0 +1,150 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/hardened-glibc/hardened-glibc-2.6.1-r1.ebuild,v 1.1 2008/04/27 23:17:42 pappy Exp $
+
+inherit eutils
+
+# the main installation routine and patches
+# from http://www.linuxfromscratch.org/hlfs
+# and one file of patches of sys-libs/glibc
+
+DESCRIPTION="Gentoo Hardened GNU libc6"
+HOMEPAGE="http://www.gentoo.org/proj/en/hardened/"
+
+KERNELVER="2.6.18"
+
+GNU_MIRROR="ftp://ftp.gnu.org/gnu"
+
+PATCHDIST="http://dev.gentoo.org/~pappy/dist/hardened"
+PATCHPATH="sys-libs/hardened-glibc/files/2.6.1"
+GENTOOPATCHES="glibc-2.6.1-GENTOOPATCHES.patch.gz"
+
+SRC_URI="${SRC_URI} \
+ ${GNU_MIRROR}/glibc/glibc-2.6.1.tar.bz2"
+SRC_URI="${SRC_URI} \
+ ${PATCHDIST}/${PATCHPATH}/${GENTOOPATCHES}"
+
+LICENSE="LGPL-2"
+SLOT="1"
+
+# only works for x86 so far
+KEYWORDS="~x86"
+IUSE=""
+
+PROVIDE="virtual/libc"
+RESTRICT="strip" #46186
+
+DEPEND=">=sys-devel/binutils-2.15.94
+ >=sys-devel/gcc-config-1.3.12
+ >=app-misc/pax-utils-0.1.10
+ virtual/os-headers
+ sys-devel/gettext
+ >=sys-apps/portage-2.1.2"
+
+RDEPEND="sys-devel/gettext"
+
+pkg_setup() {
+ # hardcoding the CHOST in this ebuild (for x86 stages)
+ export CHOST="i486-pc-linux-gnu"
+ export CFLAGS="-O2 -pipe"
+ export CXXFLAGS="${CFLAGS}"
+
+ export CPPFLAGS=""
+ export ASFLAGS=""
+ export LDFLAGS=""
+
+ if [[ "x${MAKEOPTS}y" == "xy" ]]
+ then
+ export MAKEOPTS="-j4"
+ fi
+
+ einfo "using CHOST:${CHOST}"
+ einfo "using C(XX)FLAGS:${CFLAGS}:${CXXFLAGS}"
+ einfo "using MAKEOPTS:${MAKEOPTS}"
+}
+
+src_compile() {
+ cd "${WORKDIR}/glibc-${PV}"
+
+ epatch "${WORKDIR}/glibc-2.6.1-GENTOOPATCHES.patch"
+
+ mkdir -p "${WORKDIR}/glibc-build"
+ cd "${WORKDIR}/glibc-build"
+
+ "${WORKDIR}/glibc-${PV}/configure" \
+ --target="${CHOST}" \
+ --prefix=/usr \
+ --enable-bind-now \
+ --without-gd \
+ --disable-profile \
+ --enable-add-ons=nptl \
+ --without-selinux \
+ --with-tls \
+ --with-__thread \
+ --enable-kernel="${KERNELVER}" \
+ --without-cvs || die "configuration failed"
+
+ make || die "compile failed"
+}
+
+src_install() {
+ cd "${WORKDIR}/glibc-build"
+
+ make install_root="${D}" install || die "make install failed"
+
+ # NOTE: for installing all glibc locales in the binpackage,
+ # NOTE: make install_root="${D}" localedata/install-locales
+
+ insinto /etc
+
+ local configfiles="${WORKDIR}/glibc-${PV}/gentoo"
+
+ # install the locale-gen helper utility and config file
+ dosbin "${configfiles}/locale/locale-gen" || \
+ die "locale-gen helper script could not be installed"
+
+ doins "${configfiles}/locale/locale.gen" || \
+ die "locale.gen config file could not be installed"
+
+ # install the nscd startup script
+ doinitd "${configfiles}/etc/nscd" || \
+ die "nscd run level startup script could not be installed"
+
+ # install the config files for glibc
+ doins "${configfiles}"/etc/*.conf || \
+ die "glibc config files could not be installed"
+
+ # make sure the localtime is not overwritten by glibc emerges
+ rm "${D}/etc/localtime"
+}
+
+# NOTE: the locales are not in the .tbz2 file of the binpackage
+# NOTE: but will be generated in the postinst routine from here
+pkg_postinst() {
+ # make sure the file exists on the installed system
+ touch "${ROOT}/ld.so.conf"
+
+ # install locales (logic taken from sys-libs/glibc)
+ local locale_list="${ROOT}/etc/locale.gen"
+ if [[ -z $(locale-gen --list --config "${locale_list}") ]]
+ then
+ locale_list="${ROOT}/usr/share/i18n/SUPPORTED"
+ fi
+
+ # find the number of jobs available
+ local x jobs
+ for x in ${MAKEOPTS} ; do [[ "${x}" == -j* ]] && jobs=${x#-j} ; done
+
+ # generate the locales
+ locale-gen -j ${jobs:-2} --config "${locale_list}"
+
+ # set the timezone automatically if not found
+ if [[ ! -f "${ROOT}/etc/localtime" ]]
+ then
+ einfo "timezone not found: setting timezone to UTC"
+ cp --remove-destination \
+ "${ROOT}/usr/share/zoneinfo/UTC" \
+ "${ROOT}/etc/localtime"
+ fi
+}
+
diff --git a/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild b/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild
index 999d8e0453bc..881556385cdc 100644
--- a/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild
+++ b/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild,v 1.1 2008/04/27 22:29:48 pappy Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/hardened-glibc/hardened-glibc-2.6.1.ebuild,v 1.2 2008/04/27 23:17:42 pappy Exp $
inherit eutils
@@ -28,7 +28,9 @@ LICENSE="LGPL-2"
SLOT="1"
# only works for x86 so far
-KEYWORDS="~x86"
+# test version, do not use
+# will disappear from portage soon again
+KEYWORDS="-x86"
IUSE=""
PROVIDE="virtual/libc"