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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Tue Sep 9 17:52:13 2014 UTC (5 years, 1 month ago) by alonbl
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
upstream tarball reenroll, bug#522066

(Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key BF20DC51)

1 # Copyright 1999-2014 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-3.2.0.ebuild,v 1.1 2014/09/03 08:29:29 alonbl Exp $
4
5 EAPI=5
6
7 export CBUILD=${CBUILD:-${CHOST}}
8 export CTARGET=${CTARGET:-${CHOST}}
9 if [[ ${CTARGET} == ${CHOST} ]] ; then
10 if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then
11 export CTARGET=${CATEGORY/cross-}
12 fi
13 fi
14
15 inherit flag-o-matic eutils
16
17 DESCRIPTION="Free Win64 runtime and import library definitions"
18 HOMEPAGE="http://mingw-w64.sourceforge.net/"
19 SRC_URI="mirror://sourceforge/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v${PV}.tar.bz2"
20
21 LICENSE="BSD"
22 SLOT="0"
23 KEYWORDS="~amd64 ~x86"
24 IUSE="crosscompile_opts_headers-only idl"
25 RESTRICT="strip"
26
27 S="${WORKDIR}"
28
29 is_crosscompile() {
30 [[ ${CHOST} != ${CTARGET} ]]
31 }
32 just_headers() {
33 use crosscompile_opts_headers-only && [[ ${CHOST} != ${CTARGET} ]]
34 }
35
36 pkg_setup() {
37 if [[ ${CBUILD} == ${CHOST} ]] && [[ ${CHOST} == ${CTARGET} ]] ; then
38 die "Invalid configuration"
39 fi
40 }
41
42 src_configure() {
43 local extra_conf=()
44
45 if just_headers; then
46 extra_conf+=( --without-crt )
47 else
48 extra_conf+=( --with-crt )
49 fi
50
51 case ${CTARGET} in
52 x86_64*) extra_conf+=( --disable-lib32 --enable-lib64 ) ;;
53 i?86*) extra_conf+=( --enable-lib32 --disable-lib64 ) ;;
54 *) die "Unsupported ${CTARGET}" ;;
55 esac
56
57 CHOST=${CTARGET} strip-unsupported-flags
58 CHOST=${CTARGET} econf \
59 --prefix=/usr/${CTARGET} \
60 --includedir=/usr/${CTARGET}/usr/include \
61 --with-headers \
62 --enable-sdk \
63 $(use_enable idl) \
64 "${extra_conf[@]}"
65 }
66
67 src_install() {
68 default
69
70 if is_crosscompile ; then
71 # gcc is configured to look at specific hard-coded paths for mingw #419601
72 dosym usr /usr/${CTARGET}/mingw
73 dosym usr /usr/${CTARGET}/${CTARGET}
74 dosym usr/include /usr/${CTARGET}/sys-include
75 fi
76
77 env -uRESTRICT CHOST=${CTARGET} prepallstrip
78 rm -rf "${ED}/usr/share"
79 }

  ViewVC Help
Powered by ViewVC 1.1.20