diff options
author | 2014-08-29 14:12:31 +0000 | |
---|---|---|
committer | 2014-08-29 14:12:31 +0000 | |
commit | 8b1b38f401801e890b02ad98dac87c7dbfa0f053 (patch) | |
tree | 15570f118cae623c559a52c3c5a74d4cbe55573d /dev-lang | |
parent | Version bump. (diff) | |
download | historical-8b1b38f401801e890b02ad98dac87c7dbfa0f053.tar.gz historical-8b1b38f401801e890b02ad98dac87c7dbfa0f053.tar.bz2 historical-8b1b38f401801e890b02ad98dac87c7dbfa0f053.zip |
Add slotting to rust ebuilds
Add these slots:
(major.minor) rust release
(nightly) nightly version
(git) git master branch
Remove old unslotted versions
Package-Manager: portage-2.2.12/cvs/Linux x86_64
Manifest-Sign-Key: 0xB2EFA1D4
Diffstat (limited to 'dev-lang')
-rw-r--r-- | dev-lang/rust/ChangeLog | 16 | ||||
-rw-r--r-- | dev-lang/rust/Manifest | 45 | ||||
-rw-r--r-- | dev-lang/rust/files/50rust-mode-gentoo.el | 3 | ||||
-rw-r--r-- | dev-lang/rust/files/rust-0.11.0-libdir.patch | 270 | ||||
-rw-r--r-- | dev-lang/rust/files/rust-0.12.0-no-ldconfig.patch | 2 | ||||
-rw-r--r-- | dev-lang/rust/files/rust-9999-libdir.patch | 113 | ||||
-rw-r--r-- | dev-lang/rust/metadata.xml | 4 | ||||
-rw-r--r-- | dev-lang/rust/rust-0.10.ebuild | 93 | ||||
-rw-r--r-- | dev-lang/rust/rust-0.11.0-r1.ebuild (renamed from dev-lang/rust/rust-0.11.0.ebuild) | 51 | ||||
-rw-r--r-- | dev-lang/rust/rust-999.ebuild | 132 | ||||
-rw-r--r-- | dev-lang/rust/rust-9999-r2.ebuild (renamed from dev-lang/rust/rust-9999.ebuild) | 53 |
11 files changed, 638 insertions, 144 deletions
diff --git a/dev-lang/rust/ChangeLog b/dev-lang/rust/ChangeLog index cdbde54a4bd2..d81bad9630d6 100644 --- a/dev-lang/rust/ChangeLog +++ b/dev-lang/rust/ChangeLog @@ -1,6 +1,20 @@ # ChangeLog for dev-lang/rust # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/ChangeLog,v 1.3 2014/07/31 14:29:09 jauhien Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/ChangeLog,v 1.4 2014/08/29 14:12:27 jauhien Exp $ + +*rust-0.11.0-r1 (29 Aug 2014) +*rust-999 (29 Aug 2014) +*rust-9999-r2 (29 Aug 2014) + + 29 Aug 2014; Jauhien Piatlicki <jauhien@gentoo.org> + +files/rust-0.11.0-libdir.patch, +files/rust-9999-libdir.patch, + +rust-0.11.0-r1.ebuild, +rust-999.ebuild, +rust-9999-r2.ebuild, + -rust-0.10.ebuild, -rust-0.11.0.ebuild, -rust-9999.ebuild, + files/50rust-mode-gentoo.el, files/rust-0.12.0-no-ldconfig.patch, + metadata.xml: + Add slotting to rust ebuilds Add these slots: (major.minor) rust release + (nightly) nightly version (git) git master branch Remove old unslotted + versions *rust-9999 (31 Jul 2014) diff --git a/dev-lang/rust/Manifest b/dev-lang/rust/Manifest index ce2f84c063f8..28aca74085d2 100644 --- a/dev-lang/rust/Manifest +++ b/dev-lang/rust/Manifest @@ -1,34 +1,33 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 -AUX 50rust-mode-gentoo.el 59 SHA256 44f3cc0a09a329a75c03b225efc7504660c4f0b876bbd3c0fbe231e70da73146 SHA512 499e9229485d56ca1e3614bf38c104339ba564808c2b2a977d5401070db4761b1464abca51e7c2bc39f839266d9bb1dafe6ba234e9d941a3e7c7611eed8c987b WHIRLPOOL d1b9e5ae99da042466b24d25cf846b2378ff766b4479595e2641d52cc96aa8919857a87eaf3ee2d17bc3dc0684085c00003f96e265673163eb28d5ce7c478d01 +AUX 50rust-mode-gentoo.el 99 SHA256 8edbc05ca285e72963bfbf8c62fcf8b81af03f8127fde7e0cd0e44bbe38070bf SHA512 af3612e7a044823c14248a4d45d53a108f5b7c3c40bd7644adf67a9f0ef00d701fc5b9f17c977f0a0fab13ff76a4e221a9000e7cbb7dd6264b1387e39b9bd14e WHIRLPOOL 8ade2d3a0184dc5e9805dae0b136cdd11cad12fd08546db5438f6a575589447ab8f1cd28aee7110f6aa13dc4f0be57672edc619f2a9726b252779bd5988cb229 +AUX rust-0.11.0-libdir.patch 8231 SHA256 c86ed1af308cc0a3486afe406bdbfcb5a4e56bef3e897ec929d104682019fdfe SHA512 08f217cad02b4f7c30fd8431ffa5a1f7d5475d5d7b026e150dabbbc822fe14529dbbc87b08f4d7f05a620076e78ca5c44f7e61ddbe2adcb6fa9f99c2704c2fdc WHIRLPOOL 807305adf449591252a6f6dbc79a482c598fa38c1b678e9ba539ae46bc7b7a0262186fb4d1b5e416730118f67bc8332d45f6ffae1ef115f46c2a9c4b26d39a75 AUX rust-0.11.0-stage0.patch 843 SHA256 e6a583757f625506da2f19526211b8ec11067566e5b28ea225ac0034081d0ab5 SHA512 84a31d006b0620096d8e224e2a0f429ea3a9bd3befccfd72c82872cd1a32b1e7be0394b5cee2dd5b777e89480f9469e05343b975c7ab4015893d85e6ed8a8156 WHIRLPOOL 53b47116705e5aef97dbe457fdee970f0b5665cbeaf78c12b97ecb0d8c0c92c8596e73ea1ddcb15a3bd8abe5771a41080aa316296c37ef164c423a91fb8bb8b1 -AUX rust-0.12.0-no-ldconfig.patch 829 SHA256 a87c7453b792f7441aa8a7cc0f01b0f869556ad368aef942d76fc47391ba3519 SHA512 eeb34cd90bcdc962bd61630f964d8e1953fbaa65e165d5838b36ecd48703be1ad0d7c4bc07ccc8fd41b314ecaf27a454f2ae7a2e2bd535039e5c4adb68c0602e WHIRLPOOL 9b71079be235884a593a62e942d908fe8dcd589580406194e9145aa52cc5203ddf03c547ed664d29b73fbc935bf40f3edf942f853a3a2c9db918cf07d9662cea -DIST rust-0.10.tar.gz 19538709 SHA256 c72cfbbf03016804a81d7b68e8258ffaf018f8f5a25550ad64571ce6c2642cf9 SHA512 c5a36f947864a86241e0e443c7a19a96e7cd052c2fa7c91dacf50a6d5617ce9b6f60c74194af13a173c6360b72d4066ac8f96c0f3be7e8471f5bf77c3263d654 WHIRLPOOL 567b8e41d7e1cad1ccbcbf250a5a1abbe479aaa89bc3d110ba9c53c0c06a44d9e18b056ec2045670be1505e82f70a23cd21b9bee53857122e1e4fb61b62075fd +AUX rust-0.12.0-no-ldconfig.patch 805 SHA256 0b7d7dc918ada3ba9a3ab638abb06bbd99e7d4b80d890ed64afe4cce00f11a99 SHA512 798f4e0a87f604f3cbd0c1f8d17144a97c62b37f20b4db18049d1bf18a24997e5e9b636e164055fa07a3ee6115b0eda0aad4229f78d09052ea75e805995965da WHIRLPOOL 727dcb8a22d4c9bd08f1c6cba84c5abe25b43be624b63ba1b7acfe4aea2c3a10283c0bc7b652fdaf83f0de032ff824ed3beb8489d5a27cbe21131ba25557d064 +AUX rust-9999-libdir.patch 3802 SHA256 de21b4115126bd8f90e1afd553d1d856e4a0c56323f26dc2d1c415e73c191fde SHA512 d7bc2a63bcaae9a4f1d623fa9a716f66eeafc965c2968b2cbcf789d46254e0499e1f2a5438b103cc3a58c5ab8074172eefb383eab080dabbf5686519f7d87f64 WHIRLPOOL 859b141c0a39eca960d6a9f305c4fd04a74d7e723dae13d19aea35f0c98af208fc613e2facf3e2d07527e634565071b6e21d154e9261aaeff363c308fcdeb60a DIST rust-0.11.0-i686-unknown-linux-gnu.tar.gz 96998445 SHA256 cbfe2050f708479f2625a935d2f41165868f354ff740d2697e08acb2255670b2 SHA512 ed9213ed97351cc7ee30aa4b1177389147771ccaf8d7aa5356cecdb082966a3c5469e08f2693cb840854da523c496c90c47fa3370ceae493638efe82d5994289 WHIRLPOOL baf470655ce9229fad58db537d1fc7d34e5b858d8a06dd94690e0403d0b8d111ed41c22cf1366c7145e22c0ed55851c0bbb56db5d2408c62931c7f76f2a02352 DIST rust-0.11.0-x86_64-unknown-linux-gnu.tar.gz 97323861 SHA256 331d6374b3c8fca3e2b5fffb65ce75dfce3529bd47333de4a9ce636cb87be432 SHA512 2f98028ddaf9900150fde0bc94f2ffe28a21def3e3c84ffc3d3e5e80ee8b6d5c7010ab01dedf43b768c1c9d356041cf102b43696805f9e15bded2377206510db WHIRLPOOL dd4fcdc4f85fb4aea60cb9b547b4f242b107c3f49f478e10902bf820032b4f620af85a335059bc0fa99e2159be3e66a80a6ea76d193c7643e9cda4c168fd9f5f DIST rust-0.11.0.tar.gz 21555837 SHA256 d1b3e36448bf12b8c9289024df416de10774b6d3235d7b1d22b248ef634411ba SHA512 a29e8a1c44097cc78d36d637d1ebf9b1b914d58a56d52f8112959a68916a2df9f5f63f93e596ba6db5be21a962912503e0fd678330a9dac6abe04a59d5af4584 WHIRLPOOL b7fb24920aca2a537af0c7e20925302a20fbd662209a1774a8ecc7c2cf9aaeb9b4fabfdd45620a0fda88b49122abc04882f7254a984b06df47212e537f8713f8 -DIST rust-bin-amd64-0.10.tbz2 63434006 SHA256 08011188919ac845a285b03b724bfbebcf5e08199880553749f0a62dfe736c83 SHA512 adb1916a478a7a0d0b3cbc0f13688820fa16e7d26ae6df2e42fb82960a4d0a209bcfa0988351d1cdb5e89c146b951ce0261e3a4486c1801c078c8e713e8d04fd WHIRLPOOL 42114bb56a1c09b56c57549789873f4a553c2ec79af481ddde406aee94ba6232ac02aac335d4a76b4f4fdb0aa666bcc494f8995a9e52cea301daeca356b95e6e -DIST rust-bin-x86-0.10.tbz2 63244554 SHA256 8bd67c8d595bdcb3eef50d4c5db5eefeca85d0e657f9557e5159048247d0e480 SHA512 20a671151951a54cba7818cefcb6767ed873f2c126c232be12e1e9540d853bead8ce90a687bd0a0df9812226a421008cf2e0c181f8693f8f37fd1ee6f8e55a33 WHIRLPOOL 489b44c0d24948eab0f252a60bdb61249075058e6004ba1491ad002ad8a9f2f89e37c5e468a447b4e9a98928f515f62e5437afc070f541f7278f6f7e8678f12d -EBUILD rust-0.10.ebuild 2232 SHA256 d4e513b9839459ae0aeb174aeac4e5eb6fbab0d87ce77b4791fdb0ce7e7fdbfc SHA512 f8c1f71dd69c264ac3f31cb86b8c8a453beea297f08d004e2e560eaff520a893cdacb6fa9411d68fb82f543f67566723be1dbe07eac9beadaa6a2998094e313f WHIRLPOOL d1e3bb1b467e8032d8aa2a1c6109395331dfd6996da4b8cb4730bad1d3eb0dcd76d09795de45cdc791baefe4ea811a104e99d15ee838f82e53888dd4db39eb3a -EBUILD rust-0.11.0.ebuild 2385 SHA256 aee5c583087af127fbb6b7555fa279a1e4826d94c25e3ee3a5462f78004e247a SHA512 090a1ba7d456d9e23ed990189a719ce1cc9f53a886e2c05c17a12964a224c40b2ce0c99534b30408f62d98c1c1515dff6fefc2657680a1a53bb75940343504d2 WHIRLPOOL dd195d8dbba77c1251730472d4afb322c7321485eae0ee8cab0d22ffa0f8d441c9ac82dcb28d92f2a0800191b3ac7e6e50e5b54ea55213b1828ca33d5111519d -EBUILD rust-9999.ebuild 2317 SHA256 4b1ebcaf24e2aebfb49e04473414286face5ee2bdea868786de9d1561ddf05f7 SHA512 b2f44dd01c5c98bcff7ba119393b0a709a385f2314862acc570fb03def9d0229178732b527fcfb01ce52eee5541962dbdd39ee5da761a8439a20d463cb64d814 WHIRLPOOL 40b469e629743da11693572e297fab331a0ca297854a74df0e05469c766b384e6c4d3d523233d6b67b3b4b32f2088ad3872492e0bcf9b3e47fb51a2e3b6549bc -MISC ChangeLog 798 SHA256 7bf82c6a9b7aeec518504a2bb2f5bbf6dd980bb3f2c1251b67cc8f3bd9062171 SHA512 261fb03e26b634d0fc45332ae3f674c1f025ea3fca5d234667c905a62421ef614bbe711f48afc1efca46fc0f9f61b5eb5d483db3036033e9d14f3a7dfefdd93d WHIRLPOOL c9b247cfdb6c748ab83716040e7942a638974cd97b6dd672922256a46ed0bb9c11ba7993010a3588ce1678f96ba3fd8fbe30d510a3ca60d54649b3bc4fe5737d -MISC metadata.xml 558 SHA256 8448930fa5db8e2b4c22426e86fe18bff7b2b5dda5b5403a1cf2e67eb21d11e5 SHA512 8cab83213f7e3db20f270afa3584bb404f1ef82f282a651e8f56ec78e06840674fadb13ff44dfbc38cf63da3f27961e2f1b94df3adfaa2e6173a395362e01985 WHIRLPOOL a9bf34170565eb48d6a5f927bed168ecb54f36bf98548e7984fc03f4d53301ac0fca3d35d190eda06856f850e2bf2d1f4502dcc1a960db14dcb67b8cb931ad84 +EBUILD rust-0.11.0-r1.ebuild 3323 SHA256 df8bf49862c996a13ce88c89f7f418442141bca4387206ba2c5120c11e251e6a SHA512 b4d8904cd7c8160a4330069869297e7729adb8d173b2dc950020ac292f003245294a284a396e456a2e4d717e2a5e80aebe0e65b9b4820d94f99566f106529e30 WHIRLPOOL a5f12d60ed713b309e491ee49edbde1f81ab88da1eb615700ebeeb1d1417315c3da03ac0294975c16d8f693ec3709421587d0686048ef8ea7c5d42a19c28fd5b +EBUILD rust-999.ebuild 3364 SHA256 9fd8b4752ca02cd405752c1995fdbe114b91ed0fb526a9167359c2240eddd3e7 SHA512 7df685a877f86d9c41a089502221b7cadc77bc6f00c40c2fa0882e883b38eb86df1157636baeaa83e951de902611205252f4e3c47edc2c7738126353d40579b5 WHIRLPOOL 57030c37e1869ae59485e9b2a4c1b9153314585f3792c78e591d7e514f66285b66f5b162b8b1c6e380777f8b1e29836c3b4f43be4c66b1c2a0dd5e3ffe38b2cb +EBUILD rust-9999-r2.ebuild 3392 SHA256 5985ff8442bda3121d2027df9588d7249ecf04940ad8ddcd561cc7cda2a0d349 SHA512 e9ec19d4a61bb4afc6f594a7878120d3af0021a967a1d2f1e991aa89fc3a872336cd1047b5ed82342cd0b9644909dbed77e3eedeaf6192cc35dd4605639b3992 WHIRLPOOL 82f138fc3a045146ab48aa27e3d4cdba377b37aa35799f86dcc34646a9bbdd67d8a7671b995911f4f3952070578d0969a082a444c56d845a01b1eeca0d97c2fe +MISC ChangeLog 1374 SHA256 742ac331d713abf27108efd4c2842405a0899156630546cac480e76c4e6c7e41 SHA512 86f9c6ebb0fc8f0252dd42012de2f7a9a77274f3e8b996a8d3ec32f63824a14f4e509ce42650183a0c68d1680661e63897de3a21ed29b5848bce000d1c69e011 WHIRLPOOL 033331a3a4183839b3fd26ccc47bfde24af79034e1a1c8571519dd2ea036f66e936c1516397ee36466c59fcaa8c8db17b87926b7fa306b18e99f102f827a41ac +MISC metadata.xml 535 SHA256 17df65c4702c3ce2a237e6cc623285e67b862d7ca2d704653d5a06a2f7818cc0 SHA512 ac82235e80a43097e83a6a484def8bb6caa788956c9d2293bd2c473a71166e9de247d562a39b56f05367d3231516b4859e562b0dafddf4d99d8afa5fe4bc667f WHIRLPOOL a3721ce9389ffb2362ceb84dfb3aed1c81f26e8daa5c53fe41da6bb4ce0bc06367c24e5d7fe6999b894dd75d79a717ff0dc4bdd42562885a41076496a444f041 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 -iQIcBAEBCAAGBQJT2lK/AAoJELvuk32y76HUyvIQALpsRlAv5r9tgYaAxV6monq7 -cVjuHGSAlt+w8y8Lu16ExC3yHhfi2YPbZL7VrKwu3i4a6b5wpfE+T4SlMEWODnFa -X4HhtXOJuR6aQuV4kU9lWvMZCItJXAVI6GLO0yYqX+bRQwYS6JU5eLVPvXfuzUim -Yf42DLgz9iSG0/qANBCrmVoACzHKuro9Y2nQhyAPX0Q0GWa7Mxt3eVnEZI3jP5F/ -YI5ahlHdEPX/HghNNuqprfw/cDn4fXUexfMFiyUbiojSZnD+QwddB7hLsBOo6kFT -PwncvBhhvFNT7MLeqoYQnqT9n4gjDNYdimHo7yVaK7TWqzFaiXm+E86aqNzCCG1j -rnV5Tix3xwghcFhfDosLAdfz/ABO74PP+2cV/lub6+cVOUsMR8Ui6hDBR+USUX2b -ODG1R2Fyp63nzYYWdEJG4G4HdYWR4W/0jbsQEHGXF/7B+YARY3FIvRcT+c9+hHma -eOLptfYlLLz+r3tkwXHrJNthI8U4DSB82c8yRy4NfhcwVIw0tqixzvvCjvgdRyDF -n2yfBFHN2t8ROOksWR4MRQU6eO/rqIov4P+FiH1km6yqT5Er3dNoE+hhIaIOLQeT -UnyUnfzNoq4b3vozkceu4ohougZPr7xtiyGWmWzrT9stBUPagL1c5LSCSoLt8WRy -kmbGaKlgeV2BB9N7EEfy -=FT8S +iQIcBAEBCAAGBQJUAIpMAAoJELvuk32y76HUGeUQALtYc/hgp7sQ+7zHO3SPeD54 +nUDUpuA01vT+0wV3PxwdR4WuPNHbZ6xLWHgc2bo49dcc5OX5wh0OixlgJ6itHGJb +6YiA8QPl4VeRKmWPLtMjZpnbRHStrRDw6ry2empmwDL2nQfk0XczbVOrjxwXDGGr +e0S+1bxJKlXcR/OaWTd01cGKUKY1C3ecXzOcbxEYB7QD9nKwDAn2DrvzRfHKHIlS +f8hL/osCfXEujcpBO/3vj+J5+mhMnndlpXx7t8hgdkvH5g368cHcjiN8TTa1x7C7 +Hg24tpr7xYOaoBtFDJ09u6QThjwRqkHw6HePXXXVZQAXZL8SBRJni8D3cG/wvX2E +lv/D2CFyrbuXphjnEUqXi3oLhGKLbQfr4bsNVwl9M1hdANbMoj5g7v67yo0lNILm +b66r2zAha92MXRCDeKMXTeSMrFhP3shsZNqMs2qmKd5b96Ec/3urAbWyKjsRB2co +Oi7jVGQsQ9+UMSgcagy+zHzPAZv3OmAuJej2hGfpgD7xOCdwhdYmUe1a9yhWSwFT +38KC8ekyLqPoEmj1PdJVageec5J27bdRvo6xKBrvYTTHo83nllY3zd/f9AYOR3Ql +LxS2YZM7VDaAgld42SPiUwteabIkBJPvUeA8DLaNyWAk7Ws4cn8KsIGjeA8NAZyG +coU9T9Y+sRuO5CSYv0CM +=QTI7 -----END PGP SIGNATURE----- diff --git a/dev-lang/rust/files/50rust-mode-gentoo.el b/dev-lang/rust/files/50rust-mode-gentoo.el index 8686a13069af..92eb10d13ee2 100644 --- a/dev-lang/rust/files/50rust-mode-gentoo.el +++ b/dev-lang/rust/files/50rust-mode-gentoo.el @@ -1,2 +1,5 @@ + +;;; rust-mode site-lisp configuration + (add-to-list 'load-path "@SITELISP@") (require 'rust-mode) diff --git a/dev-lang/rust/files/rust-0.11.0-libdir.patch b/dev-lang/rust/files/rust-0.11.0-libdir.patch new file mode 100644 index 000000000000..f895e76903e9 --- /dev/null +++ b/dev-lang/rust/files/rust-0.11.0-libdir.patch @@ -0,0 +1,270 @@ +This patch adds proper support for --libdir configure option +See https://github.com/rust-lang/rust/issues/11671 and +https://github.com/rust-lang/rust/pull/16552 + +diff -r -u rust-0.11.0.orig/configure rust-0.11.0/configure +--- rust-0.11.0.orig/configure ++++ rust-0.11.0/configure +@@ -453,6 +453,14 @@ + + valopt libdir "${CFG_PREFIX}/${CFG_LIBDIR_RELATIVE}" "install libraries" + ++case "$CFG_LIBDIR" in ++ "$CFG_PREFIX"/*) CAT_INC=2;; ++ "$CFG_PREFIX"*) CAT_INC=1;; ++ *) ++ err "libdir must begin with the prefix. Use --prefix to set it accordingly.";; ++esac ++CFG_LIBDIR_RELATIVE=`echo ${CFG_LIBDIR} | cut -c$((${#CFG_PREFIX}+${CAT_INC}))-` ++ + if [ $HELP -eq 1 ] + then + echo +@@ -838,6 +846,15 @@ + do + for t in $CFG_TARGET + do ++ # host lib dir stage0 ++ make_dir $h/stage0/lib ++ ++ # target bin dir stage0 ++ make_dir $h/stage0/lib/rustlib/$t/bin ++ ++ # target lib dir stage0 ++ make_dir $h/stage0/lib/rustlib/$t/lib ++ + for i in 0 1 2 3 + do + # host bin dir +diff -r -u rust-0.11.0.orig/mk/main.mk rust-0.11.0/mk/main.mk +--- rust-0.11.0.orig/mk/main.mk ++++ rust-0.11.0/mk/main.mk +@@ -304,7 +304,11 @@ + # Destinations of artifacts for the host compiler + HROOT$(1)_H_$(3) = $(3)/stage$(1) + HBIN$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/bin ++ifeq ($(1),0) ++HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/lib ++else + HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/$$(CFG_LIBDIR_RELATIVE) ++endif + + # Destinations of artifacts for target architectures + TROOT$(1)_T_$(2)_H_$(3) = $$(HLIB$(1)_H_$(3))/rustlib/$(2) +diff -r -u rust-0.11.0.orig/src/etc/install.sh rust-0.11.0/src/etc/install.sh +--- rust-0.11.0.orig/src/etc/install.sh ++++ rust-0.11.0/src/etc/install.sh +@@ -35,6 +35,13 @@ + fi + } + ++need_cmd() { ++ if command -v $1 >/dev/null 2>&1 ++ then msg "found $1" ++ else err "need $1" ++ fi ++} ++ + putvar() { + local T + eval T=\$$1 +@@ -198,7 +205,16 @@ + ABSOLUTIFIED="${FILE_PATH}" + } + +-CFG_SRC_DIR="$(cd $(dirname $0) && pwd)/" ++msg "looking for install programs" ++need_cmd mkdir ++need_cmd printf ++need_cmd cut ++need_cmd grep ++need_cmd uname ++need_cmd tr ++need_cmd sed ++ ++CFG_SRC_DIR="$(cd $(dirname $0) && pwd)" + CFG_SELF="$0" + CFG_ARGS="$@" + +@@ -216,16 +232,85 @@ + step_msg "processing $CFG_SELF args" + fi + ++# Check for mingw or cygwin in order to special case $CFG_LIBDIR_RELATIVE. ++# This logic is duplicated from configure in order to get the correct libdir ++# for Windows installs. ++CFG_OSTYPE=$(uname -s) ++ ++case $CFG_OSTYPE in ++ ++ MINGW32*) ++ CFG_OSTYPE=pc-mingw32 ++ ;; ++ ++ MINGW64*) ++ # msys2, MSYSTEM=MINGW64 ++ CFG_OSTYPE=w64-mingw32 ++ ;; ++ ++# Thad's Cygwin identifers below ++ ++# Vista 32 bit ++ CYGWIN_NT-6.0) ++ CFG_OSTYPE=pc-mingw32 ++ ;; ++ ++# Vista 64 bit ++ CYGWIN_NT-6.0-WOW64) ++ CFG_OSTYPE=w64-mingw32 ++ ;; ++ ++# Win 7 32 bit ++ CYGWIN_NT-6.1) ++ CFG_OSTYPE=pc-mingw32 ++ ;; ++ ++# Win 7 64 bit ++ CYGWIN_NT-6.1-WOW64) ++ CFG_OSTYPE=w64-mingw32 ++ ;; ++esac ++ + OPTIONS="" + BOOL_OPTIONS="" + VAL_OPTIONS="" + ++# On windows we just store the libraries in the bin directory because ++# there's no rpath. This is where the build system itself puts libraries; ++# --libdir is used to configure the installation directory. ++# FIXME: Thise needs to parameterized over target triples. Do it in platform.mk ++CFG_LIBDIR_RELATIVE=lib ++if [ "$CFG_OSTYPE" = "pc-mingw32" ] || [ "$CFG_OSTYPE" = "w64-mingw32" ] ++then ++ CFG_LIBDIR_RELATIVE=bin ++fi ++ ++if [ "$CFG_OSTYPE" = "pc-mingw32" ] || [ "$CFG_OSTYPE" = "w64-mingw32" ] ++then ++ CFG_LD_PATH_VAR=PATH ++ CFG_OLD_LD_PATH_VAR=$PATH ++elif [ "$CFG_OSTYPE" = "Darwin" ] ++then ++ CFG_LD_PATH_VAR=DYLD_LIBRARY_PATH ++ CFG_OLD_LD_PATH_VAR=$DYLD_LIBRARY_PATH ++else ++ CFG_LD_PATH_VAR=LD_LIBRARY_PATH ++ CFG_OLD_LD_PATH_VAR=$LD_LIBRARY_PATH ++fi ++ + flag uninstall "only uninstall from the installation prefix" + opt verify 1 "verify that the installed binaries run correctly" + valopt prefix "/usr/local" "set installation prefix" +-# NB This isn't quite the same definition as in `configure`. +-# just using 'lib' instead of CFG_LIBDIR_RELATIVE +-valopt libdir "${CFG_PREFIX}/lib" "install libraries" ++# NB This is exactly the same definition as in `configure`. ++valopt libdir "${CFG_PREFIX}/${CFG_LIBDIR_RELATIVE}" "install libraries" ++case "$CFG_LIBDIR" in ++ "$CFG_PREFIX"/*) CAT_INC=2;; ++ "$CFG_PREFIX"*) CAT_INC=1;; ++ *) ++ err "libdir must begin with the prefix. Use --prefix to set it accordingly.";; ++esac ++CFG_LIBDIR_RELATIVE=`echo ${CFG_LIBDIR} | cut -c$((${#CFG_PREFIX}+${CAT_INC}))-` ++ + valopt mandir "${CFG_PREFIX}/share/man" "install man pages in PATH" + + if [ $HELP -eq 1 ] +@@ -247,11 +332,13 @@ + if [ -z "${CFG_UNINSTALL}" ] + then + msg "verifying platform can run binaries" ++ export $CFG_LD_PATH_VAR="${CFG_SRC_DIR}/lib":$CFG_OLD_LD_PATH_VAR + "${CFG_SRC_DIR}/bin/rustc" --version > /dev/null + if [ $? -ne 0 ] + then + err "can't execute rustc binary on this platform" + fi ++ export $CFG_LD_PATH_VAR=$CFG_OLD_LD_PATH_VAR + fi + fi + +@@ -348,9 +435,9 @@ + # Decide the destination of the file + FILE_INSTALL_PATH="${CFG_PREFIX}/$p" + +- if echo "$p" | grep "^lib/" > /dev/null ++ if echo "$p" | grep "^${CFG_LIBDIR_RELATIVE}/" > /dev/null + then +- pp=`echo $p | sed 's/^lib\///'` ++ pp=`echo $p | sed "s%^${CFG_LIBDIR_RELATIVE}/%%"` + FILE_INSTALL_PATH="${CFG_LIBDIR}/$pp" + fi + +@@ -384,24 +471,36 @@ + need_ok "failed to update manifest" + + # The manifest lists all files to install +-done < "${CFG_SRC_DIR}/lib/rustlib/manifest.in" ++done < "${CFG_SRC_DIR}/${CFG_LIBDIR_RELATIVE}/rustlib/manifest.in" + + # Sanity check: can we run the installed binaries? ++# ++# As with the verification above, make sure the right LD_LIBRARY_PATH-equivalent ++# is in place. Try first without this variable, and if that fails try again with ++# the variable. If the second time tries, print a hopefully helpful message to ++# add something to the appropriate environment variable. + if [ -z "${CFG_DISABLE_VERIFY}" ] + then + msg "verifying installed binaries are executable" +- "${CFG_PREFIX}/bin/rustc" --version > /dev/null ++ "${CFG_PREFIX}/bin/rustc" --version 2> /dev/null 1> /dev/null + if [ $? -ne 0 ] + then +- ERR="can't execute installed rustc binary. " +- ERR="${ERR}installation may be broken. " +- ERR="${ERR}if this is expected then rerun install.sh with \`--disable-verify\` " +- ERR="${ERR}or \`make install\` with \`--disable-verify-install\`" +- err "${ERR}" ++ export $CFG_LD_PATH_VAR="${CFG_PREFIX}/lib":$CFG_OLD_LD_PATH_VAR ++ "${CFG_PREFIX}/bin/rustc" --version > /dev/null ++ if [ $? -ne 0 ] ++ then ++ ERR="can't execute installed rustc binary. " ++ ERR="${ERR}installation may be broken. " ++ ERR="${ERR}if this is expected then rerun install.sh with \`--disable-verify\` " ++ ERR="${ERR}or \`make install\` with \`--disable-verify-install\`" ++ err "${ERR}" ++ else ++ echo ++ echo " Note: please ensure '${CFG_PREFIX}/lib' is added to ${CFG_LD_PATH_VAR}" ++ fi + fi + fi + +- + echo + echo " Rust is ready to roll." + echo +diff -r -u rust-0.11.0.orig/src/librustc/metadata/filesearch.rs rust-0.11.0/src/librustc/metadata/filesearch.rs +--- rust-0.11.0.orig/src/librustc/metadata/filesearch.rs ++++ rust-0.11.0/src/librustc/metadata/filesearch.rs +@@ -243,10 +243,14 @@ + // of the directory where librustc is located, rather than where the rustc + // binary is. + +- if sysroot.join(primary_libdir_name()).join(rustlibdir()).exists() { +- return primary_libdir_name(); +- } else { +- return secondary_libdir_name(); ++ match option_env!("CFG_LIBDIR_RELATIVE") { ++ None => if sysroot.join(primary_libdir_name()).join(rustlibdir()).exists() { ++ return primary_libdir_name(); ++ } else { ++ return secondary_libdir_name(); ++ }, ++ ++ Some(libdir) => return libdir.to_string() + } + + #[cfg(target_word_size = "64")] diff --git a/dev-lang/rust/files/rust-0.12.0-no-ldconfig.patch b/dev-lang/rust/files/rust-0.12.0-no-ldconfig.patch index b3b78f990e1f..0ab3a5a836bb 100644 --- a/dev-lang/rust/files/rust-0.12.0-no-ldconfig.patch +++ b/dev-lang/rust/files/rust-0.12.0-no-ldconfig.patch @@ -1,8 +1,6 @@ Remove ldconfig(1) execution to prevent the installation script from accessing outside of a sandbox. -Author: Heather Cynede - diff --git a/src/etc/install.sh b/src/etc/install.sh index c949743..7c3daa5 100644 --- a/src/etc/install.sh diff --git a/dev-lang/rust/files/rust-9999-libdir.patch b/dev-lang/rust/files/rust-9999-libdir.patch new file mode 100644 index 000000000000..33098b87c921 --- /dev/null +++ b/dev-lang/rust/files/rust-9999-libdir.patch @@ -0,0 +1,113 @@ +This patch adds proper support for --libdir configure option +See https://github.com/rust-lang/rust/issues/11671 and +https://github.com/rust-lang/rust/pull/16552 + +diff --git a/configure b/configure +index 636d502..fff67b6 100755 +--- a/configure ++++ b/configure +@@ -459,6 +459,14 @@ fi + + valopt libdir "${CFG_PREFIX}/${CFG_LIBDIR_RELATIVE}" "install libraries" + ++case "$CFG_LIBDIR" in ++ "$CFG_PREFIX"/*) CAT_INC=2;; ++ "$CFG_PREFIX"*) CAT_INC=1;; ++ *) ++ err "libdir must begin with the prefix. Use --prefix to set it accordingly.";; ++esac ++CFG_LIBDIR_RELATIVE=`echo ${CFG_LIBDIR} | cut -c$((${#CFG_PREFIX}+${CAT_INC}))-` ++ + if [ $HELP -eq 1 ] + then + echo +@@ -855,6 +863,15 @@ for h in $CFG_HOST + do + for t in $CFG_TARGET + do ++ # host lib dir stage0 ++ make_dir $h/stage0/lib ++ ++ # target bin dir stage0 ++ make_dir $h/stage0/lib/rustlib/$t/bin ++ ++ # target lib dir stage0 ++ make_dir $h/stage0/lib/rustlib/$t/lib ++ + for i in 0 1 2 3 + do + # host bin dir +diff --git a/mk/main.mk b/mk/main.mk +index 2bdfc1b..bca5b3b 100644 +--- a/mk/main.mk ++++ b/mk/main.mk +@@ -311,7 +311,11 @@ define SREQ + # Destinations of artifacts for the host compiler + HROOT$(1)_H_$(3) = $(3)/stage$(1) + HBIN$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/bin ++ifeq ($(1),0) ++HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/lib ++else + HLIB$(1)_H_$(3) = $$(HROOT$(1)_H_$(3))/$$(CFG_LIBDIR_RELATIVE) ++endif + + # Destinations of artifacts for target architectures + TROOT$(1)_T_$(2)_H_$(3) = $$(HLIB$(1)_H_$(3))/rustlib/$(2) +diff --git a/src/etc/install.sh b/src/etc/install.sh +index c949743..1a472c6 100644 +--- a/src/etc/install.sh ++++ b/src/etc/install.sh +@@ -301,9 +301,16 @@ fi + flag uninstall "only uninstall from the installation prefix" + opt verify 1 "verify that the installed binaries run correctly" + valopt prefix "/usr/local" "set installation prefix" +-# NB This isn't quite the same definition as in `configure`. +-# just using 'lib' instead of CFG_LIBDIR_RELATIVE ++# NB This is exactly the same definition as in `configure`. + valopt libdir "${CFG_PREFIX}/${CFG_LIBDIR_RELATIVE}" "install libraries" ++case "$CFG_LIBDIR" in ++ "$CFG_PREFIX"/*) CAT_INC=2;; ++ "$CFG_PREFIX"*) CAT_INC=1;; ++ *) ++ err "libdir must begin with the prefix. Use --prefix to set it accordingly.";; ++esac ++CFG_LIBDIR_RELATIVE=`echo ${CFG_LIBDIR} | cut -c$((${#CFG_PREFIX}+${CAT_INC}))-` ++ + valopt mandir "${CFG_PREFIX}/share/man" "install man pages in PATH" + + if [ $HELP -eq 1 ] +@@ -428,9 +435,9 @@ while read p; do + # Decide the destination of the file + FILE_INSTALL_PATH="${CFG_PREFIX}/$p" + +- if echo "$p" | grep "^lib/" > /dev/null ++ if echo "$p" | grep "^${CFG_LIBDIR_RELATIVE}/" > /dev/null + then +- pp=`echo $p | sed 's/^lib\///'` ++ pp=`echo $p | sed "s%^${CFG_LIBDIR_RELATIVE}/%%"` + FILE_INSTALL_PATH="${CFG_LIBDIR}/$pp" + fi + +diff --git a/src/librustc/metadata/filesearch.rs b/src/librustc/metadata/filesearch.rs +index 99b98b6..f3e37ff 100644 +--- a/src/librustc/metadata/filesearch.rs ++++ b/src/librustc/metadata/filesearch.rs +@@ -243,10 +243,14 @@ fn find_libdir(sysroot: &Path) -> String { + // of the directory where librustc is located, rather than where the rustc + // binary is. + +- if sysroot.join(primary_libdir_name()).join(rustlibdir()).exists() { +- return primary_libdir_name(); +- } else { +- return secondary_libdir_name(); ++ match option_env!("CFG_LIBDIR_RELATIVE") { ++ None => if sysroot.join(primary_libdir_name()).join(rustlibdir()).exists() { ++ return primary_libdir_name(); ++ } else { ++ return secondary_libdir_name(); ++ }, ++ ++ Some(libdir) => return libdir.to_string() + } + + #[cfg(target_word_size = "64")] diff --git a/dev-lang/rust/metadata.xml b/dev-lang/rust/metadata.xml index b2372428725b..d84b0f6f3efc 100644 --- a/dev-lang/rust/metadata.xml +++ b/dev-lang/rust/metadata.xml @@ -5,8 +5,10 @@ <email>jauhien@gentoo.org</email> <name>Jauhien Piatlicki</name> </maintainer> + <maintainer> + <email>Heather@Cynede.net</email> + </maintainer> <use> - <flag name="binary-bootstrap">Download precompiled rust for compilator bootstrap</flag> <flag name="clang">Use <pkg>sys-devel/clang</pkg> for building</flag> <flag name="libcxx">Use <pkg>sys-libs/libcxx</pkg> as standard library when building with <pkg>sys-devel/clang</pkg></flag> diff --git a/dev-lang/rust/rust-0.10.ebuild b/dev-lang/rust/rust-0.10.ebuild deleted file mode 100644 index b87c586eb506..000000000000 --- a/dev-lang/rust/rust-0.10.ebuild +++ /dev/null @@ -1,93 +0,0 @@ -# Copyright 1999-2014 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-0.10.ebuild,v 1.1 2014/05/18 23:46:09 jauhien Exp $ - -EAPI="5" - -PYTHON_COMPAT=( python{2_6,2_7} ) - -inherit elisp-common python-any-r1 - -DESCRIPTION="Systems programming language from Mozilla" -HOMEPAGE="http://www.rust-lang.org/" - -ARCH_SRC_URI="amd64? ( mirror://gentoo/${PN}-bin-amd64-${PV}.tbz2 ) - x86? ( mirror://gentoo/${PN}-bin-x86-${PV}.tbz2 )" -SRC_URI="http://static.rust-lang.org/dist/${P}.tar.gz - binary-bootstrap? ( ${ARCH_SRC_URI} )" - -LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -IUSE="+binary-bootstrap clang debug emacs vim-syntax zsh-completion" - -RDEPEND="emacs? ( virtual/emacs ) - vim-syntax? ( || ( app-editors/vim app-editors/gvim ) ) - zsh-completion? ( app-shells/zsh )" -DEPEND="${RDEPEND} - ${PYTHON_DEPS} - >=dev-lang/perl-5.0 - clang? ( sys-devel/clang )" - -SITEFILE="50${PN}-mode-gentoo.el" - -src_configure() { - local LOCAL_RUST_PATH=/usr - if use binary-bootstrap; then - LOCAL_RUST_PATH="${WORKDIR}${LOCAL_RUST_PATH}" - else - LOCAL_RUST_PATH="${EPREFIX}${LOCAL_RUST_PATH}" - fi - - "${ECONF_SOURCE:-.}"/configure \ - --prefix="${EPREFIX}/usr/" \ - $(use_enable clang) \ - $(use_enable debug) \ - $(use_enable debug llvm-assertions) \ - $(use_enable !debug optimize) \ - $(use_enable !debug optimize-cxx) \ - $(use_enable !debug optimize-llvm) \ - $(use_enable !debug optimize-tests) \ - --enable-local-rust \ - --local-rust-root="${LOCAL_RUST_PATH}" \ - --disable-manage-submodules \ - || die -} - -src_compile() { - default - - if use emacs; then - cd src/etc/emacs || die - elisp-compile *.el - elisp-make-autoload-file "${PN}-mode-autoloads.el" . - fi -} - -src_install() { - default - - if use emacs; then - elisp-install ${PN}-mode src/etc/emacs/*.el src/etc/emacs/*.elc - elisp-site-file-install "${FILESDIR}/${SITEFILE}" - fi - - if use vim-syntax; then - insinto /usr/share/vim/vimfiles - doins -r src/etc/vim/* - fi - - if use zsh-completion; then - insinto "/usr/share/zsh/site-functions" - doins src/etc/zsh/_rust - fi -} - -pkg_postinst() { - use emacs && elisp-site-regen -} - -pkg_postrm() { - use emacs && elisp-site-regen -} diff --git a/dev-lang/rust/rust-0.11.0.ebuild b/dev-lang/rust/rust-0.11.0-r1.ebuild index 2880ec4e734b..e3be7ee19530 100644 --- a/dev-lang/rust/rust-0.11.0.ebuild +++ b/dev-lang/rust/rust-0.11.0-r1.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-0.11.0.ebuild,v 1.1 2014/07/31 09:52:41 jauhien Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-0.11.0-r1.ebuild,v 1.1 2014/08/29 14:12:27 jauhien Exp $ EAPI="5" @@ -17,7 +17,7 @@ ARCH_SRC_URI="amd64? ( http://static.rust-lang.org/dist/${P}-x86_64-unknown-linu SRC_URI="http://static.rust-lang.org/dist/${P}.tar.gz ${ARCH_SRC_URI}" LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" -SLOT="0" +SLOT="0.11" KEYWORDS="~amd64 ~x86" IUSE="clang debug emacs libcxx vim-syntax zsh-completion" @@ -27,15 +27,17 @@ RDEPEND="vim-syntax? ( || ( app-editors/vim app-editors/gvim ) ) zsh-completion? ( app-shells/zsh )" DEPEND="${RDEPEND} ${PYTHON_DEPS} + app-admin/eselect-rust >=dev-lang/perl-5.0 clang? ( sys-devel/clang ) emacs? ( virtual/emacs ) - libcxx? ( sys-libs/libcxx )" + libcxx? ( sys-libs/libcxx ) + !dev-lang/rust:0" SITEFILE="50${PN}-mode-gentoo.el" src_prepare() { - epatch "${FILESDIR}/${P}-stage0.patch" + epatch "${FILESDIR}/${P}-stage0.patch" "${FILESDIR}/${P}-libdir.patch" } src_configure() { @@ -44,7 +46,9 @@ src_configure() { LOCAL_RUST_PATH="${WORKDIR}/${P}-${ARCH_POSTFIX}-unknown-linux-gnu" "${ECONF_SOURCE:-.}"/configure \ - --prefix="${EPREFIX}/usr/" \ + --prefix="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/lib/${P}" \ + --mandir="${EPREFIX}/usr/share/${P}/man" \ $(use_enable clang) \ $(use_enable debug) \ $(use_enable debug llvm-assertions) \ @@ -56,11 +60,12 @@ src_configure() { --enable-local-rust \ --local-rust-root="${LOCAL_RUST_PATH}" \ --disable-manage-submodules \ + --disable-verify-install \ || die } src_compile() { - default + emake VERBOSE=1 if use emacs; then cd src/etc/emacs || die @@ -73,25 +78,47 @@ src_install() { default if use emacs; then - elisp-install ${PN}-mode src/etc/emacs/*.el src/etc/emacs/*.elc - elisp-site-file-install "${FILESDIR}/${SITEFILE}" + local sf="${T}/${SITEFILE}" + local my_elisp_pn=${PN}-mode + + insinto "/usr/share/${P}/emacs/site-lisp/${my_elisp_pn}" + doins -r src/etc/emacs/*.el src/etc/emacs/*.elc + + cp "${FILESDIR}/${SITEFILE}" "${sf}" || die + sed -i -e "s:@SITELISP@:${EPREFIX}${SITELISP}/${my_elisp_pn}:g" "${sf}" || die + insinto "/usr/share/${P}/emacs/site-lisp/site-gentoo.d/" + doins "${sf}" fi if use vim-syntax; then - insinto /usr/share/vim/vimfiles + insinto /usr/share/${P}/vim/vimfiles doins -r src/etc/vim/* fi if use zsh-completion; then - insinto "/usr/share/zsh/site-functions" + insinto "/usr/share/${P}/zsh/site-functions" doins src/etc/zsh/_rust fi + + mv "${D}/usr/bin/rustc" "${D}/usr/bin/rustc-${PV}" || die + mv "${D}/usr/bin/rustdoc" "${D}/usr/bin/rustdoc-${PV}" || die + + cat <<-EOF > "${T}"/50${P} + LDPATH="/usr/lib/${P}" + MANPATH="/usr/share/${P}/man" + EOF + doenvd "${T}"/50${P} } pkg_postinst() { - use emacs && elisp-site-regen + eselect rust update --if-unset + + elog "Rust uses slots now, use 'eselect rust list'" + elog "and 'eselect rust set' to list and set rust version." + elog "For more information see 'eselect rust help'" + elog "and http://wiki.gentoo.org/wiki/Project:Eselect/User_guide" } pkg_postrm() { - use emacs && elisp-site-regen + eselect rust unset --if-invalid } diff --git a/dev-lang/rust/rust-999.ebuild b/dev-lang/rust/rust-999.ebuild new file mode 100644 index 000000000000..5669a63d5c48 --- /dev/null +++ b/dev-lang/rust/rust-999.ebuild @@ -0,0 +1,132 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-999.ebuild,v 1.1 2014/08/29 14:12:27 jauhien Exp $ + +EAPI="5" + +PYTHON_COMPAT=( python{2_6,2_7} ) + +inherit elisp-common eutils python-any-r1 + +MY_P=${PN}-nightly + +DESCRIPTION="Systems programming language from Mozilla" +HOMEPAGE="http://www.rust-lang.org/" +MY_SRC_URI="http://static.rust-lang.org/dist/${MY_P}.tar.gz" + +LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" +SLOT="nightly" +KEYWORDS="" + +IUSE="clang debug emacs libcxx vim-syntax zsh-completion" +REQUIRED_USE="libcxx? ( clang )" + +RDEPEND="vim-syntax? ( || ( app-editors/vim app-editors/gvim ) ) + zsh-completion? ( app-shells/zsh )" +DEPEND="${RDEPEND} + ${PYTHON_DEPS} + app-admin/eselect-rust + >=dev-lang/perl-5.0 + net-misc/wget + clang? ( sys-devel/clang ) + emacs? ( virtual/emacs ) + libcxx? ( sys-libs/libcxx ) + !dev-lang/rust:0" + +S="${WORKDIR}/${MY_P}" + +SITEFILE="50${PN}-mode-gentoo.el" + +src_unpack() { + wget "${MY_SRC_URI}" || die + unpack ./"${PN}-nightly.tar.gz" + + use amd64 && BUILD_TRIPLE=x86_64-unknown-linux-gnu + use x86 && BUILD_TRIPLE=i686-unknown-linux-gnu + export CFG_SRC_DIR="${S}" && \ + cd ${S} && \ + mkdir -p "${S}/dl" && \ + mkdir -p "${S}/${BUILD_TRIPLE}/stage0/bin" && \ + python2 "${S}/src/etc/get-snapshot.py" ${BUILD_TRIPLE} || die +} + +src_prepare() { + epatch "${FILESDIR}/${PN}-0.12.0-no-ldconfig.patch" "${FILESDIR}/${PN}-9999-libdir.patch" +} + +src_configure() { + "${ECONF_SOURCE:-.}"/configure \ + --prefix="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/lib/${P}" \ + --mandir="${EPREFIX}/usr/share/${P}/man" \ + $(use_enable clang) \ + $(use_enable debug) \ + $(use_enable debug llvm-assertions) \ + $(use_enable !debug optimize) \ + $(use_enable !debug optimize-cxx) \ + $(use_enable !debug optimize-llvm) \ + $(use_enable !debug optimize-tests) \ + $(use_enable libcxx libcpp) \ + --disable-manage-submodules \ + --disable-verify-install \ + || die +} + +src_compile() { + emake VERBOSE=1 + + if use emacs; then + cd src/etc/emacs || die + elisp-compile *.el + elisp-make-autoload-file "${PN}-mode-autoloads.el" . + fi +} + +src_install() { + default + + if use emacs; then + local sf="${T}/${SITEFILE}" + local my_elisp_pn=${PN}-mode + + insinto "/usr/share/${P}/emacs/site-lisp/${my_elisp_pn}" + doins -r src/etc/emacs/*.el src/etc/emacs/*.elc + + cp "${FILESDIR}/${SITEFILE}" "${sf}" || die + sed -i -e "s:@SITELISP@:${EPREFIX}${SITELISP}/${my_elisp_pn}:g" "${sf}" || die + insinto "/usr/share/${P}/emacs/site-lisp/site-gentoo.d/" + doins "${sf}" + fi + + if use vim-syntax; then + insinto /usr/share/${P}/vim/vimfiles + doins -r src/etc/vim/* + fi + + if use zsh-completion; then + insinto "/usr/share/${P}/zsh/site-functions" + doins src/etc/zsh/_rust + fi + + mv "${D}/usr/bin/rustc" "${D}/usr/bin/rustc-${PV}" || die + mv "${D}/usr/bin/rustdoc" "${D}/usr/bin/rustdoc-${PV}" || die + + cat <<-EOF > "${T}"/50${P} + LDPATH="/usr/lib/${P}" + MANPATH="/usr/share/${P}/man" + EOF + doenvd "${T}"/50${P} +} + +pkg_postinst() { + eselect rust update --if-unset + + elog "Rust uses slots now, use 'eselect rust list'" + elog "and 'eselect rust set' to list and set rust version." + elog "For more information see 'eselect rust help'" + elog "and http://wiki.gentoo.org/wiki/Project:Eselect/User_guide" +} + +pkg_postrm() { + eselect rust unset --if-invalid +} diff --git a/dev-lang/rust/rust-9999.ebuild b/dev-lang/rust/rust-9999-r2.ebuild index 63ae345aac8c..d3b3c85ace3d 100644 --- a/dev-lang/rust/rust-9999.ebuild +++ b/dev-lang/rust/rust-9999-r2.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-9999.ebuild,v 1.1 2014/07/31 14:29:09 jauhien Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-lang/rust/rust-9999-r2.ebuild,v 1.1 2014/08/29 14:12:27 jauhien Exp $ EAPI="5" @@ -13,7 +13,7 @@ HOMEPAGE="http://www.rust-lang.org/" EGIT_REPO_URI="git://github.com/rust-lang/rust.git" LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" -SLOT="0" +SLOT="git" KEYWORDS="" IUSE="clang debug emacs libcxx vim-syntax zsh-completion" @@ -23,10 +23,12 @@ RDEPEND="vim-syntax? ( || ( app-editors/vim app-editors/gvim ) ) zsh-completion? ( app-shells/zsh )" DEPEND="${RDEPEND} ${PYTHON_DEPS} + app-admin/eselect-rust >=dev-lang/perl-5.0 clang? ( sys-devel/clang ) emacs? ( virtual/emacs ) - libcxx? ( sys-libs/libcxx )" + libcxx? ( sys-libs/libcxx ) + !dev-lang/rust:0" SITEFILE="50${PN}-mode-gentoo.el" @@ -43,12 +45,16 @@ src_unpack() { } src_prepare() { - epatch "${FILESDIR}/${PN}-0.12.0-no-ldconfig.patch" + epatch "${FILESDIR}/${PN}-0.12.0-no-ldconfig.patch" "${FILESDIR}/${P}-libdir.patch" + local commit_hash=`git rev-parse --short HEAD` + sed -i -e "s/CFG_FILENAME_EXTRA=.*/CFG_FILENAME_EXTRA=${commit_hash}/" mk/main.mk || die } src_configure() { "${ECONF_SOURCE:-.}"/configure \ - --prefix="${EPREFIX}/usr/" \ + --prefix="${EPREFIX}/usr" \ + --libdir="${EPREFIX}/usr/lib/${P}" \ + --mandir="${EPREFIX}/usr/share/${P}/man" \ $(use_enable clang) \ $(use_enable debug) \ $(use_enable debug llvm-assertions) \ @@ -58,11 +64,12 @@ src_configure() { $(use_enable !debug optimize-tests) \ $(use_enable libcxx libcpp) \ --disable-manage-submodules \ + --disable-verify-install \ || die } src_compile() { - default + emake VERBOSE=1 if use emacs; then cd src/etc/emacs || die @@ -75,25 +82,47 @@ src_install() { default if use emacs; then - elisp-install ${PN}-mode src/etc/emacs/*.el src/etc/emacs/*.elc - elisp-site-file-install "${FILESDIR}/${SITEFILE}" + local sf="${T}/${SITEFILE}" + local my_elisp_pn=${PN}-mode + + insinto "/usr/share/${P}/emacs/site-lisp/${my_elisp_pn}" + doins -r src/etc/emacs/*.el src/etc/emacs/*.elc + + cp "${FILESDIR}/${SITEFILE}" "${sf}" || die + sed -i -e "s:@SITELISP@:${EPREFIX}${SITELISP}/${my_elisp_pn}:g" "${sf}" || die + insinto "/usr/share/${P}/emacs/site-lisp/site-gentoo.d/" + doins "${sf}" fi if use vim-syntax; then - insinto /usr/share/vim/vimfiles + insinto /usr/share/${P}/vim/vimfiles doins -r src/etc/vim/* fi if use zsh-completion; then - insinto "/usr/share/zsh/site-functions" + insinto "/usr/share/${P}/zsh/site-functions" doins src/etc/zsh/_rust fi + + mv "${D}/usr/bin/rustc" "${D}/usr/bin/rustc-${PV}" || die + mv "${D}/usr/bin/rustdoc" "${D}/usr/bin/rustdoc-${PV}" || die + + cat <<-EOF > "${T}"/50${P} + LDPATH="/usr/lib/${P}" + MANPATH="/usr/share/${P}/man" + EOF + doenvd "${T}"/50${P} } pkg_postinst() { - use emacs && elisp-site-regen + eselect rust update --if-unset + + elog "Rust uses slots now, use 'eselect rust list'" + elog "and 'eselect rust set' to list and set rust version." + elog "For more information see 'eselect rust help'" + elog "and http://wiki.gentoo.org/wiki/Project:Eselect/User_guide" } pkg_postrm() { - use emacs && elisp-site-regen + eselect rust unset --if-invalid } |