diff options
author | Duncan Coutts <dcoutts@gentoo.org> | 2007-11-05 10:27:49 +0000 |
---|---|---|
committer | Duncan Coutts <dcoutts@gentoo.org> | 2007-11-05 10:27:49 +0000 |
commit | 248caf6443da0401e786ddcdbc141700e650676d (patch) | |
tree | 96ffe9c60c30ea756e6a88c90578e422aa442951 /dev-lang/ghc | |
parent | alpha/ia64/sparc stable wrt #197799 (diff) | |
download | historical-248caf6443da0401e786ddcdbc141700e650676d.tar.gz historical-248caf6443da0401e786ddcdbc141700e650676d.tar.bz2 historical-248caf6443da0401e786ddcdbc141700e650676d.zip |
Use new unified ghc ebuild for 6.2.2 and 6.4.2.
Package-Manager: portage-2.1.3.16
Diffstat (limited to 'dev-lang/ghc')
-rw-r--r-- | dev-lang/ghc/ChangeLog | 8 | ||||
-rw-r--r-- | dev-lang/ghc/Manifest | 58 | ||||
-rw-r--r-- | dev-lang/ghc/files/digest-ghc-6.2.2 | 13 | ||||
-rw-r--r-- | dev-lang/ghc/files/digest-ghc-6.4.2 | 25 | ||||
-rw-r--r-- | dev-lang/ghc/ghc-6.2.2.ebuild | 308 | ||||
-rw-r--r-- | dev-lang/ghc/ghc-6.4.2.ebuild | 410 |
6 files changed, 538 insertions, 284 deletions
diff --git a/dev-lang/ghc/ChangeLog b/dev-lang/ghc/ChangeLog index 0ea7614ed83f..9388fea2aa12 100644 --- a/dev-lang/ghc/ChangeLog +++ b/dev-lang/ghc/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for dev-lang/ghc # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ChangeLog,v 1.139 2007/11/05 02:18:21 dcoutts Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ChangeLog,v 1.140 2007/11/05 10:27:49 dcoutts Exp $ + + 05 Nov 2007; Duncan Coutts <dcoutts@gentoo.org> ghc-6.2.2.ebuild, + ghc-6.4.2.ebuild: + Use new unified ghc ebuild for 6.2.2 and 6.4.2. This merges the + functionality of ghc-bin into the ghc ebuild and eliminates virtual/ghc. + To get the binary version emerge with the "binary" USE flag. 05 Nov 2007; Duncan Coutts <dcoutts@gentoo.org> ghc-6.6.1.ebuild: Add sparc and ppc binaries. Also fix some var quoting QA warnings. diff --git a/dev-lang/ghc/Manifest b/dev-lang/ghc/Manifest index 1ba93d60bcd4..32368a2d4c28 100644 --- a/dev-lang/ghc/Manifest +++ b/dev-lang/ghc/Manifest @@ -33,13 +33,29 @@ AUX ghc-updater 9251 RMD160 1e5b06f4c5b931a4795aaa81069760d3d4a1ab81 SHA1 7ef2df MD5 e4f0146fa94d8e1f76f7099b724c9f34 files/ghc-updater 9251 RMD160 1e5b06f4c5b931a4795aaa81069760d3d4a1ab81 files/ghc-updater 9251 SHA256 7d87201a5055fe830b2b80f85aeb02c0ffdb7a36b96a953f723044ac4a4f3dd3 files/ghc-updater 9251 +DIST ghc-6.2.2-libraries.tar.gz 524182 RMD160 f4ce0df2040f91a5a56cc618e68f1aa2e4bf0185 SHA1 64af9e782f7eeae9f7f47445811f50cf3210f093 SHA256 ebcf8c1fd31c9a33ff64ca888f01e9911464469f59e5432c626b8c686c2d9142 DIST ghc-6.2.2-src.tar.bz2 5406427 RMD160 7afa370c148f2b9c3d53d662da996f5d7c05282d SHA1 9ca5bfed02210d3731a76fab5e25a8c690067fde SHA256 a0fe7eb8d447f25fbc616cdbce2bb4e03961a884c2c37969d1e23588b588a852 +DIST ghc-6.2.2-users_guide.tar.gz 197576 RMD160 d17c2c89d03d911dfa0b449b47814d2e19dc6030 SHA1 7f7e79cb1a57812ac44f3e9881757cc278a8c14b SHA256 846df4bedf44f00a438a276c849289ce1b2d79f3fa53fb16d576517b2da1e509 DIST ghc-6.4.2-alut.patch.gz 6670 RMD160 e6ab2a114f44f6f176a98c9cd6ab1e336662a958 SHA1 879000d18b11d1edc1a32cf720ed24bbc20e8981 SHA256 e116b385df3bb5a5feb92ce92a92bdb0f24115361aedb1bddc9a7e6ce682d8b9 +DIST ghc-6.4.2-libraries.tar.gz 975364 RMD160 e1f19920ba7cfbc92e52fb1e3a770cd6437482c1 SHA1 2640cd220cb6ad08f12f19eda27008be26c76bb9 SHA256 b1d492f1cb8b036f56e7df187730492a6dd993b5d9ce52e4bd42dbebc9044b51 DIST ghc-6.4.2-src.tar.bz2 6954958 RMD160 19943eb2673e663973e64739cdf23720b6f36d38 SHA1 60bcea323f851caa84d49c7731b86164d5cefa42 SHA256 d517e52e0204a077c54cda11b67bf9b6ac3daa47ac7bccf1561afc7c572e6be0 +DIST ghc-6.4.2-users_guide.tar.gz 233341 RMD160 0c0d7325b1535c6e248a25accd068085b8ff8880 SHA1 e255ee25b796b43282caf68697e6a6fdac78bb14 SHA256 8949148e37b6ec7fbbc82f7151ac26c3cadcfec1783e17f672fa527f7366ccdd DIST ghc-6.6-libraries.tar.gz 1221149 RMD160 7c8a8cf26f43f4cbb31f4eee0682f85bf7143daf SHA1 5a407a2df32894a9b7a8e519edd2539f808b960e SHA256 1df171a2d7996b1014c51353ef715010d682d6ff1115dbfa1fd68176dc923236 DIST ghc-6.6-src.tar.bz2 4345587 RMD160 0d8d5cdde21e5ad86fba1023872be316316d14e7 SHA1 9876dbc46ef22684c2cc95e8dce49b2a1f47017e SHA256 79b2a29136d56c8120a526188297603304dc80d3093cda76fde939df7d4dcc7e DIST ghc-6.6-users_guide.tar.gz 255475 RMD160 ecbdff8f0501780641408204fe60946cde392c95 SHA1 13c8e0e5922a8598a7b8c0eb05dbef9c8e1b661c SHA256 7242a6ccf3df6f141f4e493f9dd37def9d036239b819aa5a5d6f3a58489799ef DIST ghc-6.6.1-src.tar.bz2 4339970 RMD160 6b82a74559425fe5fe1fa1b67a83433457bae0ad SHA1 cc1846b4ad607e270721371ce4043b1a017cd10e SHA256 489126ceeb2dbb6a85ef8d87d6792e61e1bc0d5882e4b33a7725410d796132c6 +DIST ghc-bin-6.2.2-r1-ppc.tbz2 21018465 RMD160 4dda12e11ce31d395d1085e441171580832003f7 SHA1 0b0f3c5a77612a52317914730c0ecb15bd75d719 SHA256 453babea6a9c3d3382b9987f5e40d184dd3e591a7b1d1f6bd6d41984d94f4dd4 +DIST ghc-bin-6.2.2-r1-sparc.tbz2 16189582 RMD160 0ba8ff87c91abcd43988c21df8537eec0932c6a3 SHA1 404333d666256164bf056f6144f0b21094719e1b SHA256 5d225e05e73cb85500b4a1860a4dd82adbb9edc4791d087341b4458e70022cc3 +DIST ghc-bin-6.2.2-r1-x86.tbz2 14561932 RMD160 b8e6a08b269257689efdc95d698a9e2b86c6d3e3 SHA1 71da573a12385b69a872fb39edeb7b06f1db38b2 SHA256 24a4ea7fe9b8ba58f84e0d68012158e70972a1caacd482d6c84905bda4502f63 +DIST ghc-bin-6.4.2-alpha.tbz2 30930863 RMD160 f53968b2b9329dd4ffb15dfb64c3e7748e7fcfc2 SHA1 2915deac0a915d9c317d8781a3179041daa235c9 SHA256 8668d6b4d28a6567fb17665d41784c61576cabf6d80cf47c8b66d1f3f4178a3b +DIST ghc-bin-6.4.2-amd64.tbz2 18554509 RMD160 f4b9ee0041d2a005a1d2d98290dc89eb120c5939 SHA1 d134942591fdfb17bd1b8e010220ea1086e85aca SHA256 8466a5f017a09d5bee2bd4f28cb0fa690cd2bf0f6c9fedd892624c7f1096d214 +DIST ghc-bin-6.4.2-hppa.tbz2 33914952 RMD160 c20d9a783abcfdda1a69b63e941c9f5c1fd587a0 SHA1 99a83e7c3bf5a6e7dec450ddd8a565d39803921d SHA256 6c036e313b4d67ab4940e62a3719589c5e94591ac8fe96ed595796876dd4bd88 +DIST ghc-bin-6.4.2-ia64.tbz2 28944776 RMD160 85f9a3f09e9f319cea0c8a253fdb03885ff7f13e SHA1 8124cb8b39c6e11c8373dfb0289c337617bc8f11 SHA256 7ac02b0277bbbc92aea4de150404ebf5b12445db197b08573446cad901638f12 +DIST ghc-bin-6.4.2-ppc.tbz2 22994932 RMD160 3ee3b26a1b98ceb085a2ca12e9e9e791c245ba86 SHA1 747ee3f204389c68e7c66d20ce2d535e2992ab20 SHA256 1239845ddaafe0bbfe8e24a13a6a7a7ba4462f313227e28d47beb644e876979c +DIST ghc-bin-6.4.2-ppc64.tbz2 28817831 RMD160 98f4e0800233d0b75c519be26b77fd2455fa167d SHA1 d216e5c03d7cce7e3a109b754cde6c85596c4d68 SHA256 788a4c4e5730afd921bfe2c84c894b4190422a5d9e6d18d135de92976446d40a +DIST ghc-bin-6.4.2-sparc.tbz2 22175545 RMD160 fa8fa8d85a167db895ea74b9ce40590ceae503ab SHA1 0dd7de97eaadf548d152300a131629371648a8aa SHA256 c95edaff53778edcfd275e41f70cadc2fd7e83c058b5d09e2a44081ae1c29d30 +DIST ghc-bin-6.4.2-x86-fbsd.tbz2 19091807 RMD160 6071878b02b87066f8937b671d6414330a41a841 SHA1 9f3a66fcfe872980d073e5f6cb309dcee1a7d2cb SHA256 f2a397d233a491ab65ab43223e7657f7fc47311413e168bcd6a735e705c1acf3 +DIST ghc-bin-6.4.2-x86.tbz2 19367589 RMD160 5d3ad1b92c3785db1090799ee6da6182a4771248 SHA1 71876713bbe4cbd335ac50118c9c50219e02d2a5 SHA256 9628c3d3ca3c095c5c423cffb0d0daf801e518f6d6ace17c032c6ca6d5e3e24c DIST ghc-bin-6.6-alpha.tbz2 35338275 RMD160 82b7dca5f3c8b89e7e395da95d596197eca92888 SHA1 931a6d3db14272a72398ed4b520a162f78c84a27 SHA256 3a8e6cacccdb95313a22b8a8c27ecc0311ef83380f303a286f1d8ab216aa4f5d DIST ghc-bin-6.6-amd64.tbz2 26093530 RMD160 b44c90a8e3f99a462af0400d0d31c315833606bb SHA1 1bde6e886df681da8ff65529ca1fd288e1b768a0 SHA256 acde821d26abbd0838e5bcd41cbde0daf5a538fea7619e3f2bc6cbe491d4b387 DIST ghc-bin-6.6-ppc.tbz2 34668445 RMD160 33f811104146dc8ef4d2839f71d39eb821128515 SHA1 b7ab12fe30ada669b7241bd604280674d94a8284 SHA256 f0bc5583396666da4f03f519cec9fc239e96ae06d5fdb5bd951de8dae1cb1d79 @@ -52,14 +68,14 @@ DIST ghc-bin-6.6.1-ppc.tbz2 36241311 RMD160 af8fbaa06d9a13337612b44b2131ee3a95a7 DIST ghc-bin-6.6.1-sparc.tbz2 31791719 RMD160 5cfd2aebfc1aae1c4fbb7bd39c6fd9715ad041cd SHA1 868a811b9cb00ab1c82e7353a0a35f5918e38944 SHA256 ecfd0dd250390d5e0a1a32e5be0bfac70f73e98d1a946641bd8be23c91e47706 DIST ghc-bin-6.6.1-x86.tbz2 26134077 RMD160 fcc31115073c2c0c4be75dce0253cb9bca5e45d3 SHA1 2c6e4bfadbae714b2f8a5da8efbc43f8124e6f8d SHA256 17a9b7125ae52c7d20f177214919837c95f96d6d997d729e493a0b94bdb84d29 DIST ghc-testsuite-6.4.2.tar.gz 1181389 RMD160 1eea6a19a9fca6b3d56a6f29b69289cb88af8173 SHA1 7ada60fe2abb9208d841787781d522d5a1110dc2 SHA256 1a864243e922c233049585fa3bf4a86a0ca3e7b3ffebf26245eb037f15dd4d12 -EBUILD ghc-6.2.2.ebuild 7426 RMD160 6b770de0aaef72a60a18784c44f9bddac1d8212c SHA1 2028d77f73ea2e9b46c5b9febdf148d563fd324f SHA256 9ac559bfc0ba3a9c4520866c8fd63c2455c17e45416780b7cf9f34cb08334efa -MD5 a6bb05f427575b5ee11f452c51b4583a ghc-6.2.2.ebuild 7426 -RMD160 6b770de0aaef72a60a18784c44f9bddac1d8212c ghc-6.2.2.ebuild 7426 -SHA256 9ac559bfc0ba3a9c4520866c8fd63c2455c17e45416780b7cf9f34cb08334efa ghc-6.2.2.ebuild 7426 -EBUILD ghc-6.4.2.ebuild 10070 RMD160 19ad879eb049280ee9941735313323b00f3b7ee7 SHA1 8bbbf7da81a0a400be1fbdc235983615e78084b2 SHA256 d35743be192f8ddd02b5bdd79e1f571a8ce45a83a3f3d1cf1b530f056197b4f6 -MD5 c057896fc37c0f44adb8a8f0bf08d3b7 ghc-6.4.2.ebuild 10070 -RMD160 19ad879eb049280ee9941735313323b00f3b7ee7 ghc-6.4.2.ebuild 10070 -SHA256 d35743be192f8ddd02b5bdd79e1f571a8ce45a83a3f3d1cf1b530f056197b4f6 ghc-6.4.2.ebuild 10070 +EBUILD ghc-6.2.2.ebuild 10547 RMD160 32cd06496587f8d1cd8c91a46447df1d05985e7c SHA1 275a761962f680cc32ebfec6e840064ad20d922d SHA256 3e69e939d2085f8e4395a0230a7f57b4c477cad43880f8526e7598bcbd46dcf4 +MD5 6dd563706bfb1eda2b16dc4336749b4d ghc-6.2.2.ebuild 10547 +RMD160 32cd06496587f8d1cd8c91a46447df1d05985e7c ghc-6.2.2.ebuild 10547 +SHA256 3e69e939d2085f8e4395a0230a7f57b4c477cad43880f8526e7598bcbd46dcf4 ghc-6.2.2.ebuild 10547 +EBUILD ghc-6.4.2.ebuild 13730 RMD160 1c771f24e81c97f813eedfaee5584d5c6d71214d SHA1 f59c364ed831c1a7f829384ae2839644954800ec SHA256 c03f24e637509c45179762ec04888e87ffb02f2316c58d99f566039c8fa56a2d +MD5 1d4c20c9f7f365519d5bd8223dbe9288 ghc-6.4.2.ebuild 13730 +RMD160 1c771f24e81c97f813eedfaee5584d5c6d71214d ghc-6.4.2.ebuild 13730 +SHA256 c03f24e637509c45179762ec04888e87ffb02f2316c58d99f566039c8fa56a2d ghc-6.4.2.ebuild 13730 EBUILD ghc-6.6.1.ebuild 12360 RMD160 8d21e2c6f0fa54e67f189f335252e74c6aaea8ad SHA1 854cc4ca76e810ca6e735e321de1ae6a5e2291b7 SHA256 8d6bd70b0aa5793176f2bab1df283b2f5e2bb2f41dd35e6f23a2949b77be5abe MD5 8b4b2a77818aaf951718c3f478da350c ghc-6.6.1.ebuild 12360 RMD160 8d21e2c6f0fa54e67f189f335252e74c6aaea8ad ghc-6.6.1.ebuild 12360 @@ -68,20 +84,20 @@ EBUILD ghc-6.6.ebuild 10937 RMD160 3ed0d2c91f30e94fc99af3f97fdca1b740601d83 SHA1 MD5 85329ed1d3dafe1c5df874a160d2017f ghc-6.6.ebuild 10937 RMD160 3ed0d2c91f30e94fc99af3f97fdca1b740601d83 ghc-6.6.ebuild 10937 SHA256 3bc383011bce6086e3c6ae4e3eb949a27b97ddd9bb61123a08662ed0627a3fa1 ghc-6.6.ebuild 10937 -MISC ChangeLog 23951 RMD160 393f227ade7fba4bf872e77751627e3e68f01839 SHA1 92f3d46d7f3f41067cd010de64e9527a84262e1b SHA256 d6aaaec819c2826854dfdbe8c63021fd7285300b4f94e86d9bfd7f45d780bd1f -MD5 76b0db38c84d0822df5150f8e5e1faf5 ChangeLog 23951 -RMD160 393f227ade7fba4bf872e77751627e3e68f01839 ChangeLog 23951 -SHA256 d6aaaec819c2826854dfdbe8c63021fd7285300b4f94e86d9bfd7f45d780bd1f ChangeLog 23951 +MISC ChangeLog 24244 RMD160 47e4a24fccb07c3e83028ab824891cfef56f9f84 SHA1 3a175799152e0256942a3f6b05da1903e5d2f839 SHA256 dcfa9a8b79ef9566044d20a9a022ecfdbbc69b870d4c5a0df5945f5049793c75 +MD5 d96e25ff0b39d2c7bead6ee18597baf6 ChangeLog 24244 +RMD160 47e4a24fccb07c3e83028ab824891cfef56f9f84 ChangeLog 24244 +SHA256 dcfa9a8b79ef9566044d20a9a022ecfdbbc69b870d4c5a0df5945f5049793c75 ChangeLog 24244 MISC metadata.xml 223 RMD160 7783e6057effb8b8f0b79cffe8b557b32c633839 SHA1 7b962c77f2e38479a9d1621ec8d307ca9f761753 SHA256 1d00c8be162a6cb87b3de440b3e63e10b39c12d56e8fbfe592e75aed872b2508 MD5 c694674dcbef799cd4fdb6914683ebff metadata.xml 223 RMD160 7783e6057effb8b8f0b79cffe8b557b32c633839 metadata.xml 223 SHA256 1d00c8be162a6cb87b3de440b3e63e10b39c12d56e8fbfe592e75aed872b2508 metadata.xml 223 -MD5 e15aa904a6de695d1d97c70b426d2133 files/digest-ghc-6.2.2 247 -RMD160 08fa98200a54512a79a687475e4a65ccc0f4b28f files/digest-ghc-6.2.2 247 -SHA256 7fc3b897f80347476050b06f1749dfeaddb2c7d2c95dac7584c51588b29853b1 files/digest-ghc-6.2.2 247 -MD5 e0d5838a93fd2efddbb7b3ad9bc2cf1b files/digest-ghc-6.4.2 753 -RMD160 0d029ce257de088bf011643c75a1eb52796d3802 files/digest-ghc-6.4.2 753 -SHA256 84f4b6adad832de57cc219499590df79b6be7ac5c96ec975e15aa37370269d40 files/digest-ghc-6.4.2 753 +MD5 8ed762277b9219611317734d99caedd5 files/digest-ghc-6.2.2 1417 +RMD160 7afee9072dade11cef5ecf602fe51d2a23b4d67f files/digest-ghc-6.2.2 1417 +SHA256 56d10e47e9939bbce11b687514060d2ccbfb8baebbcab0ec292354e8d520f8c5 files/digest-ghc-6.2.2 1417 +MD5 6308d48d87902c0291684404af3b51c8 files/digest-ghc-6.4.2 3034 +RMD160 86dc4ce1fb4ef0384fc85f4b7a10c5a8400f052d files/digest-ghc-6.4.2 3034 +SHA256 5cc8ac805cef4c138b20821b1997840ca595964b542e3c0bfdac0bff92f09a0e files/digest-ghc-6.4.2 3034 MD5 a5e305ef4ed8c9ab526bb04cb5af9f31 files/digest-ghc-6.6 2009 RMD160 e2f5c6cdc2b2922ff3ea67e8a85c6e874f5de0ef files/digest-ghc-6.6 2009 SHA256 4566f2c019143e537d54bf492ebe22b2c8f4deedbb276a9000f720bca11779c5 files/digest-ghc-6.6 2009 @@ -91,7 +107,7 @@ SHA256 124664b34f856301c151a1f332970718c6a6e6930b2ac22b189897be7b3419f2 files/di -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) -iD8DBQFHLn4znUVyUObPUL4RAoFAAJ43xnoGQy15aetv9c5PJfuGPmUdyQCeOuxF -F6TsFxMtSl/vEui+j74RMAQ= -=eZh5 +iD8DBQFHLvDtnUVyUObPUL4RAj0OAKCJ0zts56lmf4sdWGzDB1OOUoE/vwCffNdG +50Th+1vuu1Q8um2IZFDK2M4= +=x0Ae -----END PGP SIGNATURE----- diff --git a/dev-lang/ghc/files/digest-ghc-6.2.2 b/dev-lang/ghc/files/digest-ghc-6.2.2 index b077d9b08c69..07a04d24f55f 100644 --- a/dev-lang/ghc/files/digest-ghc-6.2.2 +++ b/dev-lang/ghc/files/digest-ghc-6.2.2 @@ -1,3 +1,16 @@ +MD5 e81174308a2782ab83b23ef009ce44f2 ghc-6.2.2-libraries.tar.gz 524182 +RMD160 f4ce0df2040f91a5a56cc618e68f1aa2e4bf0185 ghc-6.2.2-libraries.tar.gz 524182 +SHA256 ebcf8c1fd31c9a33ff64ca888f01e9911464469f59e5432c626b8c686c2d9142 ghc-6.2.2-libraries.tar.gz 524182 MD5 42088bff4de30e7c3a277cfa55d5589e ghc-6.2.2-src.tar.bz2 5406427 RMD160 7afa370c148f2b9c3d53d662da996f5d7c05282d ghc-6.2.2-src.tar.bz2 5406427 SHA256 a0fe7eb8d447f25fbc616cdbce2bb4e03961a884c2c37969d1e23588b588a852 ghc-6.2.2-src.tar.bz2 5406427 +MD5 5475d32b4e26c5d67850808ff3032558 ghc-6.2.2-users_guide.tar.gz 197576 +RMD160 d17c2c89d03d911dfa0b449b47814d2e19dc6030 ghc-6.2.2-users_guide.tar.gz 197576 +SHA256 846df4bedf44f00a438a276c849289ce1b2d79f3fa53fb16d576517b2da1e509 ghc-6.2.2-users_guide.tar.gz 197576 +RMD160 4dda12e11ce31d395d1085e441171580832003f7 ghc-bin-6.2.2-r1-ppc.tbz2 21018465 +SHA256 453babea6a9c3d3382b9987f5e40d184dd3e591a7b1d1f6bd6d41984d94f4dd4 ghc-bin-6.2.2-r1-ppc.tbz2 21018465 +RMD160 0ba8ff87c91abcd43988c21df8537eec0932c6a3 ghc-bin-6.2.2-r1-sparc.tbz2 16189582 +SHA256 5d225e05e73cb85500b4a1860a4dd82adbb9edc4791d087341b4458e70022cc3 ghc-bin-6.2.2-r1-sparc.tbz2 16189582 +MD5 707ec1a9e6d298c2d357a1be031ead83 ghc-bin-6.2.2-r1-x86.tbz2 14561932 +RMD160 b8e6a08b269257689efdc95d698a9e2b86c6d3e3 ghc-bin-6.2.2-r1-x86.tbz2 14561932 +SHA256 24a4ea7fe9b8ba58f84e0d68012158e70972a1caacd482d6c84905bda4502f63 ghc-bin-6.2.2-r1-x86.tbz2 14561932 diff --git a/dev-lang/ghc/files/digest-ghc-6.4.2 b/dev-lang/ghc/files/digest-ghc-6.4.2 index 535bdc990220..005707551351 100644 --- a/dev-lang/ghc/files/digest-ghc-6.4.2 +++ b/dev-lang/ghc/files/digest-ghc-6.4.2 @@ -1,9 +1,34 @@ MD5 2719f349e10f883963ffe4b1537106b6 ghc-6.4.2-alut.patch.gz 6670 RMD160 e6ab2a114f44f6f176a98c9cd6ab1e336662a958 ghc-6.4.2-alut.patch.gz 6670 SHA256 e116b385df3bb5a5feb92ce92a92bdb0f24115361aedb1bddc9a7e6ce682d8b9 ghc-6.4.2-alut.patch.gz 6670 +MD5 da0c29eec955c2218a2434eaeda9dccd ghc-6.4.2-libraries.tar.gz 975364 +RMD160 e1f19920ba7cfbc92e52fb1e3a770cd6437482c1 ghc-6.4.2-libraries.tar.gz 975364 +SHA256 b1d492f1cb8b036f56e7df187730492a6dd993b5d9ce52e4bd42dbebc9044b51 ghc-6.4.2-libraries.tar.gz 975364 MD5 a394bf14e94c3bca5507d568fcc03375 ghc-6.4.2-src.tar.bz2 6954958 RMD160 19943eb2673e663973e64739cdf23720b6f36d38 ghc-6.4.2-src.tar.bz2 6954958 SHA256 d517e52e0204a077c54cda11b67bf9b6ac3daa47ac7bccf1561afc7c572e6be0 ghc-6.4.2-src.tar.bz2 6954958 +MD5 bf0aaab4470184d0587bde1428e2e984 ghc-6.4.2-users_guide.tar.gz 233341 +RMD160 0c0d7325b1535c6e248a25accd068085b8ff8880 ghc-6.4.2-users_guide.tar.gz 233341 +SHA256 8949148e37b6ec7fbbc82f7151ac26c3cadcfec1783e17f672fa527f7366ccdd ghc-6.4.2-users_guide.tar.gz 233341 +RMD160 f53968b2b9329dd4ffb15dfb64c3e7748e7fcfc2 ghc-bin-6.4.2-alpha.tbz2 30930863 +SHA256 8668d6b4d28a6567fb17665d41784c61576cabf6d80cf47c8b66d1f3f4178a3b ghc-bin-6.4.2-alpha.tbz2 30930863 +MD5 43a086bf746c332f30f379001d8a1ddf ghc-bin-6.4.2-amd64.tbz2 18554509 +RMD160 f4b9ee0041d2a005a1d2d98290dc89eb120c5939 ghc-bin-6.4.2-amd64.tbz2 18554509 +SHA256 8466a5f017a09d5bee2bd4f28cb0fa690cd2bf0f6c9fedd892624c7f1096d214 ghc-bin-6.4.2-amd64.tbz2 18554509 +RMD160 c20d9a783abcfdda1a69b63e941c9f5c1fd587a0 ghc-bin-6.4.2-hppa.tbz2 33914952 +SHA256 6c036e313b4d67ab4940e62a3719589c5e94591ac8fe96ed595796876dd4bd88 ghc-bin-6.4.2-hppa.tbz2 33914952 +RMD160 85f9a3f09e9f319cea0c8a253fdb03885ff7f13e ghc-bin-6.4.2-ia64.tbz2 28944776 +SHA256 7ac02b0277bbbc92aea4de150404ebf5b12445db197b08573446cad901638f12 ghc-bin-6.4.2-ia64.tbz2 28944776 +RMD160 3ee3b26a1b98ceb085a2ca12e9e9e791c245ba86 ghc-bin-6.4.2-ppc.tbz2 22994932 +SHA256 1239845ddaafe0bbfe8e24a13a6a7a7ba4462f313227e28d47beb644e876979c ghc-bin-6.4.2-ppc.tbz2 22994932 +RMD160 98f4e0800233d0b75c519be26b77fd2455fa167d ghc-bin-6.4.2-ppc64.tbz2 28817831 +SHA256 788a4c4e5730afd921bfe2c84c894b4190422a5d9e6d18d135de92976446d40a ghc-bin-6.4.2-ppc64.tbz2 28817831 +RMD160 fa8fa8d85a167db895ea74b9ce40590ceae503ab ghc-bin-6.4.2-sparc.tbz2 22175545 +SHA256 c95edaff53778edcfd275e41f70cadc2fd7e83c058b5d09e2a44081ae1c29d30 ghc-bin-6.4.2-sparc.tbz2 22175545 +RMD160 6071878b02b87066f8937b671d6414330a41a841 ghc-bin-6.4.2-x86-fbsd.tbz2 19091807 +SHA256 f2a397d233a491ab65ab43223e7657f7fc47311413e168bcd6a735e705c1acf3 ghc-bin-6.4.2-x86-fbsd.tbz2 19091807 +RMD160 5d3ad1b92c3785db1090799ee6da6182a4771248 ghc-bin-6.4.2-x86.tbz2 19367589 +SHA256 9628c3d3ca3c095c5c423cffb0d0daf801e518f6d6ace17c032c6ca6d5e3e24c ghc-bin-6.4.2-x86.tbz2 19367589 MD5 6d97897b1f5cef7bf4bdc7fa6745d853 ghc-testsuite-6.4.2.tar.gz 1181389 RMD160 1eea6a19a9fca6b3d56a6f29b69289cb88af8173 ghc-testsuite-6.4.2.tar.gz 1181389 SHA256 1a864243e922c233049585fa3bf4a86a0ca3e7b3ffebf26245eb037f15dd4d12 ghc-testsuite-6.4.2.tar.gz 1181389 diff --git a/dev-lang/ghc/ghc-6.2.2.ebuild b/dev-lang/ghc/ghc-6.2.2.ebuild index fa8bedac8ada..786ebf57ae59 100644 --- a/dev-lang/ghc/ghc-6.2.2.ebuild +++ b/dev-lang/ghc/ghc-6.2.2.ebuild @@ -1,18 +1,20 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ghc-6.2.2.ebuild,v 1.24 2007/11/05 02:18:21 dcoutts Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ghc-6.2.2.ebuild,v 1.25 2007/11/05 10:27:49 dcoutts Exp $ # Brief explanation of the bootstrap logic: # -# ghc requires ghc-bin to bootstrap. -# Therefore, -# (1) both ghc-bin and ghc provide virtual/ghc -# (2) virtual/ghc *must* default to ghc-bin -# (3) ghc depends on virtual/ghc +# Previous ghc ebuilds have been split into two: ghc and ghc-bin, +# where ghc-bin was primarily used for bootstrapping purposes. +# From now on, these two ebuilds have been combined, with the +# binary USE flag used to determine whether or not the pre-built +# binary package should be emerged or whether ghc should be compiled +# from source. If the latter, then the relevant ghc-bin for the +# arch in question will be used in the working directory to compile +# ghc from source. # -# This solution has the advantage that the binary distribution -# can be removed once an forall after the first succesful install -# of ghc. +# This solution has the advantage of allowing us to retain the one +# ebuild for both packages, and thus phase out virtual/ghc. # Note to users of hardened gcc-3.x: # @@ -31,42 +33,35 @@ inherit base eutils flag-o-matic toolchain-funcs ghc-package DESCRIPTION="The Glasgow Haskell Compiler" HOMEPAGE="http://www.haskell.org/ghc/" -SRC_URI="http://www.haskell.org/ghc/dist/${PV}/ghc-${PV}-src.tar.bz2" +SRC_URI="!binary? ( http://haskell.org/ghc/dist/${PV}/${P}-src.tar.bz2 ) + doc? ( mirror://gentoo/${P}-libraries.tar.gz + mirror://gentoo/${P}-users_guide.tar.gz ) + ppc? ( mirror://gentoo/ghc-bin-${PV}-r1-ppc.tbz2 ) + sparc? ( mirror://gentoo/ghc-bin-${PV}-r1-sparc.tbz2 ) + x86? ( mirror://gentoo/ghc-bin-${PV}-r1-x86.tbz2 )" -LICENSE="as-is" +LICENSE="BSD" SLOT="0" KEYWORDS="-* ppc sparc x86" -IUSE="doc opengl" +IUSE="binary doc ghcbootstrap opengl" + +LOC="/opt/ghc" # location for installation of binary version PROVIDE="virtual/ghc" RDEPEND=" + !dev-lang/ghc-bin >=sys-devel/gcc-2.95.3 >=sys-devel/binutils-2.17 >=dev-lang/perl-5.6.1 >=dev-libs/gmp-4.1 - >=sys-libs/readline-4.2 + =sys-libs/readline-5* opengl? ( virtual/opengl virtual/glu virtual/glut )" -# ghc cannot usually be bootstrapped using later versions ... -DEPEND="${RDEPEND} - <virtual/ghc-6.3 - !>=virtual/ghc-6.4 - doc? ( ~app-text/docbook-sgml-dtd-3.1 - >=app-text/docbook-dsssl-stylesheets-1.64 - >=app-text/openjade-1.3.1 - >=app-text/sgml-common-0.6.3 - >=dev-haskell/haddock-0.6-r2 )" - -pkg_setup() { - if test $(gcc-major-version) -gt 3; then - eerror "ghc-6.2.2 does not work with gcc-4.x, only 3.x or older" - eerror "You can either use gcc-config to switch to gcc-3.x" - eerror "or you emerge '>=dev-lang/ghc-6.4' or later." - die "ghc-6.2.2 does not work with gcc-4.x, only 3.x or older" - fi -} +DEPEND="${RDEPEND}" +# In the ghcbootstrap case we rely on the developer having +# >=ghc-5.04.3 on their $PATH already append-ghc-cflags() { local flag compile assemble link @@ -118,113 +113,208 @@ ghc_setup_cflags() { gcc-specs-ssp && append-ghc-cflags compile -fno-stack-protector } -ghc_setup_wrapper() { - echo '#!/bin/sh' - echo "GHCBIN=\"$(ghc-libdir)/ghc-$1\";" - echo "TOPDIROPT=\"-B$(ghc-libdir)\";" - echo "GHC_CFLAGS=\"${GHC_CFLAGS}\";" - echo '# Mini-driver for GHC' - echo 'exec $GHCBIN $TOPDIROPT $GHC_CFLAGS ${1+"$@"}' +pkg_setup() { + if test $(gcc-major-version) -gt 3; then + eerror "ghc-6.2.2 does not work with gcc-4.x, only 3.x or older" + eerror "You can either use gcc-config to switch to gcc-3.x" + eerror "or you emerge '>=dev-lang/ghc-6.4' or later." + die "ghc-6.2.2 does not work with gcc-4.x, only 3.x or older" + fi + + if use ghcbootstrap; then + ewarn "You requested ghc bootstrapping, this is usually only used" + ewarn "by Gentoo developers to make binary .tbz2 packages for" + ewarn "use with the ghc ebuild's USE=\"binary\" feature." + use binary && \ + die "USE=\"ghcbootstrap binary\" is not a valid combination." + use doc && \ + die "USE=\"ghcbootstrap doc\" is not a valid combination" + [[ -z $(type -P ghc) ]] && \ + die "Could not find a ghc to bootstrap with." + fi + + if use binary; then + if use opengl || use doc; then + ewarn "The binary build does not include the docs or OpenGL bindings" + ewarn "If you want those features, emerge with USE=\"-binary\"" + fi + fi + + set_config +} + +set_config() { + # make this a separate function and call it several times as portage doesn't + # remember the variables properly between the fuctions. + use binary && GHC_PREFIX="/opt/ghc" || GHC_PREFIX="/usr" } src_unpack() { + # Create the ${S} dir if we're using the binary version + use binary && mkdir "${S}" + base_src_unpack ghc_setup_cflags - # Modify the ghc driver script to use GHC_CFLAGS - echo "SCRIPT_SUBST_VARS += GHC_CFLAGS" >> "${S}/ghc/driver/ghc/Makefile" - echo "GHC_CFLAGS = ${GHC_CFLAGS}" >> "${S}/ghc/driver/ghc/Makefile" - sed -i -e 's|$TOPDIROPT|$TOPDIROPT $GHC_CFLAGS|' "${S}/ghc/driver/ghc/ghc.sh" + if use binary; then + + # Move unpacked files to the expected place + mv "${WORKDIR}/usr" "${S}" - # Patch to fix a mis-compilation in the rts due to strict aliasing, - # should be fixed upstream for 6.4.3 and 6.6. Fixes bug #135651. - echo 'GC_HC_OPTS += -optc-fno-strict-aliasing' >> "${S}/ghc/rts/Makefile" + # Relocate from /usr to /opt/ghc + sed -i -e "s|/usr|${LOC}|g" \ + "${S}/usr/bin/ghc-${PV}" \ + "${S}/usr/bin/ghci-${PV}" \ + "${S}/usr/bin/ghc-pkg-${PV}" \ + "${S}/usr/bin/hsc2hs" \ + "${S}/usr/$(get_libdir)/${P}/package.conf" \ + || die "Relocating ghc from /usr to /opt/ghc failed" - # Don't strip binaries on install. See QA warnings in bug #140369. - sed -i -e 's/SRC_INSTALL_BIN_OPTS += -s//' "${S}/mk/config.mk.in" + sed -i -e "s|/usr/$(get_libdir)|${LOC}/$(get_libdir)|" \ + "${S}/usr/bin/ghcprof" + + else + # Modify the ghc driver script to use GHC_CFLAGS + echo "SCRIPT_SUBST_VARS += GHC_CFLAGS" >> "${S}/ghc/driver/ghc/Makefile" + echo "GHC_CFLAGS = ${GHC_CFLAGS}" >> "${S}/ghc/driver/ghc/Makefile" + sed -i -e 's|$TOPDIROPT|$TOPDIROPT $GHC_CFLAGS|' "${S}/ghc/driver/ghc/ghc.sh" + + if ! use ghcbootstrap; then + # Relocate from /usr to ${WORKDIR}/usr + sed -i -e "s|/usr|${WORKDIR}/usr|g" \ + "${WORKDIR}/usr/bin/ghc-${PV}" \ + "${WORKDIR}/usr/bin/ghci-${PV}" \ + "${WORKDIR}/usr/bin/ghc-pkg-${PV}" \ + "${WORKDIR}/usr/bin/hsc2hs" \ + "${WORKDIR}/usr/$(get_libdir)/${P}/package.conf" \ + || die "Relocating ghc from /usr to workdir failed" + fi + + # Patch to fix a mis-compilation in the rts due to strict aliasing, + # should be fixed upstream for 6.4.3 and 6.6. Fixes bug #135651. + echo 'GC_HC_OPTS += -optc-fno-strict-aliasing' >> "${S}/ghc/rts/Makefile" + + # Don't strip binaries on install. See QA warnings in bug #140369. + sed -i -e 's/SRC_INSTALL_BIN_OPTS += -s//' "${S}/mk/config.mk.in" + fi } src_compile() { - # initialize build.mk - echo '# Gentoo changes' > mk/build.mk + if ! use binary; then - # We also need to use the GHC_CFLAGS flags when building ghc itself - echo "SRC_HC_OPTS+=${GHC_CFLAGS}" >> mk/build.mk - echo "SRC_CC_OPTS+=${CFLAGS} -Wa,--noexecstack" >> mk/build.mk + # initialize build.mk + echo '# Gentoo changes' > mk/build.mk - # determine what to do with documentation - if use doc; then - echo SGMLDocWays="html" >> mk/build.mk - else + # We also need to use the GHC_CFLAGS flags when building ghc itself + echo "SRC_HC_OPTS+=${GHC_CFLAGS}" >> mk/build.mk + echo "SRC_CC_OPTS+=${CFLAGS} -Wa,--noexecstack" >> mk/build.mk + + # We can't depend on haddock so we never build docs + # and we rely on pre-built ones instead echo SGMLDocWays="" >> mk/build.mk # needed to prevent haddock from being called echo NO_HADDOCK_DOCS=YES >> mk/build.mk - fi - # circumvent a very strange bug that seems related with ghc producing too much - # output while being filtered through tee (e.g. due to portage logging) - # reported as bug #111183 - echo "SRC_HC_OPTS+=-fno-warn-deprecations" >> mk/build.mk + # circumvent a very strange bug that seems related with ghc producing too much + # output while being filtered through tee (e.g. due to portage logging) + # reported as bug #111183 + echo "SRC_HC_OPTS+=-fno-warn-deprecations" >> mk/build.mk - # Required for some architectures, because they don't support ghc fully ... - use ppc || use sparc && echo "SplitObjs=NO" >> mk/build.mk - use sparc && echo "GhcWithInterpreter=NO" >> mk/build.mk + # Required for some architectures, because they don't support ghc fully ... + use ppc || use sparc && echo "SplitObjs=NO" >> mk/build.mk + use sparc && echo "GhcWithInterpreter=NO" >> mk/build.mk - GHC_CFLAGS="" ghc_setup_wrapper $(ghc-version) > "${T}/ghc.sh" - chmod +x "${T}/ghc.sh" + # Get ghc from the unpacked binary .tbz2 + # except when bootstrapping we just pick ghc up off the path + use ghcbootstrap || \ + export PATH="${WORKDIR}/usr/bin:${PATH}" - # unset SGML_CATALOG_FILES because documentation installation - # breaks otherwise ... - SGML_CATALOG_FILES="" econf \ - --with-ghc="${T}/ghc.sh" \ - $(use_enable opengl hopengl) \ - || die "econf failed" + # Note that --disable-hopengl actually enables it. We have to ommit + # the flag to disable opengl. + econf \ + $(use opengl && echo "--enable-hopengl") \ + || die "econf failed" - # ghc-6.2.x build system does not support parallel make - emake -j1 datadir="/usr/share/doc/${PF}" || die "make failed" - # the explicit datadir is required to make the haddock entries - # in the package.conf file point to the right place ... + # ghc-6.2.x build system does not support parallel make + emake -j1 datadir="/usr/share/doc/${P}" || die "make failed" + # the explicit datadir is required to make the haddock entries + # in the package.conf file point to the right place ... + fi # ! use binary } -src_install () { - local insttarget - - insttarget="install" - use doc && insttarget="${insttarget} install-docs" - - # the libdir0 setting is needed for amd64, and does not - # harm for other arches - emake -j1 ${insttarget} \ - prefix="${D}/usr" \ - datadir="${D}/usr/share/doc/${PF}" \ - infodir="${D}/usr/share/info" \ - mandir="${D}/usr/share/man" \ - libdir0="${D}/usr/$(get_libdir)" \ - || die "make ${insttarget} failed" - - #need to remove ${D} from ghcprof script - # TODO: does this actually work? - cd "${D}/usr/bin" - mv ghcprof ghcprof-orig - sed -e 's:$FPTOOLS_TOP_ABS:#$FPTOOLS_TOP_ABS:' ghcprof-orig > ghcprof - chmod a+x ghcprof - rm -f ghcprof-orig - - cd "${S}/ghc" - dodoc README ANNOUNCE LICENSE VERSION - - dosbin "${FILESDIR}/ghc-updater" +src_install() { + if use binary; then + mkdir "${D}/opt" + mv "${S}/usr" "${D}/opt/ghc" + + cp -p "${D}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf"{,.shipped} \ + || die "failed to copy package.conf" + + doenvd "${FILESDIR}/10ghc" + else + # the libdir0 setting is needed for amd64, and does not + # harm for other arches + #TODO: are any of these overrides still required? isn't econf enough? + emake -j1 install \ + prefix="${D}/usr" \ + datadir="${D}/usr/share/doc/${PF}" \ + infodir="${D}/usr/share/info" \ + mandir="${D}/usr/share/man" \ + libdir0="${D}/usr/$(get_libdir)" \ + || die "make install failed" + + cd "${S}/ghc" + dodoc README ANNOUNCE LICENSE VERSION + + dosbin "${FILESDIR}/ghc-updater" + + cp -p "${D}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf"{,.shipped} \ + || die "failed to copy package.conf" + fi + + if use doc; then + docinto "html/libraries" + dohtml -A haddock -r "${WORKDIR}/libraries/"* \ + || die "installing library docs failed" + docinto "html/users_guide" + dohtml -r "${WORKDIR}/users_guide/"* \ + || die "installing user guide failed" + docinto "" + fi } pkg_postinst () { ghc-reregister - elog "If you have dev-lang/ghc-bin installed, you might" - elog "want to unmerge it. It is no longer needed." - elog + + if use binary; then + elog "The envirenment has been set to use the binary distribution of" + elog "GHC. In order to activate it please run:" + elog " env-update && source /etc/profile" + elog "Otherwise this setting will become active the next time you login" + fi + ewarn "IMPORTANT:" ewarn "If you have upgraded from another version of ghc or" - ewarn "if you have switched from ghc-bin to ghc, please run:" - ewarn " /usr/sbin/ghc-updater" + ewarn "if you have switched between binary and source versions" + ewarn "of ghc, please run:" + if use binary; then + ewarn " /opt/ghc/sbin/ghc-updater" + else + ewarn " /usr/sbin/ghc-updater" + fi ewarn "to re-merge all ghc-based Haskell libraries." } + +pkg_prerm() { + # Overwrite the (potentially) modified package.conf with a copy of the + # original one, so that it will be removed during uninstall. + + set_config # load GHC_PREFIX + + PKG="${ROOT}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf" + + cp -p "${PKG}"{.shipped,} + + [[ -f ${PKG}.old ]] && rm "${PKG}.old" +} diff --git a/dev-lang/ghc/ghc-6.4.2.ebuild b/dev-lang/ghc/ghc-6.4.2.ebuild index 8b29141f47f9..d881731e4ea8 100644 --- a/dev-lang/ghc/ghc-6.4.2.ebuild +++ b/dev-lang/ghc/ghc-6.4.2.ebuild @@ -1,18 +1,20 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ghc-6.4.2.ebuild,v 1.22 2007/11/05 02:18:21 dcoutts Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/ghc/ghc-6.4.2.ebuild,v 1.23 2007/11/05 10:27:49 dcoutts Exp $ # Brief explanation of the bootstrap logic: # -# ghc requires ghc-bin to bootstrap. -# Therefore, -# (1) both ghc-bin and ghc provide virtual/ghc -# (2) virtual/ghc *must* default to ghc-bin -# (3) ghc depends on virtual/ghc +# Previous ghc ebuilds have been split into two: ghc and ghc-bin, +# where ghc-bin was primarily used for bootstrapping purposes. +# From now on, these two ebuilds have been combined, with the +# binary USE flag used to determine whether or not the pre-built +# binary package should be emerged or whether ghc should be compiled +# from source. If the latter, then the relevant ghc-bin for the +# arch in question will be used in the working directory to compile +# ghc from source. # -# This solution has the advantage that the binary distribution -# can be removed once an forall after the first succesful install -# of ghc. +# This solution has the advantage of allowing us to retain the one +# ebuild for both packages, and thus phase out virtual/ghc. # Note to users of hardened gcc-3.x: # @@ -26,7 +28,7 @@ # re-emerge ghc (or ghc-bin). People using vanilla gcc can switch between # gcc-3.x and 4.x with no problems. -inherit base eutils flag-o-matic toolchain-funcs autotools ghc-package check-reqs +inherit base eutils flag-o-matic toolchain-funcs autotools ghc-package DESCRIPTION="The Glasgow Haskell Compiler" HOMEPAGE="http://www.haskell.org/ghc/" @@ -38,60 +40,49 @@ MY_P="${PN}-${MY_PV}" EXTRA_SRC_URI="${MY_PV}" [[ -z "${IS_SNAPSHOT}" ]] && EXTRA_SRC_URI="stable/dist" -SRC_URI="http://www.haskell.org/ghc/dist/${EXTRA_SRC_URI}/${MY_P}-src.tar.bz2 - test? ( http://haskell.org/ghc/dist/ghc-testsuite-${MY_PV}.tar.gz ) - mirror://gentoo/${P}-alut.patch.gz" - -LICENSE="as-is" +SRC_URI="!binary? ( http://haskell.org/ghc/dist/${EXTRA_SRC_URI}/${MY_P}-src.tar.bz2 ) + doc? ( mirror://gentoo/${P}-libraries.tar.gz + mirror://gentoo/${P}-users_guide.tar.gz ) + alpha? ( mirror://gentoo/ghc-bin-${PV}-alpha.tbz2 ) + amd64? ( mirror://gentoo/ghc-bin-${PV}-amd64.tbz2 ) + hppa? ( mirror://gentoo/ghc-bin-${PV}-hppa.tbz2 ) + ia64? ( mirror://gentoo/ghc-bin-${PV}-ia64.tbz2 ) + ppc? ( mirror://gentoo/ghc-bin-${PV}-ppc.tbz2 ) + ppc64? ( mirror://gentoo/ghc-bin-${PV}-ppc64.tbz2 ) + sparc? ( mirror://gentoo/ghc-bin-${PV}-sparc.tbz2 ) + x86? ( mirror://gentoo/ghc-bin-${PV}-x86.tbz2 ) + x86-fbsd? ( mirror://gentoo/ghc-bin-${PV}-x86-fbsd.tbz2 ) + test? ( http://haskell.org/ghc/dist/ghc-testsuite-${MY_PV}.tar.gz ) + mirror://gentoo/${P}-alut.patch.gz" + +LICENSE="BSD" SLOT="0" KEYWORDS="~alpha amd64 hppa ~ia64 ppc ppc64 sparc x86 ~x86-fbsd" -IUSE="test doc X opengl openal" +IUSE="binary doc ghcbootstrap test X opengl openal" +LOC="/opt/ghc" # location for installation of binary version S="${WORKDIR}/${MY_P}" PROVIDE="virtual/ghc" RDEPEND=" + !dev-lang/ghc-bin >=sys-devel/gcc-2.95.3 >=sys-devel/binutils-2.17 >=dev-lang/perl-5.6.1 >=dev-libs/gmp-4.1 - >=sys-libs/readline-4.2 - X? ( x11-libs/libX11 ) + =sys-libs/readline-5* + X? ( || ( x11-libs/libX11 virtual/x11 ) ) opengl? ( virtual/opengl virtual/glu virtual/glut openal? ( media-libs/openal media-libs/freealut ) )" -# ghc cannot usually be bootstrapped using later versions ... -DEPEND="${RDEPEND} - <virtual/ghc-6.5 - !>=virtual/ghc-6.6 - doc? ( ~app-text/docbook-xml-dtd-4.2 - app-text/docbook-xsl-stylesheets - >=dev-libs/libxslt-1.1.2 - >=dev-haskell/haddock-0.6-r2 )" +DEPEND="${RDEPEND}" +# In the ghcbootstrap case we rely on the developer having +# >=ghc-5.04.3 on their $PATH already PDEPEND=">=dev-haskell/cabal-1.1.4" -pkg_setup() { - if use openal && ! use opengl; then - ewarn "The OpenAL bindings require the OpenGL bindings, however" - ewarn "USE=\"-opengl\" so the OpenAL bindings will not be built." - ewarn "To build the OpenAL bindings emerge with USE=\"openal opengl\"" - fi - - # Portage's resolution of virtuals fails on virtual/ghc in some Portage - # releases, the following function causes the build to fail with an - # informative error message in such a case. - #if ! has_version virtual/ghc; then - # eerror "This ebuild needs a version of GHC to bootstrap from." - # eerror "Please emerge dev-lang/ghc-bin to get a binary version." - # eerror "You can either use the binary version directly or emerge" - # eerror "dev-lang/ghc afterwards." - # die "virtual/ghc version required to build" - #fi -} - append-ghc-cflags() { local flag compile assemble link for flag in $*; do @@ -146,130 +137,220 @@ ghc_setup_cflags() { append-ghc-cflags assemble "-Wa,--noexecstack" } -ghc_setup_wrapper() { - echo '#!/bin/sh' - echo "GHCBIN=\"$(ghc-libdir)/ghc-$1\";" - echo "TOPDIROPT=\"-B$(ghc-libdir)\";" - echo "GHC_CFLAGS=\"${GHC_CFLAGS}\";" - echo '# Mini-driver for GHC' - echo 'exec $GHCBIN $TOPDIROPT $GHC_CFLAGS ${1+"$@"}' +pkg_setup() { + if use ghcbootstrap; then + ewarn "You requested ghc bootstrapping, this is usually only used" + ewarn "by Gentoo developers to make binary .tbz2 packages for" + ewarn "use with the ghc ebuild's USE=\"binary\" feature." + use binary && \ + die "USE=\"ghcbootstrap binary\" is not a valid combination." + use doc && \ + die "USE=\"ghcbootstrap doc\" is not a valid combination" + [[ -z $(type -P ghc) ]] && \ + die "Could not find a ghc to bootstrap with." + fi + + if use openal && ! use opengl; then + ewarn "The OpenAL bindings require the OpenGL bindings, however" + ewarn "USE=\"-opengl\" so the OpenAL bindings will not be built." + ewarn "To build the OpenAL bindings emerge with USE=\"openal opengl\"" + fi + + if use binary; then + if use opengl || use openal || use X || use test; then + ewarn "The binary build does not include the X, OpenGL" + ewarn "or OpenAL bindings and does not support the testsuite." + ewarn "If you want those features, emerge with USE=\"-binary\"" + fi + fi + + set_config +} + +set_config() { + # make this a separate function and call it several times as portage doesn't + # remember the variables properly between the fuctions. + use binary && GHC_PREFIX="/opt/ghc" || GHC_PREFIX="/usr" } src_unpack() { + # Create the ${S} dir if we're using the binary version + use binary && mkdir "${S}" + base_src_unpack ghc_setup_cflags - cd "${S}" - epatch "${WORKDIR}/${P}-alut.patch" - epatch "${FILESDIR}/${P}-sparc32plus.patch" - epatch "${FILESDIR}/${P}-sparcmangler.patch" + if use binary; then - # Modify the ghc driver script to use GHC_CFLAGS - echo "SCRIPT_SUBST_VARS += GHC_CFLAGS" >> "${S}/ghc/driver/ghc/Makefile" - echo "GHC_CFLAGS = ${GHC_CFLAGS}" >> "${S}/ghc/driver/ghc/Makefile" - sed -i -e 's|$TOPDIROPT|$TOPDIROPT $GHC_CFLAGS|' "${S}/ghc/driver/ghc/ghc.sh" + # Move unpacked files to the expected place + mv "${WORKDIR}/usr" "${S}" - # If we're using the testsuite then move it to into the build tree - use test && mv "${WORKDIR}/testsuite" "${S}/" + # Relocate from /usr to /opt/ghc + sed -i -e "s|/usr|${LOC}|g" \ + "${S}/usr/bin/ghc-${PV}" \ + "${S}/usr/bin/ghci-${PV}" \ + "${S}/usr/bin/ghc-pkg-${PV}" \ + "${S}/usr/bin/hsc2hs" \ + "${S}/usr/$(get_libdir)/${P}/package.conf" \ + || die "Relocating ghc from /usr to /opt/ghc failed" - # Patch to fix a mis-compilation in the rts due to strict aliasing, - # should be fixed upstream for 6.4.3 and 6.6. Fixes bug #135651. - echo 'GC_HC_OPTS += -optc-fno-strict-aliasing' >> "${S}/ghc/rts/Makefile" - # Don't strip binaries on install. See QA warnings in bug #140369. - sed -i -e 's/SRC_INSTALL_BIN_OPTS += -s//' "${S}/mk/config.mk.in" -} + # fix docs + if use doc; then + # correct the documentation and .haddock files path + sed -i -e \ + "s|/opt/ghc/share/doc/${P}/html/libraries|/usr/share/doc/${P}/html/libraries|g" \ + "${S}/usr/$(get_libdir)/${P}/package.conf" + else + # remove all doc stuff from package.conf + sed -i \ + -e 's|haddockInterfaces = \[[^]]*\]|haddockInterfaces = \[\]|g' \ + -e "s|haddockHTMLs = \[[^]]*\]|haddockHTMLs = \[\]|g" \ + "${S}/usr/$(get_libdir)/${P}/package.conf" + fi + + sed -i -e "s|/usr/$(get_libdir)|${LOC}/$(get_libdir)|" \ + "${S}/usr/bin/ghcprof" -src_compile() { - # initialize build.mk - echo '# Gentoo changes' > mk/build.mk - - # We also need to use the GHC_CFLAGS flags when building ghc itself - echo "SRC_HC_OPTS+=${GHC_CFLAGS}" >> mk/build.mk - echo "SRC_CC_OPTS+=${CFLAGS} -Wa,--noexecstack" >> mk/build.mk - - # If you need to do a quick build then enable this bit and add debug to IUSE - #if use debug; then - # echo "SRC_HC_OPTS = -H32m -O0" >> mk/build.mk - # echo "GhcStage1HcOpts =" >> mk/build.mk - # echo "GhcLibHcOpts =" >> mk/build.mk - # echo "GhcLibWays =" >> mk/build.mk - # echo "SplitObjs = NO" >> mk/build.mk - #fi - - # determine what to do with documentation - if use doc; then - echo XMLDocWays="html" >> mk/build.mk else - echo XMLDocWays="" >> mk/build.mk - # needed to prevent haddock from being called - echo NO_HADDOCK_DOCS=YES >> mk/build.mk - fi - # circumvent a very strange bug that seems related with ghc producing too much - # output while being filtered through tee (e.g. due to portage logging) - # reported as bug #111183 - echo "SRC_HC_OPTS+=-fno-warn-deprecations" >> mk/build.mk + cd "${S}" + epatch "${WORKDIR}/${P}-alut.patch" + epatch "${FILESDIR}/${P}-sparc32plus.patch" + epatch "${FILESDIR}/${P}-sparcmangler.patch" + + # Modify the ghc driver script to use GHC_CFLAGS + echo "SCRIPT_SUBST_VARS += GHC_CFLAGS" >> "${S}/ghc/driver/ghc/Makefile" + echo "GHC_CFLAGS = ${GHC_CFLAGS}" >> "${S}/ghc/driver/ghc/Makefile" + sed -i -e 's|$TOPDIROPT|$TOPDIROPT $GHC_CFLAGS|' "${S}/ghc/driver/ghc/ghc.sh" + + if ! use ghcbootstrap; then + # Relocate from /usr to ${WORKDIR}/usr + sed -i -e "s|/usr|${WORKDIR}/usr|g" \ + "${WORKDIR}/usr/bin/ghc-${PV}" \ + "${WORKDIR}/usr/bin/ghci-${PV}" \ + "${WORKDIR}/usr/bin/ghc-pkg-${PV}" \ + "${WORKDIR}/usr/bin/hsc2hs" \ + "${WORKDIR}/usr/$(get_libdir)/${P}/package.conf" \ + || die "Relocating ghc from /usr to workdir failed" + fi - # And some arches used to work ok, but bork with recent gcc versions - # See bug #145466 for ppc64. - if use ia64 || use ppc64; then - echo "GhcUnregisterised=YES" >> mk/build.mk - echo "GhcRTSWays := debug" >> mk/build.mk - fi + # If we're using the testsuite then move it to into the build tree + use test && mv "${WORKDIR}/testsuite" "${S}/" - GHC_CFLAGS="" ghc_setup_wrapper $(ghc-version) > "${T}/ghc.sh" - chmod +x "${T}/ghc.sh" + # Patch to fix a mis-compilation in the rts due to strict aliasing, + # should be fixed upstream for 6.4.3 and 6.6. Fixes bug #135651. + echo 'GC_HC_OPTS += -optc-fno-strict-aliasing' >> "${S}/ghc/rts/Makefile" - # We've patched some configure.ac files to fix the OpenAL/ALUT bindings. - # So we need to autoreconf. - eautoreconf + # Don't strip binaries on install. See QA warnings in bug #140369. + sed -i -e 's/SRC_INSTALL_BIN_OPTS += -s//' "${S}/mk/config.mk.in" + fi +} - econf \ - --with-ghc="${T}/ghc.sh" \ - $(use_enable opengl opengl) \ - $(use_enable opengl glut) \ - $(use openal && use opengl \ - && echo --enable-openal --enable-alut \ - || echo --disable-openal --disable-alut) \ - $(use_enable X x11) \ - $(use_enable X hgl) \ - || die "econf failed" +src_compile() { + if ! use binary; then + + # initialize build.mk + echo '# Gentoo changes' > mk/build.mk + + # We also need to use the GHC_CFLAGS flags when building ghc itself + echo "SRC_HC_OPTS+=${GHC_CFLAGS}" >> mk/build.mk + echo "SRC_CC_OPTS+=${CFLAGS} -Wa,--noexecstack" >> mk/build.mk + + # If you need to do a quick build then enable this bit and add debug to IUSE + #if use debug; then + # echo "SRC_HC_OPTS = -H32m -O -fasm" >> mk/build.mk + # echo "GhcLibHcOpts =" >> mk/build.mk + # echo "GhcLibWays =" >> mk/build.mk + # echo "SplitObjs = NO" >> mk/build.mk + #fi + + # We can't depend on haddock so we never build docs + # and we rely on pre-built ones instead + echo SGMLDocWays="" >> mk/build.mk + # needed to prevent haddock from being called + echo NO_HADDOCK_DOCS=YES >> mk/build.mk - emake all datadir="/usr/share/doc/${PF}" || die "make failed" - # the explicit datadir is required to make the haddock entries - # in the package.conf file point to the right place ... + # circumvent a very strange bug that seems related with ghc producing too much + # output while being filtered through tee (e.g. due to portage logging) + # reported as bug #111183 + echo "SRC_HC_OPTS+=-fno-warn-deprecations" >> mk/build.mk + + # And some arches used to work ok, but bork with recent gcc versions + # See bug #145466 for ppc64. + if use ia64 || use ppc64; then + echo "GhcUnregisterised=YES" >> mk/build.mk + echo "GhcWithNativeCodeGen=NO" >> mk/build.mk + echo "GhcWithInterpreter=NO" >> mk/build.mk + echo "SplitObjs=NO" >> mk/build.mk + echo "GhcRTSWays := debug" >> mk/build.mk + fi + # We've patched some configure.ac files to fix the OpenAL/ALUT bindings. + # So we need to autoreconf. + eautoreconf + + # Get ghc from the unpacked binary .tbz2 + # except when bootstrapping we just pick ghc up off the path + use ghcbootstrap || \ + export PATH="${WORKDIR}/usr/bin:${PATH}" + + econf \ + $(use_enable opengl opengl) \ + $(use_enable opengl glut) \ + $(use openal && use opengl \ + && echo --enable-openal --enable-alut \ + || echo --disable-openal --disable-alut) \ + $(use_enable X x11) \ + $(use_enable X hgl) \ + || die "econf failed" + + emake all datadir="/usr/share/doc/${P}" || die "make failed" + # the explicit datadir is required to make the haddock entries + # in the package.conf file point to the right place ... + + fi # ! use binary } -src_install () { - local insttarget - - insttarget="install" - use doc && insttarget="${insttarget} install-docs" - - # the libdir0 setting is needed for amd64, and does not - # harm for other arches - emake -j1 ${insttarget} \ - prefix="${D}/usr" \ - datadir="${D}/usr/share/doc/${PF}" \ - infodir="${D}/usr/share/info" \ - mandir="${D}/usr/share/man" \ - libdir0="${D}/usr/$(get_libdir)" \ - || die "make ${insttarget} failed" - - #need to remove ${D} from ghcprof script - # TODO: does this actually work? - cd "${D}/usr/bin" - mv ghcprof ghcprof-orig - sed -e 's:$FPTOOLS_TOP_ABS:#$FPTOOLS_TOP_ABS:' ghcprof-orig > ghcprof - chmod a+x ghcprof - rm -f ghcprof-orig - - cd "${S}/ghc" - dodoc README ANNOUNCE LICENSE VERSION - - dosbin "${FILESDIR}/ghc-updater" +src_install() { + if use binary; then + mkdir "${D}/opt" + mv "${S}/usr" "${D}/opt/ghc" + + cp -p "${D}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf"{,.shipped} \ + || die "failed to copy package.conf" + + doenvd "${FILESDIR}/10ghc" + else + # the libdir0 setting is needed for amd64, and does not + # harm for other arches + #TODO: are any of these overrides still required? isn't econf enough? + emake -j1 install \ + prefix="${D}/usr" \ + datadir="${D}/usr/share/doc/${PF}" \ + infodir="${D}/usr/share/info" \ + mandir="${D}/usr/share/man" \ + libdir0="${D}/usr/$(get_libdir)" \ + || die "make install failed" + + cd "${S}/ghc" + dodoc README ANNOUNCE LICENSE VERSION + + dosbin "${FILESDIR}/ghc-updater" + + cp -p "${D}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf"{,.shipped} \ + || die "failed to copy package.conf" + fi + + if use doc; then + docinto "html/libraries" + dohtml -A haddock -r "${WORKDIR}/libraries/"* \ + || die "installing library docs failed" + docinto "html/users_guide" + dohtml -r "${WORKDIR}/users_guide/"* \ + || die "installing user guide failed" + docinto "" + fi } pkg_postinst () { @@ -277,16 +358,39 @@ pkg_postinst () { $(ghc-getghcpkg) unregister Cabal > /dev/null eend $? ghc-reregister - elog "If you have dev-lang/ghc-bin installed, you might" - elog "want to unmerge it. It is no longer needed." - elog + + if use binary; then + elog "The envirenment has been set to use the binary distribution of" + elog "GHC. In order to activate it please run:" + elog " env-update && source /etc/profile" + elog "Otherwise this setting will become active the next time you login" + fi + ewarn "IMPORTANT:" ewarn "If you have upgraded from another version of ghc or" - ewarn "if you have switched from ghc-bin to ghc, please run:" - ewarn " /usr/sbin/ghc-updater" + ewarn "if you have switched between binary and source versions" + ewarn "of ghc, please run:" + if use binary; then + ewarn " /opt/ghc/sbin/ghc-updater" + else + ewarn " /usr/sbin/ghc-updater" + fi ewarn "to re-merge all ghc-based Haskell libraries." } +pkg_prerm() { + # Overwrite the (potentially) modified package.conf with a copy of the + # original one, so that it will be removed during uninstall. + + set_config # load GHC_PREFIX + + PKG="${ROOT}/${GHC_PREFIX}/$(get_libdir)/${P}/package.conf" + + cp -p "${PKG}"{.shipped,} + + [[ -f ${PKG}.old ]] && rm "${PKG}.old" +} + src_test() { if use test; then local summary |