2011-07-19 01:44:59 +02:00
|
|
|
# Template build file for 'mingw-w64-crt'
|
|
|
|
#
|
|
|
|
_shortname=mingw-w64
|
2011-07-21 00:38:06 +02:00
|
|
|
pkgname=${_shortname}-crt
|
2011-07-19 01:44:59 +02:00
|
|
|
_majversion=1.0
|
|
|
|
_snapshot=20110523
|
2011-07-21 00:38:06 +02:00
|
|
|
version=${_majversion}.${_snapshot}
|
2011-07-21 11:52:56 +02:00
|
|
|
revision=3
|
2011-07-21 00:38:06 +02:00
|
|
|
distfiles=${SOURCEFORGE_SITE}/${_shortname}/${_shortname}/${_shortname}-v${_majversion}-snapshot-${_snapshot}.tar.bz2
|
2013-04-14 04:24:51 +02:00
|
|
|
hostmakedepends="flex"
|
|
|
|
makedepends="mingw-w64-binutils mingw-w64-headers mingw-w64-gcc"
|
|
|
|
if [ "$XBPS_MACHINE" = "x86_64" ]; then
|
|
|
|
makedepends+=" gcc-multilib"
|
2012-05-23 20:58:45 +02:00
|
|
|
fi
|
2011-07-19 01:44:59 +02:00
|
|
|
short_desc="The mingw-w64 cross-compiler runtime"
|
|
|
|
maintainer="davehome <davehome@redthumb.info.tm>"
|
|
|
|
homepage="http://mingw-w64.sourceforge.net/"
|
|
|
|
license="Public Domain, BSD, LGPL, ZPL"
|
|
|
|
checksum=12dc02c40cb2d28dd70aeea792fe998e29acfc614589ecf7508cd1fbb93a4154
|
|
|
|
long_desc="
|
|
|
|
The mingw-w64 cross-compiler runtime.
|
|
|
|
|
|
|
|
This is the mingw-64 cross-compiler, which supports building code for Win32
|
|
|
|
or Win64 (multilib). For the i686 platform, only 32bit is available."
|
|
|
|
|
|
|
|
_mingwprefix=/opt
|
|
|
|
|
2011-11-08 11:56:17 +01:00
|
|
|
if [ "${XBPS_MACHINE}" = "x86_64" ]; then
|
|
|
|
_mingwtriplet="${XBPS_MACHINE}-w64-mingw32"
|
2011-07-19 01:44:59 +02:00
|
|
|
_multilib_args="--enable-lib32 --enable-lib64"
|
|
|
|
else
|
2011-11-08 11:56:17 +01:00
|
|
|
_mingwtriplet="${XBPS_MACHINE}-w64-mingw32"
|
2011-07-19 01:44:59 +02:00
|
|
|
_multilib_args="--enable-lib32 --disable-lib64"
|
|
|
|
fi
|
|
|
|
|
2011-07-19 10:35:13 +02:00
|
|
|
strip_cmd=${_mingwprefix}/bin/${_mingwtriplet}-strip
|
2011-07-21 00:38:06 +02:00
|
|
|
wrksrc=${_shortname}-v${_majversion}-${_snapshot}
|
|
|
|
build_wrksrc=${pkgname}
|
|
|
|
|
2012-05-23 20:58:45 +02:00
|
|
|
do_build() {
|
2011-07-19 01:44:59 +02:00
|
|
|
unset LD_LIBRARY_PATH LDLIBPATH LDFLAGS CPPFLAGS
|
|
|
|
local SAVEDPATH=$PATH
|
|
|
|
export PATH="/opt/bin:/usr/local/bin:/usr/local/sbin:/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin"
|
|
|
|
|
2011-07-21 00:38:06 +02:00
|
|
|
./configure --prefix=${_mingwprefix} --with-sysroot=${_mingwprefix} \
|
|
|
|
--host=${_mingwtriplet} ${_multilib_args} \
|
|
|
|
--bindir=${_mingwprefix}/bin --libdir=${_mingwprefix}/lib \
|
|
|
|
--libexecdir=${_mingwprefix}/lib
|
2011-07-19 01:44:59 +02:00
|
|
|
|
|
|
|
make ${makejobs}
|
|
|
|
|
|
|
|
export PATH=$SAVEDPATH
|
|
|
|
}
|
|
|
|
|
2012-05-23 20:58:45 +02:00
|
|
|
do_install() {
|
2011-07-19 10:35:13 +02:00
|
|
|
# This path setting is necessary so that it finds ${_mingwprefix}-ranlib
|
|
|
|
unset LD_LIBRARY_PATH LDLIBPATH LDFLAGS CPPFLAGS
|
|
|
|
local SAVEDPATH=$PATH
|
|
|
|
export PATH="/opt/bin:/usr/local/bin:/usr/local/sbin:/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin"
|
|
|
|
|
2011-07-21 00:38:06 +02:00
|
|
|
make DESTDIR=${DESTDIR} install
|
2011-07-19 10:35:13 +02:00
|
|
|
|
|
|
|
export PATH=$SAVEDPATH
|
2011-07-19 01:44:59 +02:00
|
|
|
}
|
2013-04-14 04:24:51 +02:00
|
|
|
|
|
|
|
mingw-w64-crt_package() {
|
|
|
|
pkg_install() {
|
|
|
|
vmove opt
|
|
|
|
}
|
|
|
|
}
|