diff options
author | Mike Frysinger <vapier@gentoo.org> | 2006-10-02 20:47:52 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2006-10-02 20:47:52 +0000 |
commit | 8b8768b866f46f98590010defbef59bc15a1faf5 (patch) | |
tree | 2ca029c006110eb277939a5752d907f4c4b979c7 /dev-util/mingw-runtime | |
parent | Add python-2.4 license. (diff) | |
download | gentoo-2-8b8768b866f46f98590010defbef59bc15a1faf5.tar.gz gentoo-2-8b8768b866f46f98590010defbef59bc15a1faf5.tar.bz2 gentoo-2-8b8768b866f46f98590010defbef59bc15a1faf5.zip |
redo install in SYSROOT style
(Portage version: 2.1.2_pre2)
Diffstat (limited to 'dev-util/mingw-runtime')
-rw-r--r-- | dev-util/mingw-runtime/mingw-runtime-3.10.ebuild | 20 | ||||
-rw-r--r-- | dev-util/mingw-runtime/mingw-runtime-3.9.ebuild | 20 |
2 files changed, 24 insertions, 16 deletions
diff --git a/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild b/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild index 853a9dc62d67..9277c32bdd84 100644 --- a/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild +++ b/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild,v 1.4 2006/09/26 06:18:05 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw-runtime/mingw-runtime-3.10.ebuild,v 1.5 2006/10/02 20:47:52 vapier Exp $ # This version does not work as the configure script expects the installed # cross-compiler to be able to link binaries ... except we haven't provided @@ -30,6 +30,9 @@ RESTRICT="strip" DEPEND="" +is_crosscompile() { + [[ ${CHOST} != ${CTARGET} ]] +} just_headers() { use crosscompile_opts_headers-only && [[ ${CHOST} != ${CTARGET} ]] } @@ -53,10 +56,7 @@ src_compile() { just_headers && return 0 CHOST=${CTARGET} strip-unsupported-flags - econf \ - --host=${CTARGET} \ - --prefix=/usr/${CTARGET} \ - || die + econf --host=${CTARGET} || die emake || die } @@ -65,10 +65,14 @@ src_install() { insinto /usr/${CTARGET}/usr/include doins -r include/* || die else - emake install DESTDIR="${D}" || die + local insdir + is_crosscompile \ + && insdir=${D}/usr/${CTARGET} \ + || insdir=${D} + emake install DESTDIR="${insdir}" || die env -uRESTRICT CHOST=${CTARGET} prepallstrip - rm -rf "${D}"/usr/${CTARGET}/doc + rm -rf "${insdir}"/usr/doc dodoc CONTRIBUTORS ChangeLog README TODO readme.txt fi - dosym usr/include /usr/${CTARGET}/sys-include + is_crosscompile && dosym usr/include /usr/${CTARGET}/sys-include } diff --git a/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild b/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild index 06208d715533..ebde522a7e9e 100644 --- a/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild +++ b/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild,v 1.4 2006/09/26 06:18:05 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw-runtime/mingw-runtime-3.9.ebuild,v 1.5 2006/10/02 20:47:52 vapier Exp $ export CBUILD=${CBUILD:-${CHOST}} export CTARGET=${CTARGET:-${CHOST}} @@ -24,6 +24,9 @@ RESTRICT="strip" DEPEND="" +is_crosscompile() { + [[ ${CHOST} != ${CTARGET} ]] +} just_headers() { use crosscompile_opts_headers-only && [[ ${CHOST} != ${CTARGET} ]] } @@ -51,10 +54,7 @@ src_compile() { just_headers && return 0 CHOST=${CTARGET} strip-unsupported-flags - econf \ - --host=${CTARGET} \ - --prefix=/usr/${CTARGET} \ - || die + econf --host=${CTARGET} || die emake || die } @@ -63,10 +63,14 @@ src_install() { insinto /usr/${CTARGET}/usr/include doins -r include/* || die else - emake install DESTDIR="${D}" || die + local insdir + is_crosscompile \ + && insdir=${D}/usr/${CTARGET} \ + || insdir=${D} + emake install DESTDIR="${insdir}" || die env -uRESTRICT CHOST=${CTARGET} prepallstrip - rm -rf "${D}"/usr/${CTARGET}/doc + rm -rf "${insdir}"/usr/doc dodoc CONTRIBUTORS ChangeLog README TODO readme.txt fi - dosym usr/include /usr/${CTARGET}/sys-include + is_crosscompile && dosym usr/include /usr/${CTARGET}/sys-include } |