/[gentoo-x86]/dev-util/mingw64-runtime/mingw64-runtime-20091222.ebuild
Gentoo

Contents of /dev-util/mingw64-runtime/mingw64-runtime-20091222.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Tue Jan 12 19:52:42 2010 UTC (9 years, 10 months ago) by vapier
Branch: MAIN
Changes since 1.2: +2 -3 lines
Drop dir changing to fix patch application #300719 by Thomas Axelsson.
(Portage version: 2.2_rc61/cvs/Linux x86_64)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-util/mingw64-runtime/mingw64-runtime-20091222.ebuild,v 1.2 2009/12/24 13:23:06 vapier Exp $
4
5 export CBUILD=${CBUILD:-${CHOST}}
6 export CTARGET=${CTARGET:-${CHOST}}
7 if [[ ${CTARGET} == ${CHOST} ]] ; then
8 if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
9 export CTARGET=${CATEGORY/cross-}
10 fi
11 fi
12
13 inherit flag-o-matic eutils
14
15 DESCRIPTION="Free Win64 runtime and import library definitions"
16 HOMEPAGE="http://mingw-w64.sourceforge.net/"
17 SRC_URI="mirror://sourceforge/mingw-w64/mingw-w64-trunk-snapshot-${PV}.tar.bz2"
18
19 LICENSE="BSD"
20 SLOT="0"
21 KEYWORDS="~amd64 ~x86"
22 IUSE="crosscompile_opts_headers-only"
23 RESTRICT="strip"
24
25 S=${WORKDIR}/trunk/mingw-w64-crt
26
27 is_crosscompile() {
28 [[ ${CHOST} != ${CTARGET} ]]
29 }
30 just_headers() {
31 use crosscompile_opts_headers-only && [[ ${CHOST} != ${CTARGET} ]]
32 }
33
34 pkg_setup() {
35 if [[ ${CBUILD} == ${CHOST} ]] && [[ ${CHOST} == ${CTARGET} ]] ; then
36 die "Invalid configuration"
37 fi
38 }
39
40 src_unpack() {
41 unpack ${A}
42 epatch "${FILESDIR}"/${P}-mm_shuffle_ps-x86.patch #298087
43 }
44
45 src_compile() {
46 # install the local headers as the crt step wants latest
47 pushd ../mingw-w64-headers >/dev/null
48 # directx sdk triggers failure, see upstream #2919341
49 CHOST=${CTARGET} econf --enable-sdk=ddk || die
50 emake install DESTDIR="${WORKDIR}/sysroot" || die
51 popd >/dev/null
52
53 just_headers && return 0
54
55 CHOST=${CTARGET} strip-unsupported-flags
56 append-cppflags -isystem "${WORKDIR}/sysroot/usr/${CTARGET}/include"
57 CHOST=${CTARGET} econf || die
58 emake || die
59 }
60
61 src_install() {
62 insinto /usr/${CTARGET}/usr/include
63 doins -r "${WORKDIR}"/sysroot/usr/${CTARGET}/include/* || die
64 is_crosscompile \
65 && dosym usr /usr/${CTARGET}/${CTARGET} \
66 && dosym usr/include /usr/${CTARGET}/sys-include
67 just_headers && return 0
68
69 emake install DESTDIR="${D}" || die
70 env -uRESTRICT CHOST=${CTARGET} prepallstrip
71 rm -rf "${D}"/usr/doc
72 }

  ViewVC Help
Powered by ViewVC 1.1.20