From cd08e63819e14be76ee1f1824dfc1316ce4d89f1 Mon Sep 17 00:00:00 2001 From: Alon Bar-Lev Date: Tue, 5 May 2015 11:39:47 +0000 Subject: [PATCH] Version bump, bug#543954 Package-Manager: portage-2.2.18/cvs/Linux x86_64 Manifest-Sign-Key: 0xBF20DC51 --- dev-util/mingw64-runtime/ChangeLog | 10 +- dev-util/mingw64-runtime/Manifest | 24 ++-- .../files/mingw64-runtime-4.0.1-build.patch | 88 ++++++++++++++ .../mingw64-runtime-4.0.1-winpthreads.patch | 86 +++++++++++++ dev-util/mingw64-runtime/metadata.xml | 6 + .../mingw64-runtime-4.0.1.ebuild | 113 ++++++++++++++++++ 6 files changed, 311 insertions(+), 16 deletions(-) create mode 100644 dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-build.patch create mode 100644 dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-winpthreads.patch create mode 100644 dev-util/mingw64-runtime/mingw64-runtime-4.0.1.ebuild diff --git a/dev-util/mingw64-runtime/ChangeLog b/dev-util/mingw64-runtime/ChangeLog index 3d836b4d9d66..1e72b21f8af4 100644 --- a/dev-util/mingw64-runtime/ChangeLog +++ b/dev-util/mingw64-runtime/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for dev-util/mingw64-runtime # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw64-runtime/ChangeLog,v 1.19 2015/02/27 08:11:21 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw64-runtime/ChangeLog,v 1.20 2015/05/05 11:39:40 alonbl Exp $ + +*mingw64-runtime-4.0.1 (05 May 2015) + + 05 May 2015; Alon Bar-Lev + +files/mingw64-runtime-4.0.1-build.patch, + +files/mingw64-runtime-4.0.1-winpthreads.patch, +mingw64-runtime-4.0.1.ebuild, + metadata.xml: + Version bump, bug#543954 27 Feb 2015; Mike Frysinger mingw64-runtime-2.0.8.ebuild, mingw64-runtime-3.0.0.ebuild, mingw64-runtime-3.1.0.ebuild, diff --git a/dev-util/mingw64-runtime/Manifest b/dev-util/mingw64-runtime/Manifest index 815cb7d35ce0..103c029d5f44 100644 --- a/dev-util/mingw64-runtime/Manifest +++ b/dev-util/mingw64-runtime/Manifest @@ -1,30 +1,24 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 +AUX mingw64-runtime-4.0.1-build.patch 2981 SHA256 35e3dcd14c23241a1eedcaaad25f99f6e345fde5e1d950f697e4e0f0a288ec6c SHA512 6495f898b736188800b1fc02956cfe021c7668a2d38d8acabc2d035e90aa1d72d761ae15141396f8d3dad8ac7111dcaac5fdb0c59c0d34bd2d820e54ab30c89d WHIRLPOOL 97ed9c6d118d75432ef322a7e1234e53cdcca76b4686875e482356cb69ee04f59593e23c74add37ae33bb71326c57e8494f2557e6e375d68303eb4776cb1b268 +AUX mingw64-runtime-4.0.1-winpthreads.patch 3142 SHA256 fd9039cb2ff117a661c15a70868af66c44e38206acd158cffa3ed6767939aad8 SHA512 5a4e34257f0eb9f3f9b51677459111b08b389dbebf3f29d30d99dcccd06e41bf1b82d6d0a1ce01fbfa5c0833bff205679203a0146d77b5416ef277c4c047a492 WHIRLPOOL 4dfdc48f45f122869734f22acd75549af9815e472184cb0cb3f87fc8b0f4389f9799af17702c0add54ef93a50e58e3a37141e6f0636ca29a7ceb78a49bc12df5 DIST mingw-w64-v2.0.8.tar.gz 7017057 SHA256 1a5a2c57f90c7f1b5eb8402a52f93de645925a8af62c2cfe748f39ce66008cf4 SHA512 c526bad968c74d86e740862f5e492329b32a1782c69b3a22f7203ac7e38697ba2017f95ed7bf519b737328a92d7c1b4e519f9103d634550f30bdb4a21921303e WHIRLPOOL 913bc444941c4c9c630404847cfb9bb54083fcd366a240e47992d3ee65cfc4c86f340099970243d3d251d5a1e5a00005c09e9d1aecb884256e125155bbcfbd0e DIST mingw-w64-v3.0.0.tar.bz2 7012419 SHA256 ffd381a53cb774843667ccdaeb3a23f86be77b0344355e1a5947b3ceb8343c67 SHA512 7fc438908328ae4429f79dfaaae92bc7e88bc0f46517bdebdc3c45b3e8062ff6c27f166eb51103c2d49aae01851d82f33e0b031c8d98198baaeb119e19221989 WHIRLPOOL ea2820ab24dcd6f35fab0404b2bd26273b117731bb25e2e3ef753e9a3a9b6661564605cdae7ed5e6e4f9fc6b3c3d000761fa44afa19f79b5d6deaebca44f709c DIST mingw-w64-v3.1.0.tar.bz2 7021162 SHA256 ece7a7e7e1ab5e25d5ce469f8e4de7223696146fffa71c16e2a9b017d0e017d2 SHA512 9f418694aa0f072e2f08766fcee8929ac3022187750028781336243e050495b9709bb9ae87b4a83a8e9d3856478c525d8636277a4c219e282421b269dafa68d8 WHIRLPOOL 90a3a7056df7c4da2e605da1578e65b16e0f831370d8b1d399fed48945828604a94f9402b2d53bc4ca26623f1d34e6c45c862bf1f7590ddf9325fd4a053a18fb DIST mingw-w64-v3.2.0.tar.bz2 7053254 SHA256 78a0de610829a1145ae12c4a29603344963a0b8156ba39a9a31a0e79c3b29142 SHA512 dd483bcf7ba0e698a33a0b02a811b181e601cd344b87dafd0f6c477f68efb9a617a4109046fd06735242623f87833cf97688f057583e1378d6d84e7818927593 WHIRLPOOL 99ba5ddaa99c40309d12d75d3953deaf9cc31280ad2446793d1525702963edd1b33e91053e99bdfd06d37980049d30b7fb4e9f3a5358f8277c2fabe587c56037 +DIST mingw-w64-v4.0.1.tar.bz2 10803072 SHA256 89d2524a071b6337dfd9f3b6e6f46d8002b2633f928c833dc4e873a13e045b17 SHA512 a216a09a460c56c29208aee1e1cdb428e856f9c8d59dd399723ccf6d549368f0a13a6aacb046d211ddec7c0a1f1c227d5dd599e4f0c33ba4b6d9c92bd0a7fa1b WHIRLPOOL e021031e2820e918fe0f291624335fadc08641e811f6cf19d45b1586d2ac96c6bff4fb936bcd154a7b48711db9f5faabd27bfdced3a38073b4a20c8471a91915 EBUILD mingw64-runtime-2.0.8.ebuild 2015 SHA256 032d6d13ae4cf387463e0cb2d882e4214b5213893a393b62dfa534053a4db93b SHA512 2010b474e6935950e63476765fa188122ee21153e83b03022d1e1d5dd2c63ce8f1fddfed5bc3900538bb551876fa1b2b1c1ae03db475eb0ccb68cb5f4eabec44 WHIRLPOOL e58bec5b0f8c66a61476f782850b810f84c5ce9de4dfcdaece378acdd593039b66d2968a9b95b16ae76f1b47a1767fba066215cf738b9dbf25feb8d60646376e EBUILD mingw64-runtime-3.0.0.ebuild 1941 SHA256 774637965e445448435ee807fd6caabec50b9f7b766ca63a0771ddbb796ef1dc SHA512 06037a7acc5c776dd81a140151450165f37ac05355c8a9a8a544f2d06bbb6a927d0d2b145dee5dea1bf48bcb04fc86d2a20bec0b07f41932c30c06e88796fe79 WHIRLPOOL d55a080114b64db204c7462ce33cfc0a53e3a0b9d9b1f80d8a6d9074c0b24340f687cd13dc4ccc75691080c4b4f1265996d4c9f292a5b47a1d0f33f88b4e8f54 EBUILD mingw64-runtime-3.1.0.ebuild 1941 SHA256 dd523273a5bebc796914cedab196a05a85610767087cc29c0d8ecc6b9868aeec SHA512 c350055980db87d1f7dfbd8b720403da7e4d0025ef5fdc63beb1df8102601516e3fb6a79688604095fe3856cd81c2662024fb60dab8f42e159a198a41e108a8f WHIRLPOOL d350475f19e7d373aca71368c131959a3964cd2d00c2d883ff52ce179fcc250ac30cbed53ae90716f42307199bb5a45ce9b569e71a75ec1e08b32a79b6584f44 EBUILD mingw64-runtime-3.2.0-r1.ebuild 1944 SHA256 c21eb75825b8e76347b30d767769cca578fb8ccf12e6344ec56dc482e2509673 SHA512 5a5a6eef95bb30fccbf677b9fb38f9754dcf45d23a3d71687e97900623335968419e4e9552293ada254306f79c1ad4b0788fc70566684bdde8e78c90d78915f8 WHIRLPOOL 429d152e8166cfd494f6ec3b8148545365d33a52ee7fce9fabbebc37e0e9c12e85cd1ef5061868db10e5074fe78d2c192f8e9c7801f3dcf23691917ee0565108 -MISC ChangeLog 3415 SHA256 ffe220de1ea12504272e8e11972e3f380aee5c5612a358ec79261af72b611ecd SHA512 47b7fe9eee44e3d7d51e093ecec1a2a67fc44a86b00ccdeee504ea303227951467ed5d61055993ebd0b078fa72e83ae01c7b738800bfac33f0560f53490d2f06 WHIRLPOOL 8c4dd37672a1b59ee6c78b311b7dcba50970e12bca98aa7d63a2b4b9258d72eab7db20eb3c6fef7062f50e867217044b2be0efb2f06bf9e804f72add1616d809 -MISC metadata.xml 228 SHA256 24d02522b86de4d4fdd4a19b0f07556cf0d371ccad8d870339068793dfe18570 SHA512 811d51b71d4a117389dbf64a5c307466c9416761f7fb2b12a335ee501ce515f1bc1924f5dd610cdac06b3ffdec7f58bd75d3a2c3ef9182a1ad1263c07f34593a WHIRLPOOL 9bc77b7dcf1138516c9ae0eae06f6952492acb2ac7f78fad77b2503e6afc7d835a5b7d537354232fa080593e11a3d6bf03cd4716fca1b65825a2c0a40ca377d0 +EBUILD mingw64-runtime-4.0.1.ebuild 2712 SHA256 c968cc01ef3a823d6d0170db7f9d9ce3555ffe9419e49e5035d0140c6537d80d SHA512 6aac880590e2691161eae00f74e8835c5ac40c8a36b01b052027bf003b7f62c3ebad4c72b4c6c749751f99b75fdf805097b5af3d35403e81676241a51edd59bd WHIRLPOOL 224ef3d3c4a258a7238144895ec6d2da4491d0baaf23f27f36c641fbecf41a50cea4c0bbeeaa3ee7d6637f807755a71336b0d5c3eed4fc1c82369be0603bfac8 +MISC ChangeLog 3670 SHA256 7cd9976de775f8d4c760e6860af327fd3ebf5e8a0e104d364c3ad62decf7a352 SHA512 d514d50ad706d755be69f4821cc092a8b73f614526d372437b95c34b71ce181e934b10c4d44ee1ad7727c3c68a0067ba2d3b956f66c16f3ae5602a50472181e8 WHIRLPOOL 55cf99587928e8fbba9ee6c79b70ded995b73fdd01174d95bb767c1de3381905da1bf3c344b4f6b583c53be1a512e594ab3a3c51c604137c9be5cee79258b172 +MISC metadata.xml 346 SHA256 2285586b9c313809dd4bfedb38d4fc48001173cdcd1228ea4cd3a195cb0817d4 SHA512 691d6411195f135790ce7cbae9454c06d30ece63f1a75bc231103e526bfeaae18d63bff37359e505c968c8739938ae8668039977870c541fcc7af3396f0ecef1 WHIRLPOOL 2cca46e1e00b627f07a6a0b953d5a0ff2b001bc44fbaeec683390380520416eb059af22e81f4dd0d4a046d77af136f938620d975542cf44ed98d9b8c318a552a -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 -iQIcBAEBCAAGBQJU8CaqAAoJEPGu1DbS6WIA5l8P/Rcxux256f6Rhq95YCrDK4hU -G5VV05AaoyT6XpSNIy17EFsSG9Pj/TuCyJ9YJOJ8k0Ba3n6tLF6zQ2xnLFdRO9Is -/8NwxWWrabyruEOHz6Ce8SLnmGv5ZThBXE8S2E3rYSkYwbXobPLyYk1Ppf+8ec6i -b8B+g+UghEb68vABK08vSjLyit7x+WUyE9CWHrkkCXs4/sC8yoFG35H9a0Rq2fFH -pddTWvNsOCnbIV8Oo4HL0utvC3FcUJ9JGoZbo9ezSgYAJ+B6p0u65RyDBVfz6NJC -VKQ96L+FfxPl2+7lH6sXAUXVMT0/bJiDJaL1q0+awyzExhRefBZXyQUiaHkOGJT1 -NugYtRK4zVmMxa2DhSg4h8eq/6wB0HpJUyqXzk4zRfa3MPgjf9kgZOAzMVbDs5WB -53NMzpPEkziU8MI4jYyd2iXDAQr2X6BUa1wskJK4mEBhdk/NpTMQx12BG/AHVZ8c -KVK9V5TNfeOdLYXtWDv3Y+JrDCnCZKLAApENOOE7c7gCwmjHZusKjJ/qUqoH7J8q -9Efjv29/EcDMxjre4cQqZQ1Qu3VM+1j7Se8LtGUkNmwvP8LBWTGyi0WVhSTaMMhx -ZjeIkdYljxu8PTY5I4cskbYb8DrAEdT15Jv5zUdXtDbN3TDNo7lyWXmzXT7mkj9D -YseJaBjTm66CM4Um8Id8 -=NnXF +iF4EAREIAAYFAlVIq/8ACgkQXYk9GL8g3FEynQD/bETFhc9qwbpkP9rmlwGhveBk +gLBta8OXUvNPXoKmn8kBAI6hZq3Pj9fQP2tmmzZMF2Z0BZBm/2sRB4HttCcexJq8 +=iUpJ -----END PGP SIGNATURE----- diff --git a/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-build.patch b/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-build.patch new file mode 100644 index 000000000000..6461b98e5044 --- /dev/null +++ b/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-build.patch @@ -0,0 +1,88 @@ +From 67434f57cbb5aba791e9ca973a86859e0736f829 Mon Sep 17 00:00:00 2001 +From: Alon Bar-Lev +Date: Mon, 4 May 2015 21:31:10 +0300 +Subject: [PATCH 2/2] build: autoconf: enable multiple tools and libs + +this somewhat reduces the error checking, but makes code and usage nicer. + +Signed-off-by: Alon Bar-Lev +--- + configure.ac | 55 ++++++++++++------------------------------------------- + 1 file changed, 12 insertions(+), 43 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 468d1b1..1b59821 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -56,32 +56,12 @@ AC_ARG_WITH([libraries], + [Build the extra mingw-w64 libs, where ARG is one of libmangle, pseh, winpthreads, or all])], + [], + [with_libraries=no]) +-AS_CASE([$with_libraries], +- [yes|all],[ +- with_libraries="libmangle,pseh,winpthreads" +- with_libraries_winpthreads=yes +- with_libraries_mangle=yes +- with_libraries_pseh=yes], +- [libmangle],[ +- with_libraries="libmangle" +- with_libraries_winpthreads=no +- with_libraries_mangle=yes +- with_libraries_pseh=no], +- [pseh],[ +- with_libraries="pseh" +- with_libraries_winpthreads=no +- with_libraries_mangle=no +- with_libraries_pseh=yes], +- [winpthreads],[ +- with_libraries="winpthreads" +- with_libraries_winpthreads=yes +- with_libraries_mangle=no +- with_libraries_pseh=no], +- [no],[ +- with_libraries_winpthreads=no +- with_libraries_mangle=no +- with_libraries_pseh=no], +- [MW64_OPTION_ERROR([with-libraries])]) ++for l in winpthreads mangle pseh; do ++ res=`echo "${with_libraries}" | grep $l > /dev/null && echo yes || echo no` ++ AS_CASE([$with_libraries], ++ [all|yes],[res=yes]) ++ AS_VAR_COPY([with_libraries_$l], [res]) ++done + AM_CONDITIONAL([LIBRARIES_MANGLE],[test "x$with_libraries_mangle" = xyes]) + AM_CONDITIONAL([LIBRARIES_PSEH],[test "x$with_libraries_pseh" = xyes]) + AM_CONDITIONAL([LIBRARIES_WINPTHREADS],[test "x$with_libraries_winpthreads" = xyes]) +@@ -96,23 +76,12 @@ AC_ARG_WITH([tools], + [Build the extra mingw-w64 tools, where ARG is one of gendef, genidl, or all])], + [], + [with_tools=no]) +-AS_CASE([$with_tools], +- [yes|all],[ +- with_tools="gendef,genidl" +- with_tools_gendef=yes +- with_tools_genidl=yes], +- [gendef],[ +- with_tools="gendef" +- with_tools_gendef=yes +- with_tools_genidl=no], +- [genidl],[ +- with_tools="genidl" +- with_tools_gendef=no +- with_tools_genidl=yes], +- [no],[ +- with_tools_gendef=no +- with_tools_genidl=no], +- [MW64_OPTION_ERROR([with-tools])]) ++for t in gendef genidl; do ++ res=`echo "${with_tools}" | grep $t > /dev/null && echo yes || echo no` ++ AS_CASE([$with_tools], ++ [all|yes],[res=yes]) ++ AS_VAR_COPY([with_tools_$t], [res]) ++done + AM_CONDITIONAL([TOOLS_GENDEF],[test "x$with_tools_gendef" = xyes]) + AM_CONDITIONAL([TOOLS_GENIDL],[test "x$with_tools_genidl" = xyes]) + AM_COND_IF([TOOLS_GENDEF],[AC_CONFIG_SUBDIRS([mingw-w64-tools/gendef])]) +-- +2.3.6 + diff --git a/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-winpthreads.patch b/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-winpthreads.patch new file mode 100644 index 000000000000..0d3e59dc9dd5 --- /dev/null +++ b/dev-util/mingw64-runtime/files/mingw64-runtime-4.0.1-winpthreads.patch @@ -0,0 +1,86 @@ +From 0adec5d0e1c65fc4ce4f84f3d4bb6738e923e1de Mon Sep 17 00:00:00 2001 +From: Alon Bar-Lev +Date: Mon, 4 May 2015 20:39:52 +0300 +Subject: [PATCH 1/2] build: autoconf: support winpthreads library + +Signed-off-by: Alon Bar-Lev +--- + Makefile.am | 6 +++++- + configure.ac | 15 +++++++++++++-- + 2 files changed, 18 insertions(+), 3 deletions(-) + +diff --git a/Makefile.am b/Makefile.am +index 26a7606..308b6fd 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -14,6 +14,10 @@ if LIBRARIES_PSEH + MAYBE_LIBRARIES_PSEH = mingw-w64-libraries/pseh + endif + ++if LIBRARIES_WINPTHREADS ++ MAYBE_LIBRARIES_WINPTHREADS = mingw-w64-libraries/winpthreads ++endif ++ + if TOOLS_GENDEF + MAYBE_TOOLS_GENDEF = mingw-w64-tools/gendef + endif +@@ -22,7 +26,7 @@ if TOOLS_GENIDL + MAYBE_TOOLS_GENIDL = mingw-w64-tools/genidl + endif + +-SUBDIRS = $(MAYBE_HEADER) $(MAYBE_CRT) $(MAYBE_LIBRARIES_MANGLE) $(MAYBE_LIBRARIES_PSEH) $(MAYBE_TOOLS_GENDEF) $(MAYBE_TOOLS_GENIDL) ++SUBDIRS = $(MAYBE_HEADER) $(MAYBE_CRT) $(MAYBE_LIBRARIES_MANGLE) $(MAYBE_LIBRARIES_PSEH) $(MAYBE_LIBRARIES_WINPTHREADS) $(MAYBE_TOOLS_GENDEF) $(MAYBE_TOOLS_GENIDL) + + DISTCHECK_CONFIGURE_FLAGS = --with-headers --with-crt --with-libraries=all --with-tools=all + +diff --git a/configure.ac b/configure.ac +index 4bb3926..468d1b1 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -53,30 +53,41 @@ AC_MSG_RESULT([$with_crt]) + AC_MSG_CHECKING([whether to build the optional libraries]) + AC_ARG_WITH([libraries], + [AS_HELP_STRING([--with-libraries=ARG], +- [Build the extra mingw-w64 libs, where ARG is one of libmangle, pseh, or all])], ++ [Build the extra mingw-w64 libs, where ARG is one of libmangle, pseh, winpthreads, or all])], + [], + [with_libraries=no]) + AS_CASE([$with_libraries], + [yes|all],[ +- with_libraries="libmangle,pseh" ++ with_libraries="libmangle,pseh,winpthreads" ++ with_libraries_winpthreads=yes + with_libraries_mangle=yes + with_libraries_pseh=yes], + [libmangle],[ + with_libraries="libmangle" ++ with_libraries_winpthreads=no + with_libraries_mangle=yes + with_libraries_pseh=no], + [pseh],[ + with_libraries="pseh" ++ with_libraries_winpthreads=no + with_libraries_mangle=no + with_libraries_pseh=yes], ++ [winpthreads],[ ++ with_libraries="winpthreads" ++ with_libraries_winpthreads=yes ++ with_libraries_mangle=no ++ with_libraries_pseh=no], + [no],[ ++ with_libraries_winpthreads=no + with_libraries_mangle=no + with_libraries_pseh=no], + [MW64_OPTION_ERROR([with-libraries])]) + AM_CONDITIONAL([LIBRARIES_MANGLE],[test "x$with_libraries_mangle" = xyes]) + AM_CONDITIONAL([LIBRARIES_PSEH],[test "x$with_libraries_pseh" = xyes]) ++AM_CONDITIONAL([LIBRARIES_WINPTHREADS],[test "x$with_libraries_winpthreads" = xyes]) + AM_COND_IF([LIBRARIES_MANGLE],[AC_CONFIG_SUBDIRS([mingw-w64-libraries/libmangle])]) + AM_COND_IF([LIBRARIES_PSEH],[AC_CONFIG_SUBDIRS([mingw-w64-libraries/pseh])]) ++AM_COND_IF([LIBRARIES_WINPTHREADS],[AC_CONFIG_SUBDIRS([mingw-w64-libraries/winpthreads])]) + AC_MSG_RESULT([$with_libraries]) + + AC_MSG_CHECKING([whether to build the optional tools]) +-- +2.3.6 + diff --git a/dev-util/mingw64-runtime/metadata.xml b/dev-util/mingw64-runtime/metadata.xml index bf6941f943c3..3afd7c80097e 100644 --- a/dev-util/mingw64-runtime/metadata.xml +++ b/dev-util/mingw64-runtime/metadata.xml @@ -6,5 +6,11 @@ Install idl files. + + Build extra libraries. + + + Build extra tools. + diff --git a/dev-util/mingw64-runtime/mingw64-runtime-4.0.1.ebuild b/dev-util/mingw64-runtime/mingw64-runtime-4.0.1.ebuild new file mode 100644 index 000000000000..48c6178cabc1 --- /dev/null +++ b/dev-util/mingw64-runtime/mingw64-runtime-4.0.1.ebuild @@ -0,0 +1,113 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-util/mingw64-runtime/mingw64-runtime-4.0.1.ebuild,v 1.1 2015/05/05 11:39:40 alonbl Exp $ + +EAPI=5 + +export CBUILD=${CBUILD:-${CHOST}} +export CTARGET=${CTARGET:-${CHOST}} +if [[ ${CTARGET} == ${CHOST} ]] ; then + if [[ ${CATEGORY} == cross-* ]] ; then + export CTARGET=${CATEGORY#cross-} + fi +fi + +WANT_AUTOMAKE="1.15" + +inherit autotools flag-o-matic eutils + +DESCRIPTION="Free Win64 runtime and import library definitions" +HOMEPAGE="http://mingw-w64.sourceforge.net/" +SRC_URI="mirror://sourceforge/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v${PV}.tar.bz2" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="crosscompile_opts_headers-only idl libraries tools" +RESTRICT="strip" + +S="${WORKDIR}/mingw-w64-v${PV}" + +is_crosscompile() { + [[ ${CHOST} != ${CTARGET} ]] +} +just_headers() { + use crosscompile_opts_headers-only && [[ ${CHOST} != ${CTARGET} ]] +} +crt_with() { + just_headers && echo --without-$1 || echo --with-$1 +} +crt_use_enable() { + just_headers && echo --without-$2 || use_enable "$@" +} +crt_use_with() { + just_headers && echo --without-$2 || use_with "$@" +} + +pkg_setup() { + if [[ ${CBUILD} == ${CHOST} ]] && [[ ${CHOST} == ${CTARGET} ]] ; then + die "Invalid configuration" + fi +} + +src_prepare() { + epatch "${FILESDIR}/${P}-winpthreads.patch" + epatch "${FILESDIR}/${P}-build.patch" + eautoreconf +} + +src_configure() { + CHOST=${CTARGET} strip-unsupported-flags + + if ! just_headers; then + mkdir "${WORKDIR}/headers" + pushd "${WORKDIR}/headers" > /dev/null + CHOST=${CTARGET} "${S}/configure" \ + --prefix="${T}/tmproot" \ + --with-headers \ + --without-crt \ + || die + popd > /dev/null + append-cppflags "-I${T}/tmproot/include" + fi + + local extra_conf=() + + case ${CTARGET} in + x86_64*) extra_conf+=( --disable-lib32 --enable-lib64 ) ;; + i?86*) extra_conf+=( --enable-lib32 --disable-lib64 ) ;; + *) die "Unsupported ${CTARGET}" ;; + esac + + CHOST=${CTARGET} econf \ + --prefix=/usr/${CTARGET} \ + --includedir=/usr/${CTARGET}/usr/include \ + --with-headers \ + --enable-sdk \ + $(crt_with crt) \ + $(crt_use_enable idl) \ + $(crt_use_with libraries libraries winpthreads,libmangle) \ + $(crt_use_with tools) \ + "${extra_conf[@]}" +} + +src_compile() { + if ! just_headers; then + emake -C "${WORKDIR}/headers" install + fi + default +} + +src_install() { + default + + if is_crosscompile ; then + # gcc is configured to look at specific hard-coded paths for mingw #419601 + dosym usr /usr/${CTARGET}/mingw + dosym usr /usr/${CTARGET}/${CTARGET} + dosym usr/include /usr/${CTARGET}/sys-include + fi + + env -uRESTRICT CHOST=${CTARGET} prepallstrip + rm -rf "${ED}/usr/share" +} -- 2.26.2