summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-10-03 03:59:17 +0000
committerMike Frysinger <vapier@gentoo.org>2011-10-03 03:59:17 +0000
commitfae9c20853d33c3be8cf439c8e2dac5e6fdee77a (patch)
tree1b6e991b3aec39dff797f10764439b9adce97690 /sys-apps/baselayout
parentVersion bump. (diff)
downloadhistorical-fae9c20853d33c3be8cf439c8e2dac5e6fdee77a.tar.gz
historical-fae9c20853d33c3be8cf439c8e2dac5e6fdee77a.tar.bz2
historical-fae9c20853d33c3be8cf439c8e2dac5e6fdee77a.zip
Version bump and multilib overhaul.
Package-Manager: portage-2.2.0_alpha59/cvs/Linux x86_64
Diffstat (limited to 'sys-apps/baselayout')
-rw-r--r--sys-apps/baselayout/ChangeLog7
-rw-r--r--sys-apps/baselayout/Manifest14
-rw-r--r--sys-apps/baselayout/baselayout-2.1.ebuild206
3 files changed, 220 insertions, 7 deletions
diff --git a/sys-apps/baselayout/ChangeLog b/sys-apps/baselayout/ChangeLog
index 95494dcaa871..0a33a294428c 100644
--- a/sys-apps/baselayout/ChangeLog
+++ b/sys-apps/baselayout/ChangeLog
@@ -1,10 +1,15 @@
# ChangeLog for sys-apps/baselayout
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/baselayout/ChangeLog,v 1.511 2011/09/04 18:08:04 williamh Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/baselayout/ChangeLog,v 1.512 2011/10/03 03:59:17 vapier Exp $
# See the rc-scripts ChangeLog in subversion for release info:
# http://sources.gentoo.org/viewcvs.py/*checkout*/baselayout/trunk/ChangeLog
+*baselayout-2.1 (03 Oct 2011)
+
+ 03 Oct 2011; Mike Frysinger <vapier@gentoo.org> +baselayout-2.1.ebuild:
+ Version bump and multilib overhaul.
+
04 Sep 2011; William Hubbs <williamh@gentoo.org>
-baselayout-1.12.14-r1.ebuild, -files/baselayout-1.12.14-iproute.patch:
Remove baselayout-1 from the tree
diff --git a/sys-apps/baselayout/Manifest b/sys-apps/baselayout/Manifest
index 882f360e5671..2fb7fd8b5eff 100644
--- a/sys-apps/baselayout/Manifest
+++ b/sys-apps/baselayout/Manifest
@@ -1,14 +1,16 @@
-----BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
+Hash: SHA256
DIST baselayout-2.0.3.tar.bz2 39969 RMD160 ca4ae235382780cd386c89f0147fbe17bb599414 SHA1 c5dbcc2d131254b2bb14b782101e2318d1dfcd2d SHA256 879308781d845f467eb2b45b9ff006aa799e943f45ddba518f43acae1ec84bdd
+DIST baselayout-2.1.tar.bz2 40398 RMD160 bba874c5d3290848236703125c130107c1244f55 SHA1 84783a773ec050700b3b0ce4c7645ae878f7f7fb SHA256 2ac6f2156513a2820a0eeeecc2cf7e7c0b5e0c750b324f1e21912d5f3cda4956
EBUILD baselayout-2.0.3.ebuild 7366 RMD160 579ac15844268e72cd9e1f593501e9a5806f4043 SHA1 3dcb7064e613d063fbe2428f7e3f57d92a2d9219 SHA256 e72e760fbc2452212fee89e5f4c00437b11d7973b5c27933c58481e9a656f5a4
-MISC ChangeLog 107332 RMD160 145138107380f64743786e6e3d9b8bc105999f1a SHA1 e6b53bfea19743f517991a86dc81b562f1245722 SHA256 c338cefe80534681a823122d023e52e78effee756798f63260bf13f30050e3df
+EBUILD baselayout-2.1.ebuild 7083 RMD160 aa78d1dd9f005ee16decf9bb723f02293233ef79 SHA1 bc3e7269f4ba52d364dba30ec70fd78fe6666154 SHA256 0b7e683efcc335cf8270ae744a45685a7ad35b667679a89f3a6c0b88572551cd
+MISC ChangeLog 107474 RMD160 df4c7e614fa2e246d31ddfe602947caaa0ce196b SHA1 3cf73c91e2a805113e9d2a755408dd2c4c4b880f SHA256 c6d7fac90f3ce60abe0bb16a96b240c0d33fe6f7402458e33f27bc84a387b0a4
MISC metadata.xml 164 RMD160 f43cbec30b7074319087c9acffdb9354b17b0db3 SHA1 9c213f5803676c56439df3716be07d6692588856 SHA256 f5f2891f2a4791cd31350bb2bb572131ad7235cd0eeb124c9912c187ac10ce92
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.17 (GNU/Linux)
+Version: GnuPG v2.0.18 (GNU/Linux)
-iEYEARECAAYFAk5jvgYACgkQblQW9DDEZTgscACfTFj6ypb53w3qh4Hckre7TstX
-pzwAnjDaeEtarJvzfxiB49kkZc+U0nzZ
-=Pkpn
+iF4EAREIAAYFAk6JMyEACgkQaC/OocHi7JZ1CgD+KWy1gNtyHzuV5VCq/PeLtFTz
+IvrdCqJ6/2H0tkzRalEA/32IxF4Sp6QxwtZd9sQ7jjZxNKvjnmdf7Z8darmcXvj3
+=/Srp
-----END PGP SIGNATURE-----
diff --git a/sys-apps/baselayout/baselayout-2.1.ebuild b/sys-apps/baselayout/baselayout-2.1.ebuild
new file mode 100644
index 000000000000..eba860455d7c
--- /dev/null
+++ b/sys-apps/baselayout/baselayout-2.1.ebuild
@@ -0,0 +1,206 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/baselayout/baselayout-2.1.ebuild,v 1.1 2011/10/03 03:59:17 vapier Exp $
+
+inherit eutils multilib
+
+DESCRIPTION="Filesystem baselayout and init scripts"
+HOMEPAGE="http://www.gentoo.org/"
+SRC_URI="mirror://gentoo/${P}.tar.bz2
+ http://dev.gentoo.org/~vapier/dist/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
+IUSE="build"
+
+PDEPEND="sys-apps/openrc"
+
+pkg_setup() {
+ multilib_layout
+}
+
+# Create our multilib dirs - the Makefile has no knowledge of this
+multilib_layout() {
+ local libdir libdirs=$(get_all_libdirs) def_libdir=$(get_abi_LIBDIR $DEFAULT_ABI)
+ : ${libdirs:=lib} # it isn't that we don't trust multilib.eclass...
+
+ # figure out which paths should be symlinks and which should be directories
+ local dirs syms exp d
+ for libdir in ${libdirs} ; do
+ exp=( {,usr/,usr/local/}${libdir} )
+ for d in "${exp[@]/#/${ROOT}}" ; do
+ # most things should be dirs
+ if [ "${SYMLINK_LIB}" = "yes" ] && [ "${libdir}" = "lib" ] ; then
+ [ ! -h "${d}" ] && [ -e "${d}" ] && dirs+=" ${d}"
+ else
+ [ -h "${d}" ] && syms+=" ${d}"
+ fi
+ done
+ done
+ if [ -n "${syms}" ] ; then
+ ewarn "Based on your profile, these paths should be directories:"
+ ewarn "${syms}"
+ ewarn "Failure to fix this may result in a broken system."
+ echo
+ fi
+ if [ -n "${dirs}" ] ; then
+ ewarn "Based on your profile, these paths should be symlinks:"
+ ewarn "${dirs}"
+ ewarn "Failure to fix this may result in a broken system."
+ echo
+ fi
+
+ # setup symlinks and dirs where we expect them to be; do not migrate
+ # data ... just fall over in that case.
+ local prefix
+ for prefix in "${ROOT}"{,usr/,usr/local/} ; do
+ if [ "${SYMLINK_LIB}" = yes ] ; then
+ # we need to make sure "lib" points to the native libdir
+ if [ -h "${prefix}lib" ] ; then
+ # it's already a symlink! assume it's pointing to right place ...
+ continue
+ elif [ -d "${prefix}lib" ] ; then
+ # "lib" is a dir, so need to convert to a symlink
+ ewarn "Converting ${prefix}lib from a dir to a symlink"
+ rm -f "${prefix}lib"/.keep
+ if rmdir "${prefix}lib" 2>/dev/null ; then
+ ln -s ${def_libdir} "${prefix}lib" || die
+ else
+ die "non-empty dir found where we needed a symlink: ${prefix}lib"
+ fi
+ else
+ # nothing exists, so just set it up sanely
+ ewarn "Initializing ${prefix}lib as a symlink"
+ mkdir -p "${prefix}" || die
+ rm -f "${prefix}lib" || die
+ ln -s ${def_libdir} "${prefix}lib" || die
+ fi
+ else
+ # we need to make sure "lib" is a dir
+ if [ -h "${prefix}lib" ] ; then
+ # "lib" is a symlink, so need to convert to a dir
+ ewarn "Converting ${prefix}lib from a symlink to a dir"
+ rm -f "${prefix}lib" || die
+ if [ -d "${prefix}lib32" ] ; then
+ ewarn "Migrating ${prefix}lib32 to ${prefix}lib"
+ mv "${prefix}lib32" "${prefix}lib" || die
+ else
+ mkdir -p "${prefix}lib" || die
+ fi
+ elif [ -d "${prefix}lib" ] ; then
+ # make sure the old "lib" ABI location does not exist; we
+ # only symlinked the lib dir on systems where we moved it
+ # to "lib32" ...
+ if [ -d "${prefix}lib32" ] ; then
+ rm -f "${prefix}lib32"/.keep
+ if ! rmdir "${prefix}lib32" 2>/dev/null ; then
+ ewarn "You need to merge ${prefix}lib32 into ${prefix}lib"
+ die "non-empty dir found where there should be none: ${prefix}lib32"
+ fi
+ fi
+ else
+ # nothing exists, so just set it up sanely
+ ewarn "Initializing ${prefix}lib as a dir"
+ mkdir -p "${prefix}" || die
+ rm -f "${prefix}lib" || die
+ ln -s ${def_libdir} "${prefix}lib" || die
+ fi
+ fi
+ done
+}
+
+pkg_preinst() {
+ # Bug #217848 - Since the remap_dns_vars() called by pkg_preinst() of
+ # the baselayout-1.x ebuild copies all the real configs from the user's
+ # /etc/conf.d into ${D}, it makes them all appear to be the default
+ # versions. In order to protect them from being unmerged after this
+ # upgrade, modify their timestamps.
+ touch "${ROOT}"/etc/conf.d/* 2>/dev/null
+
+ # This is written in src_install (so it's in CONTENTS), but punt all
+ # pending updates to avoid user having to do etc-update (and make the
+ # pkg_postinst logic simpler).
+ rm -f "${ROOT}"/etc/._cfg????_gentoo-release
+
+ # We need to install directories and maybe some dev nodes when building
+ # stages, but they cannot be in CONTENTS.
+ # Also, we cannot reference $S as binpkg will break so we do this.
+ multilib_layout
+ if use build ; then
+ emake -C "${D}/usr/share/${PN}" DESTDIR="${ROOT}" layout || die
+ fi
+ rm -f "${D}"/usr/share/${PN}/Makefile
+}
+
+src_install() {
+ emake \
+ OS=$(usex kernel_FreeBSD BSD Linux) \
+ DESTDIR="${D}" \
+ install || die
+ dodoc ChangeLog.svn
+
+ # need the makefile in pkg_preinst
+ insinto /usr/share/${PN}
+ doins Makefile || die
+
+ # handle multilib paths. do it here because we want this behavior
+ # regardless of the C library that you're using. we do explicitly
+ # list paths which the native ldconfig searches, but this isn't
+ # problematic as it doesn't change the resulting ld.so.cache or
+ # take longer to generate. similarly, listing both the native
+ # path and the symlinked path doesn't change the resulting cache.
+ local libdir ldpaths
+ for libdir in $(get_all_libdirs) ; do
+ ldpaths+=":/${libdir}:/usr/${libdir}:/usr/local/${libdir}"
+ done
+ echo "LDPATH='${ldpaths#:}'" >> "${D}"/etc/env.d/00basic
+
+ # rc-scripts version for testing of features that *should* be present
+ echo "Gentoo Base System release ${PV}" > "${D}"/etc/gentoo-release
+}
+
+pkg_postinst() {
+ local x
+
+ # We installed some files to /usr/share/baselayout instead of /etc to stop
+ # (1) overwriting the user's settings
+ # (2) screwing things up when attempting to merge files
+ # (3) accidentally packaging up personal files with quickpkg
+ # If they don't exist then we install them
+ for x in master.passwd passwd shadow group fstab ; do
+ [ -e "${ROOT}etc/${x}" ] && continue
+ [ -e "${ROOT}usr/share/baselayout/${x}" ] || continue
+ cp -p "${ROOT}usr/share/baselayout/${x}" "${ROOT}"etc
+ done
+
+ # Force shadow permissions to not be world-readable #260993
+ for x in shadow ; do
+ [ -e "${ROOT}etc/${x}" ] && chmod o-rwx "${ROOT}etc/${x}"
+ done
+
+ # Take care of the etc-update for the user
+ if [ -e "${ROOT}"/etc/._cfg0000_gentoo-release ] ; then
+ mv "${ROOT}"/etc/._cfg0000_gentoo-release "${ROOT}"/etc/gentoo-release
+ fi
+
+ # whine about users that lack passwords #193541
+ if [[ -e ${ROOT}/etc/shadow ]] ; then
+ local bad_users=$(sed -n '/^[^:]*::/s|^\([^:]*\)::.*|\1|p' "${ROOT}"/etc/shadow)
+ if [[ -n ${bad_users} ]] ; then
+ echo
+ ewarn "The following users lack passwords!"
+ ewarn ${bad_users}
+ fi
+ fi
+
+ # whine about users with invalid shells #215698
+ if [[ -e ${ROOT}/etc/passwd ]] ; then
+ local bad_shells=$(awk -F: 'system("test -e " $7) { print $1 " - " $7}' /etc/passwd | sort)
+ if [[ -n ${bad_shells} ]] ; then
+ echo
+ ewarn "The following users have non-existent shells!"
+ ewarn "${bad_shells}"
+ fi
+ fi
+}