Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 438440 Details for
Bug 586726
sys-devel/crossdev: prefixify
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
prefixify crossdev
crossdev-git-eprefix-2.patch (text/plain), 5.81 KB, created by
Michael Weiser
on 2016-06-22 15:38:05 UTC
(
hide
)
Description:
prefixify crossdev
Filename:
MIME Type:
Creator:
Michael Weiser
Created:
2016-06-22 15:38:05 UTC
Size:
5.81 KB
patch
obsolete
>--- crossdev-99999999/crossdev.orig 2016-04-02 19:35:41.000000000 +0200 >+++ crossdev-99999999/crossdev 2016-04-02 19:36:52.000000000 +0200 >@@ -7,15 +7,15 @@ > cd / > umask 0022 #159111 > >-: ${ROOT:=/} >-if [[ ${ROOT} != "/" ]] ; then >+: ${ROOT:=@GENTOO_PORTAGE_EPREFIX@} >+if [[ ${ROOT} != "@GENTOO_PORTAGE_EPREFIX@" ]] ; then > echo "Sorry, but crossdev does not support ROOT." 1>&2 > exit 2 > fi > >-CONFIGROOT="${PORTAGE_CONFIGROOT}/etc/portage" >+CONFIGROOT="@GENTOO_PORTAGE_EPREFIX@${PORTAGE_CONFIGROOT}/etc/portage" > >-source /lib/gentoo/functions.sh || exit 1 >+source @GENTOO_PORTAGE_EPREFIX@/lib/gentoo/functions.sh || exit 1 > esyslog() { :; } > die_logs() { > echo >@@ -392,7 +392,7 @@ > fi > > # make sure we have a valid logdir >- : ${PORT_LOGDIR:=/var/log/portage} >+ : ${PORT_LOGDIR:=@GENTOO_PORTAGE_EPREFIX@/var/log/portage} > mkdir -p "${PORT_LOGDIR}" > } > >@@ -413,8 +413,8 @@ > done > rm -rf "${CONFIGROOT}"/env/cross-${CTARGET} > rmdir "${CONFIGROOT}"/env 2>/dev/null >- rm -f /etc/revdep-rebuild/05cross-${CTARGET} >- rmdir /etc/revdep-rebuild 2>/dev/null >+ rm -f @GENTOO_PORTAGE_EPREFIX@/etc/revdep-rebuild/05cross-${CTARGET} >+ rmdir @GENTOO_PORTAGE_EPREFIX@/etc/revdep-rebuild 2>/dev/null > > # Unmerge all toolchain packages for this target. > qmerge -Uqy $(qlist -IC "cross-${CTARGET}/") >@@ -425,29 +425,29 @@ > gcc-{ar,nm,ranlib} gccbug gprof ld nm objcopy objdump \ > ranlib readelf size strings strip windmc windres > do >- rm -f /usr/bin/${CTARGET}-${f} /usr/${CTARGET}/bin/${f} >+ rm -f @GENTOO_PORTAGE_EPREFIX@/usr/bin/${CTARGET}-${f} @GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}/bin/${f} > done >- rm -f /usr/${CTARGET}/{sys-include,usr} >- rmdir /usr/${CTARGET}/{include/asm,include} 2>/dev/null >- rm -f /usr/bin/${CTARGET}-{gcc,{c,g}++,cpp,gfortran,gcov} >- rm -f /etc/env.d/{binutils,gcc}/config-${CTARGET} >+ rm -f @GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}/{sys-include,usr} >+ rmdir @GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}/{include/asm,include} 2>/dev/null >+ rm -f @GENTOO_PORTAGE_EPREFIX@/usr/bin/${CTARGET}-{gcc,{c,g}++,cpp,gfortran,gcov} >+ rm -f @GENTOO_PORTAGE_EPREFIX@/etc/env.d/{binutils,gcc}/config-${CTARGET} > > # clean out files from crossdev itself >- [[ -e /var/db/pkg/cross-${CTARGET} ]] && rmdir /var/db/pkg/cross-${CTARGET} >- rm -f /usr/bin/${CTARGET}-{emerge,fix-root,pkg-config} /usr/bin/emerge-${CTARGET} >+ [[ -e @GENTOO_PORTAGE_EPREFIX@/var/db/pkg/cross-${CTARGET} ]] && rmdir @GENTOO_PORTAGE_EPREFIX@/var/db/pkg/cross-${CTARGET} >+ rm -f @GENTOO_PORTAGE_EPREFIX@/usr/bin/${CTARGET}-{emerge,fix-root,pkg-config} @GENTOO_PORTAGE_EPREFIX@/usr/bin/emerge-${CTARGET} > > for f in make.{conf,globals,profile} ; do >- f="/usr/${CTARGET}/etc/${f}" >+ f="@GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}/etc/${f}" > [[ -L ${f} ]] && rm -f ${f} >- f="/usr/${CTARGET}/etc/portage/${f##*/}" >+ f="@GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}/etc/portage/${f##*/}" > [[ -L ${f} ]] && rm -f ${f} > done >- find /usr/share/crossdev/etc/ -type f | \ >+ find @GENTOO_PORTAGE_EPREFIX@/usr/share/crossdev/etc/ -type f | \ > while read f ; do > f1=${f} > [[ ! -e ${f1} ]] && continue > m1=$(set -- `md5sum ${f1}`; echo $1) >- f2=/usr/${CTARGET}${f#/usr/share/crossdev} >+ f2=@GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}${f#/usr/share/crossdev} > [[ ! -e ${f2} ]] && continue > m2=$(set -- `md5sum ${f2}`; echo $1) > if [[ ${m1} == ${m2} ]] ; then >@@ -456,7 +456,8 @@ > done > > # clean out the sysroot, prompting the user if need be >- for d in /usr/lib/gcc{,-lib}/${CTARGET} /usr/${CTARGET} ; do >+ for d in @GENTOO_PORTAGE_EPREFIX@/usr/lib/gcc{,-lib}/${CTARGET} \ >+ @GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET} ; do > if [[ ! -d ${d} ]] ; then > rm -f "${d}" > else >@@ -959,7 +960,7 @@ > output="env/cross-${CTARGET}/${pkg}.conf" > cat <<-EOF > "${output}" > SYMLINK_LIB=no >- COLLISION_IGNORE="\${COLLISION_IGNORE} /usr/lib/debug/.build-id" >+ COLLISION_IGNORE="\${COLLISION_IGNORE} @GENTOO_PORTAGE_EPREFIX@/usr/lib/debug/.build-id" > $(printf '%b' "${env}") > $(printf '%b' "${AENV}") > EOF >@@ -1113,21 +1114,21 @@ > set_metadata > > # filter out revdep rebuild stuff #182601 >-mkdir -p /etc/revdep-rebuild >-echo "SEARCH_DIRS_MASK=/usr/${CTARGET}" > /etc/revdep-rebuild/05cross-${CTARGET} >+mkdir -p @GENTOO_PORTAGE_EPREFIX@/etc/revdep-rebuild >+echo "SEARCH_DIRS_MASK=@GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET}" > @GENTOO_PORTAGE_EPREFIX@/etc/revdep-rebuild/05cross-${CTARGET} > > hr > > ####################################### > ### Create links for helper scripts ### > >-mkdir -p /usr/${CTARGET} >+mkdir -p @GENTOO_PORTAGE_EPREFIX@/usr/${CTARGET} > emerge-wrapper --target ${CTARGET} --init || exit 1 > > ################# > emerged_with_use() { > local pkg=$1 use=$2 >- grep -qs ${use} /var/db/pkg/cross-${CTARGET}/${pkg}-*/USE >+ grep -qs ${use} @GENTOO_PORTAGE_EPREFIX@/var/db/pkg/cross-${CTARGET}/${pkg}-*/USE > } > set_eopts_on_pkg_status() { > emerged_with_use "$@" \ >--- crossdev-99999999/wrappers/cross-pkg-config.orig 2016-04-02 19:35:41.000000000 +0200 >+++ crossdev-99999999/wrappers/cross-pkg-config 2016-04-02 19:36:02.000000000 +0200 >@@ -59,7 +59,7 @@ > EXTRA_PKG_CONFIG_LIBDIR=${UCLINUX_PKG_CONFIG_LIBDIR} > else > # /usr/<target> >- SYSROOT="/usr/${CHOST}" >+ SYSROOT="@GENTOO_PORTAGE_EPREFIX@/usr/${CHOST}" > if [ -z "${CHOST}" ] || [ ! -d "${SYSROOT}" ] ; then > error "Need \$ROOT or \$STAGEDIR set first" > fi >--- crossdev-99999999/wrappers/etc/portage/make.conf.orig 2016-04-02 19:35:41.000000000 +0200 >+++ crossdev-99999999/wrappers/etc/portage/make.conf 2016-04-02 19:36:02.000000000 +0200 >@@ -4,7 +4,7 @@ > > HOSTCC=__CBUILD__-gcc > >-ROOT=/usr/${CHOST}/ >+ROOT=@GENTOO_PORTAGE_EPREFIX@/usr/${CHOST}/ > > ACCEPT_KEYWORDS="__ARCH__ ~__ARCH__" > >--- crossdev-99999999/wrappers/cross-emerge >+++ crossdev-99999999/wrappers/cross-emerge >@@ -9,7 +9,7 @@ if [ -z "${CHOST}" ] ; then > fi > export CHOST > >-: ${SYSROOT=/usr/${CHOST}} >+: ${SYSROOT=@GENTOO_PORTAGE_EPREFIX@/usr/${CHOST}} > : ${PORTAGE_CONFIGROOT=${SYSROOT}} > export SYSROOT PORTAGE_CONFIGROOT >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 586726
:
438438
| 438440