diff options
-rw-r--r-- | app-admin/vault/Manifest | 4 | ||||
-rw-r--r-- | app-admin/vault/vault-1.10.5.ebuild | 85 | ||||
-rw-r--r-- | app-admin/vault/vault-1.11.1.ebuild | 86 | ||||
-rw-r--r-- | app-portage/hackport/Manifest | 3 | ||||
-rw-r--r-- | app-portage/hackport/hackport-0.6.6.ebuild | 54 | ||||
-rw-r--r-- | app-portage/hackport/hackport-0.7.2.1.ebuild (renamed from app-portage/hackport/hackport-0.7.ebuild) | 48 | ||||
-rw-r--r-- | app-portage/hackport/hackport-9999.ebuild | 76 | ||||
-rw-r--r-- | eclass/haskell-cabal.eclass | 168 | ||||
-rw-r--r-- | profiles/package.mask | 288 |
9 files changed, 668 insertions, 144 deletions
diff --git a/app-admin/vault/Manifest b/app-admin/vault/Manifest index 0ba6bcfe0fab..9f1d679a378a 100644 --- a/app-admin/vault/Manifest +++ b/app-admin/vault/Manifest @@ -2,5 +2,9 @@ DIST vault-1.10.3-vendor.tar.gz 48109465 BLAKE2B 45985a6ae4445ec75b29f198113fdd1 DIST vault-1.10.3-webui.tar.xz 1258176 BLAKE2B 85fd1b804b880a3dcdbbd4e825b663f02a985259d0a74ab7cddf4a9a2393c60918b389d0e4e81574b93c8b0867647fc1d17f7ca3e719b36ab41d6825adfbdaae SHA512 9640a7e25de0761a310e234098a0dd31db9e04b30036045ff7edaaca8f7496466f1c0148855a5e1ef270638e90a8fb97aff2c5482b32512772021c99691a5aa5 DIST vault-1.10.4-vendor.tar.gz 50089463 BLAKE2B 299e7619f158a2ea0683feaaff4a7c5019da02fa03daf25e0b4415f03b703ca11733c486165a21ffcd5b3c1d221db5b9e24e898f3cf3de014c09e29531841dcf SHA512 056a6056bac127083358f1811e8e587f0521b734219a6e03e019527fafcadfbd0d71a05314cb269e27b03423349b5a857d234d3949d0d15e7c7b1175bc573c57 DIST vault-1.10.4-webui.tar.xz 1258340 BLAKE2B 556da0e566852e5c6a091bd9139a88a9099e5f6422e225b7a4068e1bef3d9fd5a2292bb2efbe12545c20f6c956fd6180500972d5248f05bbb96db50a90ae4741 SHA512 ec9cc568d8d56ba379d0fdee31e0edc8aa8110366b112790573794975a0b32324f517e5fead39fbf59ab99667837b0e08ebadfb6d41dcde85d474712b34b475a +DIST vault-1.10.5-vendor.tar.gz 50096802 BLAKE2B 07f797666f97666a3dbdfb3cca7ba9fea1a45b26fd35d902200acdf3bad33ad365f4d547a1c3fe42f9e6a41258713b48673236d5f64547016ba08b43ede4eeda SHA512 87f56ff16a2a28690dd128ff0f1c480616ae7948eaff337e3d3e4eb3370d6d1322b2a488044bc237f9eafc60d42652f3a7decb7283d1596285762cf570fea8ca +DIST vault-1.10.5-webui.tar.xz 1258192 BLAKE2B c546475dc9949c8854e702ff97267cde97472b47f209e7ed923e6caf9d0fe2b615c0087299148c0325669ae25b4ec111d7e8eff8454dfe5fe15a47bf4c969984 SHA512 fb44ad261cfa2e492b824fc8ec0ad44e54eaa417980bd9cd845e017fcad23670231a696df306332df5cfd5ce039cc1e3f744fe3ef35563b4902ebb15798a6b1d DIST vault-1.11.0-vendor.tar.gz 49927497 BLAKE2B d7a12c1c1710c2a487b9c08a871b1d7b011d90957cab6980eb2f7eaff4ff544509899ee07c326bba8310ff16ee3bf88586dba340249cf0f7804007963af7d692 SHA512 b3b9275d5ae41c21826ed0bf1eeaffffe10e5e95b085bf8cf6af6c9ff565848f4a3f83d9a8d6165867de11b0f877383cb972e7d4313a753b0dca391203ecb4c6 DIST vault-1.11.0-webui.tar.xz 1335764 BLAKE2B 9733ae0c2fe04018dac73358a56a162e23877e68b3ce59ca569cea7e27f39c91727ab0810a737167b3f02d92a0d58e9a7195da892c677bece60fbe965dba7fdf SHA512 a5df9f0e854af8f30d6b5d15628a087c1c37361e2a0de4e412e7f78ac51affc774c1a6ed084dd849b68b147d527547593c1124d1170be38b918efd28081a6f0b +DIST vault-1.11.1-vendor.tar.gz 52063513 BLAKE2B adb2fb6ab7991e94ce00aa298837f2fac21c24bb8ea8edd2265eed6664498b38567d81fcfe28749b4bf16c449c769448a75fa3c1403f5cdf33b18580d8a65936 SHA512 c1247308f390117c98e43dd82498a069c34d3e766298dd05d5ddb5f69b9a3db2e312b897f35c9f63225cffcac476ba1021a4a71100721848642b6c4412123251 +DIST vault-1.11.1-webui.tar.xz 1335740 BLAKE2B 6a6fdcb22563ad4c3f18bf3816fe8a016c11d19a014458594c2dade3dc8e908db252c34bad88be9e80c2a6408af28af6324158e1e69b40061af6d6fe1a66c655 SHA512 1c02e0ef645df946ffb9d967a9be230800e67597d0ed6cf8afb2688eed9ca863a1f29efeefbb51e0257d2be588da443864df9e1306956844645b0168c2d58d9b diff --git a/app-admin/vault/vault-1.10.5.ebuild b/app-admin/vault/vault-1.10.5.ebuild new file mode 100644 index 000000000000..6024fed54e00 --- /dev/null +++ b/app-admin/vault/vault-1.10.5.ebuild @@ -0,0 +1,85 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit fcaps go-module systemd + +DESCRIPTION="A tool for managing secrets" +HOMEPAGE="https://vaultproject.io/" + +VAULT_WEBUI_ARCHIVE="${P}-webui.tar.xz" +SRC_URI="https://github.com/zmedico/vault/archive/refs/tags/v${PV}-vendor.tar.gz -> ${P}-vendor.tar.gz + webui? ( + https://dev.gentoo.org/~zmedico/dist/${VAULT_WEBUI_ARCHIVE} + )" + +LICENSE="MPL-2.0 Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm64" +IUSE="+webui" + +BDEPEND=" + app-arch/zip + dev-go/gox + >=dev-lang/go-1.15.3" +COMMON_DEPEND="acct-group/vault + acct-user/vault" + DEPEND="${COMMON_DEPEND}" + RDEPEND="${COMMON_DEPEND}" + +FILECAPS=( + -m 755 'cap_ipc_lock=+ep' usr/bin/${PN} +) + +RESTRICT+=" test" +S=${WORKDIR}/${P}-vendor + +src_unpack() { + default +} + +src_prepare() { + default + # Avoid the need to have a git checkout + sed -e 's:^\(GIT_COMMIT=\).*:\1:' \ + -e 's:^\(GIT_DIRTY=\).*:\1:' \ + -e s:\'\${GIT_COMMIT}\${GIT_DIRTY}\':: \ + -i scripts/build.sh || die + sed -e "/hooks/d" \ + -e 's|^\([[:space:]]*\)goimports .*)|\1true|' \ + -e "s/gofumpt/gofmt/g" \ + -i Makefile || die + if [[ -d "${WORKDIR}/http/web_ui" ]]; then + rm -rf "${S}/http/web_ui" || die + mv "${WORKDIR}/http/web_ui" "${S}/http/web_ui" || + die "mv failed" + else + mkdir -p "${S}/http/web_ui" || die + touch "${S}/http/web_ui/no_web_ui" || die + fi +} + +src_compile() { + mkdir "${T}"/bin || die + BUILD_TAGS="$(usex webui ui '')" \ + GOPATH="${T}" \ + XC_ARCH=$(go env GOARCH) \ + XC_OS=$(go env GOOS) \ + XC_OSARCH=$(go env GOOS)/$(go env GOARCH) \ + emake bin +} + +src_install() { + dobin bin/${PN} + dodoc CHANGELOG.md CONTRIBUTING.md README.md + insinto /etc/${PN}.d + doins "${FILESDIR}/"*.json.example + insinto /etc/logrotate.d + newins "${FILESDIR}/${PN}.logrotated" "${PN}" + newinitd "${FILESDIR}/${PN}.initd" "${PN}" + newconfd "${FILESDIR}/${PN}.confd" "${PN}" + systemd_dounit "${FILESDIR}/${PN}.service" + keepdir /var/log/${PN} + fowners ${PN}:${PN} /var/log/${PN} +} diff --git a/app-admin/vault/vault-1.11.1.ebuild b/app-admin/vault/vault-1.11.1.ebuild new file mode 100644 index 000000000000..004b6dd49b57 --- /dev/null +++ b/app-admin/vault/vault-1.11.1.ebuild @@ -0,0 +1,86 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit fcaps go-module systemd + +DESCRIPTION="A tool for managing secrets" +HOMEPAGE="https://vaultproject.io/" + +VAULT_WEBUI_ARCHIVE="${P}-webui.tar.xz" +SRC_URI="https://github.com/zmedico/vault/archive/refs/tags/v${PV}-vendor.tar.gz -> ${P}-vendor.tar.gz + webui? ( + https://dev.gentoo.org/~zmedico/dist/${VAULT_WEBUI_ARCHIVE} + )" + +LICENSE="MPL-2.0 Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm64" +IUSE="+webui" + +BDEPEND=" + app-arch/zip + dev-go/gox + >=dev-lang/go-1.15.3" +COMMON_DEPEND="acct-group/vault + acct-user/vault" + DEPEND="${COMMON_DEPEND}" + RDEPEND="${COMMON_DEPEND}" + +FILECAPS=( + -m 755 'cap_ipc_lock=+ep' usr/bin/${PN} +) + +RESTRICT+=" test" +S=${WORKDIR}/${P}-vendor + +src_unpack() { + default +} + +src_prepare() { + default + # Avoid the need to have a git checkout + sed -e 's:^\(GIT_COMMIT=\).*:\1:' \ + -e 's:^\(GIT_DIRTY=\).*:\1:' \ + -e s:\'\${GIT_COMMIT}\${GIT_DIRTY}\':: \ + -e "s|^BUILD_DATE=.*|BUILD_DATE=$(date +%Y-%m-%dT%H:%M:%SZ)|" \ + -i scripts/build.sh || die + sed -e "/hooks/d" \ + -e 's|^\([[:space:]]*\)goimports .*)|\1true|' \ + -e "s/gofumpt/gofmt/g" \ + -i Makefile || die + if [[ -d "${WORKDIR}/http/web_ui" ]]; then + rm -rf "${S}/http/web_ui" || die + mv "${WORKDIR}/http/web_ui" "${S}/http/web_ui" || + die "mv failed" + else + mkdir -p "${S}/http/web_ui" || die + touch "${S}/http/web_ui/no_web_ui" || die + fi +} + +src_compile() { + mkdir "${T}"/bin || die + BUILD_TAGS="$(usex webui ui '')" \ + GOPATH="${T}" \ + XC_ARCH=$(go env GOARCH) \ + XC_OS=$(go env GOOS) \ + XC_OSARCH=$(go env GOOS)/$(go env GOARCH) \ + emake bin +} + +src_install() { + dobin bin/${PN} + dodoc CHANGELOG.md CONTRIBUTING.md README.md + insinto /etc/${PN}.d + doins "${FILESDIR}/"*.json.example + insinto /etc/logrotate.d + newins "${FILESDIR}/${PN}.logrotated" "${PN}" + newinitd "${FILESDIR}/${PN}.initd" "${PN}" + newconfd "${FILESDIR}/${PN}.confd" "${PN}" + systemd_dounit "${FILESDIR}/${PN}.service" + keepdir /var/log/${PN} + fowners ${PN}:${PN} /var/log/${PN} +} diff --git a/app-portage/hackport/Manifest b/app-portage/hackport/Manifest index 8c6f72c36bae..51264754d37e 100644 --- a/app-portage/hackport/Manifest +++ b/app-portage/hackport/Manifest @@ -1,2 +1 @@ -DIST hackport-0.6.6.tar.gz 2079279 BLAKE2B 6e4084babb3fc036568387845ca2793d47a29ce94c24211259324d3040d0c0e15be028d0a9726ea8512dd518d7e9dd8447aba67725c0916418f523449f2179b4 SHA512 b836bd21e3713796feaab9ca830fdef80f52b9723d0fba6cfb60d802e038eaec2da8492eb025d6ae376aea69734c031e23c0887642675c4f767b1592d82c5523 -DIST hackport-0.7.tar.gz 2080625 BLAKE2B 87c70180df45c2bd6c6e51dff31b31c45d0c3c572223803daed8f2b9045ececa63edea1b9f35984067b393b25a31e78c761a12478c1dce6e9cc57dc4c0f1b4b0 SHA512 72f1638d2007d8b085c8dcb8d01b171c6a0e8306c71efc7be7ffc8d3e2a6fdee8e74c2bb62e8762a4315e3384d2f78ac12d45faf79b94270c638a9afc7cc1a82 +DIST hackport-0.7.2.1.tar.gz 2083380 BLAKE2B 0fe2eadfcd7a551a61ecb013973b63aec8df0a194403880ef15563a9f7462db2889fda37012e78665c2190b8ab4cd1e48f0088c4e435e7cca1f0cd0fefd119f0 SHA512 b12c3a10c750b6f1d71b9766d08934bce5fb1f62e1c13de71f84280b66ed5d5a6b7a5c62982c7c3c4a02908e1e835b709e7ac7f9b2c44a732320d55f293dfcda diff --git a/app-portage/hackport/hackport-0.6.6.ebuild b/app-portage/hackport/hackport-0.6.6.ebuild deleted file mode 100644 index 149aa49011ec..000000000000 --- a/app-portage/hackport/hackport-0.6.6.ebuild +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# ebuild generated by hackport 0.6.5.9999 - -CABAL_FEATURES="test-suite" -inherit haskell-cabal - -DESCRIPTION="Hackage and Portage integration tool" -HOMEPAGE="https://hackage.haskell.org/package/hackport" -SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz" - -LICENSE="GPL-3+" -SLOT="0" -KEYWORDS="~amd64 ~x86" -IUSE="" - -RDEPEND="app-portage/repoman - >=dev-haskell/async-2.0:= - >=dev-haskell/base16-bytestring-0.1.1:= - >=dev-haskell/base64-bytestring-1.0:= - >=dev-haskell/cryptohash-sha256-0.11:= - dev-haskell/ed25519:= - dev-haskell/extensible-exceptions:= - >=dev-haskell/hashable-1.0:= - >=dev-haskell/http-4000.1.5:= - >=dev-haskell/lukko-0.1:= - >=dev-haskell/mtl-2.1:= - >=dev-haskell/network-2.6:= - >=dev-haskell/network-uri-2.6:= - >=dev-haskell/old-locale-1.0:= - >=dev-haskell/parsec-3.1.13:= - >=dev-haskell/random-1.0:= - dev-haskell/split:= - >=dev-haskell/stm-2.0:= - >=dev-haskell/tar-0.5:= - >=dev-haskell/text-1.2.3.0:= - >=dev-haskell/xml-1.3.7:= - >=dev-haskell/zlib-0.5.3:= - >=dev-lang/ghc-8.0.1:= -" -DEPEND="${RDEPEND} - >=dev-haskell/cabal-1.24.0.0 - test? ( >=dev-haskell/doctest-0.8 - >=dev-haskell/hspec-2.0 - >=dev-haskell/quickcheck-2.0 ) -" - -src_install() { - haskell-cabal_src_install - doman man/hackport.1 -} diff --git a/app-portage/hackport/hackport-0.7.ebuild b/app-portage/hackport/hackport-0.7.2.1.ebuild index bbe4e16168c8..af17c804b2db 100644 --- a/app-portage/hackport/hackport-0.7.ebuild +++ b/app-portage/hackport/hackport-0.7.2.1.ebuild @@ -1,9 +1,10 @@ -# Copyright 1999-2021 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 -# ebuild generated by hackport 0.6.6.9999 +# ebuild generated by hackport 0.7.1.1.9999 +#hackport: flags: +cabal-v1 CABAL_FEATURES="test-suite" inherit haskell-cabal @@ -15,43 +16,50 @@ SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz" LICENSE="GPL-3+" SLOT="0" KEYWORDS="~amd64 ~x86" -IUSE="" RDEPEND=">=dev-haskell/async-2.0:= - >=dev-haskell/base16-bytestring-0.1.1:= <dev-haskell/base16-bytestring-1:= + >=dev-haskell/base16-bytestring-0.1.1:= >=dev-haskell/base64-bytestring-1.0:= >=dev-haskell/cryptohash-sha256-0.11:= - dev-haskell/ed25519:= + >=dev-haskell/echo-0.1.3:= + >=dev-haskell/ed25519-0.0:= + >=dev-haskell/edit-distance-0.2.2:= dev-haskell/extensible-exceptions:= >=dev-haskell/hashable-1.0:= >=dev-haskell/http-4000.1.5:= - >=dev-haskell/lukko-0.1:= - >=dev-haskell/mtl-2.1:= - >=dev-haskell/network-2.6:= - >=dev-haskell/network-uri-2.6:= - >=dev-haskell/old-locale-1.0:= + >=dev-haskell/network-3.0:= + >=dev-haskell/network-uri-2.6.0.2:= >=dev-haskell/parallel-3.2.1.0:= - >=dev-haskell/parsec-3.1.13:= - >=dev-haskell/random-1.0:= + dev-haskell/quickcheck:2= + >=dev-haskell/random-1:= + >=dev-haskell/regex-base-0.94.0.0:= + >=dev-haskell/regex-posix-0.96.0.0:= + >=dev-haskell/resolv-0.1.1:= dev-haskell/split:= >=dev-haskell/stm-2.0:= - >=dev-haskell/tar-0.5:= - >=dev-haskell/text-1.2.3.0:= - >=dev-haskell/xml-1.3.7:= + >=dev-haskell/tar-0.5.0.3:= + dev-haskell/xml:= >=dev-haskell/zlib-0.5.3:= - >=dev-lang/ghc-8.0.1:= + >=dev-lang/ghc-8.4.3:= " DEPEND="${RDEPEND} - >=dev-haskell/cabal-1.24.0.0 - test? ( >=dev-haskell/doctest-0.8 + >=dev-haskell/cabal-2.2.0.1 + test? ( dev-haskell/base-compat + dev-haskell/cabal-doctest + >=dev-haskell/doctest-0.8 + dev-haskell/glob >=dev-haskell/hspec-2.0 >=dev-haskell/quickcheck-2.0 ) " RDEPEND+=" - app-portage/repoman dev-util/pkgcheck " +src_configure() { + haskell-cabal_src_configure \ + --flag=cabal-v1 +} + src_install() { haskell-cabal_src_install doman man/hackport.1 diff --git a/app-portage/hackport/hackport-9999.ebuild b/app-portage/hackport/hackport-9999.ebuild index 6853550d5f1f..7cc74ec9ca0f 100644 --- a/app-portage/hackport/hackport-9999.ebuild +++ b/app-portage/hackport/hackport-9999.ebuild @@ -1,9 +1,10 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=8 -# ebuild generated by hackport 0.5.1.9999 +# ebuild generated by hackport 0.7.1.1.9999 +#hackport: flags: +cabal-v1 CABAL_FEATURES="test-suite" EGIT_REPO_URI="https://github.com/gentoo-haskell/hackport.git" @@ -13,47 +14,56 @@ inherit git-r3 haskell-cabal DESCRIPTION="Hackage and Portage integration tool" HOMEPAGE="https://github.com/gentoo-haskell/hackport" -LICENSE="GPL-2" +LICENSE="GPL-3+" SLOT="0" KEYWORDS="" -IUSE="" -RESTRICT=test # tests are broken: need path to ebuild tree - -RDEPEND=" - app-portage/repoman - dev-haskell/async:= - dev-haskell/base16-bytestring:= - dev-haskell/base64-bytestring:= - dev-haskell/cryptohash:= - dev-haskell/ed25519:= +RDEPEND=">=dev-haskell/async-2.0:= + >=dev-haskell/base16-bytestring-0.1.1:= + >=dev-haskell/base64-bytestring-1.0:= + >=dev-haskell/cryptohash-sha256-0.11:= + >=dev-haskell/echo-0.1.3:= + >=dev-haskell/ed25519-0.0:= + >=dev-haskell/edit-distance-0.2.2:= dev-haskell/extensible-exceptions:= - dev-haskell/hashable:= - >=dev-haskell/http-4000.0.3:= - dev-haskell/missingh:= - dev-haskell/mtl:= - >=dev-haskell/network-2.6:= - >=dev-haskell/network-uri-2.6:= - dev-haskell/old-locale:= - dev-haskell/old-time:= - dev-haskell/parsec:= - dev-haskell/random:= - dev-haskell/regex-compat:= + >=dev-haskell/hashable-1.0:= + >=dev-haskell/http-4000.1.5:= + >=dev-haskell/network-3.0:= + >=dev-haskell/network-uri-2.6.0.2:= + >=dev-haskell/parallel-3.2.1.0:= + dev-haskell/quickcheck:2= + >=dev-haskell/random-1:= + >=dev-haskell/regex-base-0.94.0.0:= + >=dev-haskell/regex-posix-0.96.0.0:= + >=dev-haskell/resolv-0.1.1:= dev-haskell/split:= - dev-haskell/stm:= - >=dev-haskell/tar-0.5:= - >=dev-haskell/xml-1.3.7:= - dev-haskell/zlib:= - >=dev-lang/ghc-7.8.2:= + >=dev-haskell/stm-2.0:= + >=dev-haskell/tar-0.5.0.3:= + dev-haskell/xml:= + >=dev-haskell/zlib-0.5.3:= + >=dev-lang/ghc-8.4.3:= " DEPEND="${RDEPEND} - >=dev-haskell/cabal-1.18.1.3 - test? ( dev-haskell/hunit ) + >=dev-haskell/cabal-2.2.0.1 + test? ( dev-haskell/base-compat + dev-haskell/cabal-doctest + >=dev-haskell/doctest-0.8 + dev-haskell/glob + >=dev-haskell/hspec-2.0 + >=dev-haskell/quickcheck-2.0 ) +" +RDEPEND+=" + dev-util/pkgcheck " src_prepare() { default - sed -e 's/^Version:.*/&.9999/' -i ${PN}.cabal || die # just to distinct from release install + sed -e 's/^Version:.*/&.9999/' -i ${PN}.cabal || die # just to distinguish from release install +} + +src_configure() { + haskell-cabal_src_configure \ + --flag=cabal-v1 } src_install() { diff --git a/eclass/haskell-cabal.eclass b/eclass/haskell-cabal.eclass index 541bb4a90ee5..d437fc824f53 100644 --- a/eclass/haskell-cabal.eclass +++ b/eclass/haskell-cabal.eclass @@ -8,7 +8,6 @@ # Original author: Andres Loeh <kosmikus@gentoo.org> # Original author: Duncan Coutts <dcoutts@gentoo.org> # @SUPPORTED_EAPIS: 6 7 8 -# @PROVIDES: ghc-package # @BLURB: for packages that make use of the Haskell Common Architecture for Building Applications and Libraries (cabal) # @DESCRIPTION: # Basic instructions: @@ -50,7 +49,7 @@ esac inherit ghc-package multilib toolchain-funcs -EXPORT_FUNCTIONS pkg_setup src_configure src_compile src_test src_install pkg_postinst pkg_postrm +EXPORT_FUNCTIONS pkg_setup src_prepare src_configure src_compile src_test src_install pkg_postinst pkg_postrm # @ECLASS_VARIABLE: CABAL_EXTRA_CONFIGURE_FLAGS # @USER_VARIABLE @@ -123,6 +122,72 @@ EXPORT_FUNCTIONS pkg_setup src_configure src_compile src_test src_install pkg_po # Set to anything else to disable. : ${CABAL_REPORT_OTHER_BROKEN_PACKAGES:=yes} +# @ECLASS_VARIABLE: CABAL_HACKAGE_REVISION +# @PRE_INHERIT +# @DESCRIPTION: +# Set the upstream revision number from Hackage. This will automatically +# add the upstream cabal revision to SRC_URI and apply it in src_prepare. +: ${CABAL_HACKAGE_REVISION:=0} + +# @ECLASS_VARIABLE: CABAL_PN +# @PRE_INHERIT +# @DESCRIPTION: +# Set the name of the package as it is recorded in the Hackage database. This +# is mostly used when packages use CamelCase names upstream, but we want them +# to be lowercase in portage. +: ${CABAL_PN:=${PN}} + +# @ECLASS_VARIABLE: CABAL_PV +# @PRE_INHERIT +# @DESCRIPTION: +# Set the version of the package as it is recorded in the Hackage database. +# This can be useful if we use a different versioning scheme in Portage than +# the one from upstream +: ${CABAL_PV:=${PV}} + +# @ECLASS_VARIABLE: CABAL_P +# @OUTPUT_VARIABLE +# @DESCRIPTION: +# The combined $CABAL_PN and $CABAL_PV variables, analogous to $P +CABAL_P="${CABAL_PN}-${CABAL_PV}" + +S="${WORKDIR}/${CABAL_P}" + +# @ECLASS_VARIABLE: CABAL_FILE +# @DESCRIPTION: +# The location of the .cabal file for the Haskell package. This defaults to +# "${S}/${CABAL_PN}.cabal". +: ${CABAL_FILE:="${S}/${CABAL_PN}.cabal"} + +# @ECLASS_VARIABLE: CABAL_DISTFILE +# @OUTPUT_VARIABLE +# @DESCRIPTION: +# The name of the .cabal file downloaded from Hackage. This filename does not +# include $DISTDIR +if [[ ${CABAL_HACKAGE_REVISION} -ge 1 ]]; then + CABAL_DISTFILE="${P}-rev${CABAL_HACKAGE_REVISION}.cabal" +fi + +# @ECLASS_VARIABLE: CABAL_CHDEPS +# @DEFAULT_UNSET +# @DESCRIPTION: +# Specifies changes to be made to the .cabal file. Uses the cabal_chdeps +# function internally and shares the same syntax. +# @EXAMPLE: +# CABAL_CHDEPS=( +# 'base >= 4.2 && < 4.6' 'base >= 4.2 && < 4.7' +# 'containers ==0.4.*' 'containers >= 0.4 && < 0.6' +# ) +: ${CABAL_CHDEPS:=} + + +# @ECLASS_VARIABLE: CABAL_LIVE_VERSION +# @PRE_INHERIT +# @DEFAULT_UNSET +# @DESCRIPTION: +# Set this to any value to prevent SRC_URI from being set automatically. +: ${CABAL_LIVE_VERSION:=} + # 'dev-haskell/cabal' passes those options with ./configure-based # configuration, but most packages don't need/don't accept it: # #515362, #515362 @@ -156,7 +221,7 @@ fi if [[ -n "${CABAL_USE_HOOGLE}" ]]; then # enabled only in ::haskell - #IUSE="${IUSE} hoogle" + # IUSE="${IUSE} hoogle" CABAL_USE_HOOGLE= fi @@ -169,6 +234,26 @@ if [[ -n "${CABAL_TEST_SUITE}" ]]; then RESTRICT+=" !test? ( test )" fi +# If SRC_URI is defined in the ebuild without appending, it will overwrite +# the value set here. This will not be set on packages whose versions end in "9999" +# or if CABAL_LIVE_VERSION is set. +case $PV in + *9999) ;; + *) + if [[ -z "${CABAL_LIVE_VERSION}" ]]; then + if [[ "${CABAL_P}" == "${P}" ]]; then + SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz" + else + SRC_URI="https://hackage.haskell.org/package/${CABAL_P}/${CABAL_P}.tar.gz -> ${P}.tar.gz" + fi + if [[ -n ${CABAL_DISTFILE} ]]; then + SRC_URI+=" https://hackage.haskell.org/package/${CABAL_P}/revision/${CABAL_HACKAGE_REVISION}.cabal -> ${CABAL_DISTFILE}" + fi + fi ;; +esac + +BDEPEND="${BDEPEND} app-text/dos2unix" + # returns the version of cabal currently in use. # Rarely it's handy to pin cabal version from outside. : ${_CABAL_VERSION_CACHE:=""} @@ -228,20 +313,6 @@ cabal-bootstrap() { $(ghc-getghc) "$@" } if $(ghc-supports-shared-libraries); then - # # some custom build systems might use external libraries, - # # for which we don't have shared libs, so keep static fallback - # bug #411789, http://hackage.haskell.org/trac/ghc/ticket/5743#comment:3 - # http://hackage.haskell.org/trac/ghc/ticket/7062 - # http://hackage.haskell.org/trac/ghc/ticket/3072 - # ghc does not set RPATH for extralibs, thus we do it ourselves by hands - einfo "Prepending $(ghc-libdir) to LD_LIBRARY_PATH" - if [[ ${CHOST} != *-darwin* ]]; then - LD_LIBRARY_PATH="$(ghc-libdir)${LD_LIBRARY_PATH:+:}${LD_LIBRARY_PATH}" - export LD_LIBRARY_PATH - else - DYLD_LIBRARY_PATH="$(ghc-libdir)${DYLD_LIBRARY_PATH:+:}${DYLD_LIBRARY_PATH}" - export DYLD_LIBRARY_PATH - fi { make_setup -dynamic "$@" && ./setup --help >/dev/null; } || make_setup "$@" || die "compiling ${setupmodule} failed" else @@ -288,8 +359,8 @@ cabal-show-brokens() { elog "ghc-pkg check: 'checking for other broken packages:'" # pretty-printer $(ghc-getghcpkg) check 2>&1 \ - | grep -E -v '^Warning: haddock-(html|interfaces): ' \ - | grep -E -v '^Warning: include-dirs: ' \ + | egrep -v '^Warning: haddock-(html|interfaces): ' \ + | egrep -v '^Warning: include-dirs: ' \ | head -n 20 cabal-die-if-nonempty 'broken' \ @@ -448,7 +519,7 @@ cabal-build() { } cabal-copy() { - set -- copy --destdir="${D}" "$@" + set -- copy "$@" --destdir="${D}" echo ./setup "$@" ./setup "$@" || die "setup copy failed" @@ -510,6 +581,29 @@ haskell-cabal_pkg_setup() { fi } +haskell-cabal_src_prepare() { + # Needed for packages that are still using MY_PN + if [[ -n ${MY_PN} ]]; then + local cabal_file="${S}/${MY_PN}.cabal" + else + local cabal_file="${CABAL_FILE}" + fi + + if [[ -n ${CABAL_DISTFILE} ]]; then + # pull revised cabal from upstream + einfo "Using revised .cabal file from Hackage: revision ${CABAL_HACKAGE_REVISION}" + cp "${DISTDIR}/${CABAL_DISTFILE}" "${cabal_file}" || die + fi + + # Convert to unix line endings + dos2unix "${cabal_file}" || die + + # Apply patches *after* pulling the revised cabal + default + + [[ -n "${CABAL_CHDEPS}" ]] && cabal_chdeps "${CABAL_CHDEPS[@]}" +} + haskell-cabal_src_configure() { cabal-is-dummy-lib && return @@ -599,7 +693,8 @@ haskell-cabal_src_test() { # exported function: cabal-style copy and register cabal_src_install() { if ! cabal-is-dummy-lib; then - cabal-copy + # Pass arguments to cabal-copy + cabal-copy "$@" cabal-pkg fi @@ -614,10 +709,14 @@ cabal_src_install() { touch "${hint_file}" || die } +# Arguments passed to this function will make their way to `cabal-copy` +# and eventually `./setup copy`. This allows you to specify which +# components will be installed. +# e.g. `haskell-cabal_src_install "lib:${PN}"` will only install the library haskell-cabal_src_install() { pushd "${S}" > /dev/null || die - cabal_src_install + cabal_src_install "$@" popd > /dev/null || die } @@ -678,23 +777,28 @@ cabal_flag() { #} # or # src_prepare() { -# CABAL_FILE=${S}/${MY_PN}.cabal cabal_chdeps \ +# CABAL_FILE=${S}/${CABAL_PN}.cabal cabal_chdeps \ # 'base >= 4.2 && < 4.6' 'base >= 4.2 && < 4.7' -# CABAL_FILE=${S}/${MY_PN}-tools.cabal cabal_chdeps \ +# CABAL_FILE=${S}/${CABAL_PN}-tools.cabal cabal_chdeps \ # 'base == 3.*' 'base >= 4.2 && < 4.7' #} # cabal_chdeps() { - local cabal_fn=${MY_PN:-${PN}}.cabal - local cf=${CABAL_FILE:-${S}/${cabal_fn}} + # Needed for compatibility with ebuilds still using MY_PN + if [[ -n ${MY_PN} ]]; then + local cabal_file="${S}/${MY_PN}.cabal" + else + local cabal_file="${CABAL_FILE}" + fi + local from_ss # ss - substring local to_ss local orig_c # c - contents local new_c - [[ -f $cf ]] || die "cabal file '$cf' does not exist" + [[ -f "${cabal_file}" ]] || die "cabal file '${cabal_file}' does not exist" - orig_c=$(< "$cf") + orig_c=$(< "${cabal_file}") while :; do from_pat=$1 @@ -712,9 +816,9 @@ cabal_chdeps() { new_c=${orig_c//${from_pat}/${to_str}} if [[ -n $CABAL_DEBUG_LOOSENING ]]; then - echo "${orig_c}" >"${T}/${cf}".pre - echo "${new_c}" >"${T}/${cf}".post - diff -u "${T}/${cf}".{pre,post} + echo "${orig_c}" >"${T}/${cabal_file}".pre + echo "${new_c}" >"${T}/${cabal_file}".post + diff -u "${T}/${cabal_file}".{pre,post} fi [[ "${orig_c}" == "${new_c}" ]] && die "no trigger for '${from_pat}'" @@ -723,7 +827,7 @@ cabal_chdeps() { shift done - echo "${new_c}" > "$cf" || + echo "${new_c}" > "$cabal_file" || die "failed to update" } diff --git a/profiles/package.mask b/profiles/package.mask index 05c5f232a230..05c4dfc2fc74 100644 --- a/profiles/package.mask +++ b/profiles/package.mask @@ -38,13 +38,295 @@ # are broken, or severely out of date. The aim is to have the Haskell overlay # (::haskell) be the place for development packages and only have packages # needed for end-user applications in ::gentoo, as the status who has -# proven to be unsustainable. +# proven to be unsustainable. More up-to-date versions of these packages +# are available in ::haskell. # Removal on 2022-08-22. -dev-haskell/hsql-mysql +dev-haskell/ac-ppm +dev-haskell/aeson-compat +dev-haskell/aeson-qq +dev-haskell/alex-tools +dev-haskell/alut +dev-haskell/argparser +dev-haskell/arithmoi +dev-haskell/arrows +dev-haskell/ascii-progress +dev-haskell/attoparsec-conduit +dev-haskell/attoparsec-enumerator +dev-haskell/authenticate +dev-haskell/base-noprelude +dev-haskell/basic-prelude +dev-haskell/binary-instances +dev-haskell/binary-tagged +dev-haskell/biocore +dev-haskell/biofasta +dev-haskell/biosff +dev-haskell/bitarray +dev-haskell/bits-atomic +dev-haskell/bitwise +dev-haskell/blaze-builder-conduit +dev-haskell/blaze-textual +dev-haskell/boolean +dev-haskell/boundedchan +dev-haskell/boxes +dev-haskell/bytedump +dev-haskell/bytes +dev-haskell/bytestring-mmap +dev-haskell/bytestring-show +dev-haskell/bzlib +dev-haskell/cairo +dev-haskell/cereal-vector +dev-haskell/cgi +dev-haskell/chasingbottoms +dev-haskell/chimera +dev-haskell/chunked-data +dev-haskell/cipher-camellia +dev-haskell/cipher-des +dev-haskell/cipher-rc4 +dev-haskell/classy-prelude +dev-haskell/cmark +dev-haskell/cmark-gfm +dev-haskell/comonad-transformers +dev-haskell/comonads-fd +dev-haskell/configfile +dev-haskell/control-monad-loop +dev-haskell/cpu +dev-haskell/crypto +dev-haskell/crypto-numbers +dev-haskell/crypto-pubkey +dev-haskell/crypto-random-api +dev-haskell/cryptohash-conduit +dev-haskell/curl +dev-haskell/data-accessor +dev-haskell/data-binary-ieee754 +dev-haskell/data-endian +dev-haskell/data-hash +dev-haskell/dataenc +dev-haskell/date-cache +dev-haskell/deepseq-generics +dev-haskell/dictionary-sharing +dev-haskell/djinn-ghc +dev-haskell/djinn-lib +dev-haskell/dlist-instances +dev-haskell/double-conversion +dev-haskell/edisonapi +dev-haskell/edisoncore +dev-haskell/editline +dev-haskell/ekg +dev-haskell/ekg-core +dev-haskell/ekg-json +dev-haskell/enumerator +dev-haskell/equivalence +dev-haskell/esqueleto +dev-haskell/exact-pi +dev-haskell/executable-path +dev-haskell/failure +dev-haskell/fclabels +dev-haskell/fgl-arbitrary +dev-haskell/file-location +dev-haskell/filestore +dev-haskell/fixed +dev-haskell/fmlist +dev-haskell/geniplate-mirror +dev-haskell/gio +dev-haskell/git +dev-haskell/gitrev +dev-haskell/glib +dev-haskell/gluraw +dev-haskell/glut +dev-haskell/gnuidn +dev-haskell/gnutls +dev-haskell/graphviz +dev-haskell/gsasl +dev-haskell/gtk +dev-haskell/gtk2hs-buildtools +dev-haskell/gtk3 +dev-haskell/hakyll +dev-haskell/half +dev-haskell/hamlet +dev-haskell/happstack-server +dev-haskell/harp +dev-haskell/haskell-src +dev-haskell/haskell-src-exts-util +dev-haskell/haxml +dev-haskell/hcg-minus +dev-haskell/hcodecs +dev-haskell/hdbc-mysql +dev-haskell/heaps +dev-haskell/hex +dev-haskell/hexpat +dev-haskell/highlighting-kate dev-haskell/hit +dev-haskell/hoauth2 +dev-haskell/hps +dev-haskell/hs-bibutils +dev-haskell/hs3 dev-haskell/hsb2hs -dev-haskell/lhs2tex +dev-haskell/hspec-smallcheck +dev-haskell/hsql dev-haskell/hsql-odbc +dev-haskell/hsql-sqlite3 +dev-haskell/hstringtemplate +dev-haskell/htf +dev-haskell/http-attoparsec +dev-haskell/http-client-conduit +dev-haskell/http-client-multipart +dev-haskell/http-reverse-proxy +dev-haskell/icalendar +dev-haskell/iconv +dev-haskell/idiii +dev-haskell/idna +dev-haskell/inspection-testing +dev-haskell/integer-roots +dev-haskell/json +dev-haskell/keys +dev-haskell/language-bash +dev-haskell/language-css +dev-haskell/language-dot +dev-haskell/language-ecmascript +dev-haskell/language-glsl +dev-haskell/language-lua +dev-haskell/language-python +dev-haskell/lazysmallcheck +dev-haskell/lcs +dev-haskell/lens-family +dev-haskell/lens-family-core +dev-haskell/lens-family-th +dev-haskell/lens-simple +dev-haskell/lhs2tex +dev-haskell/libxml +dev-haskell/libxml-sax +dev-haskell/linear +dev-haskell/list +dev-haskell/listlike +dev-haskell/logict-state +dev-haskell/lrucache +dev-haskell/maccatcher +dev-haskell/markdown-unlit +dev-haskell/mersenne-random-pure64 +dev-haskell/mime +dev-haskell/mime-mail +dev-haskell/minisat +dev-haskell/mod +dev-haskell/monad-journal +dev-haskell/monad-unlift +dev-haskell/monadcatchio-mtl +dev-haskell/monadcatchio-transformers +dev-haskell/monadlib +dev-haskell/monadplus +dev-haskell/monadrandom +dev-haskell/mono-traversable-instances +dev-haskell/mtl-compat +dev-haskell/multipart +dev-haskell/murmur-hash +dev-haskell/mutable-containers +dev-haskell/mysql +dev-haskell/mysql-simple +dev-haskell/network-conduit +dev-haskell/network-data +dev-haskell/newtype +dev-haskell/nonce +dev-haskell/numinstances +dev-haskell/numtype-dk +dev-haskell/objectname +dev-haskell/openal +dev-haskell/opengl +dev-haskell/openglraw +dev-haskell/pandoc-citeproc +dev-haskell/pango +dev-haskell/pcap +dev-haskell/persistent-mysql +dev-haskell/persistent-postgresql +dev-haskell/persistent-qq +dev-haskell/pid1 +dev-haskell/pipes +dev-haskell/pointed +dev-haskell/postgresql-libpq +dev-haskell/postgresql-simple +dev-haskell/pqueue +dev-haskell/prelude-extras +dev-haskell/preprocessor-tools +dev-haskell/primitive-addr +dev-haskell/process-extras +dev-haskell/profunctor-extras +dev-haskell/psqueue +dev-haskell/publicsuffixlist +dev-haskell/punycode +dev-haskell/pwstore-fast +dev-haskell/quickcheck-classes +dev-haskell/quickcheck-classes-base +dev-haskell/quickcheck-unicode +dev-haskell/ranges +dev-haskell/readargs +dev-haskell/readline +dev-haskell/recaptcha +dev-haskell/regex-pcre-builtin +dev-haskell/riff +dev-haskell/say +dev-haskell/semigroupoid-extras +dev-haskell/semirings +dev-haskell/sendfile +dev-haskell/shakespeare-css +dev-haskell/shakespeare-i18n +dev-haskell/shakespeare-js +dev-haskell/shakespeare-text +dev-haskell/shell-escape +dev-haskell/size-based +dev-haskell/stack-bin +dev-haskell/stmonadtrans +dev-haskell/store +dev-haskell/store-core +dev-haskell/stream +dev-haskell/stringable +dev-haskell/stringprep +dev-haskell/stringsearch +dev-haskell/syb-with-class +dev-haskell/system-posix-redirect +dev-haskell/tagshare +dev-haskell/tagstream-conduit +dev-haskell/tasty-ant-xml +dev-haskell/tensor +dev-haskell/testing-feat +dev-haskell/testing-type-modifiers +dev-haskell/text-binary +dev-haskell/text-stream-decode +dev-haskell/th-utilities +dev-haskell/thyme +dev-haskell/top +dev-haskell/unexceptionalio +dev-haskell/uniqueid +dev-haskell/unixutils +dev-haskell/uri +dev-haskell/uri-bytestring +dev-haskell/uri-bytestring-aeson +dev-haskell/uri-encode +dev-haskell/url +dev-haskell/uuagc +dev-haskell/uuagc-cabal +dev-haskell/uulib +dev-haskell/vector-instances +dev-haskell/vector-space +dev-haskell/wai-conduit +dev-haskell/wai-test +dev-haskell/wavy +dev-haskell/with-location +dev-haskell/wl-pprint +dev-haskell/wl-pprint-text +dev-haskell/wx +dev-haskell/wxc +dev-haskell/wxcore +dev-haskell/wxdirect +dev-haskell/xmlgen +dev-haskell/yesod-auth +dev-haskell/yesod-auth-hashdb +dev-haskell/yesod-default +dev-haskell/yesod-json +dev-haskell/zlib-conduit +dev-haskell/zlib-enum +dev-util/bustle +games-board/goatee-gtk +sci-mathematics/agda +sci-mathematics/agda-stdlib +www-apps/gitit # Sam James <sam@gentoo.org> (2022-07-22) # Severely broken, unbuildable with modern glibc, several versions out of date, |