diff options
Diffstat (limited to 'dev-ada/gpr')
-rw-r--r-- | dev-ada/gpr/Manifest | 4 | ||||
-rw-r--r-- | dev-ada/gpr/gpr-23.0.0-r2.ebuild | 65 | ||||
-rw-r--r-- | dev-ada/gpr/gpr-23.0.0-r3.ebuild | 113 | ||||
-rw-r--r-- | dev-ada/gpr/metadata.xml | 1 |
4 files changed, 116 insertions, 67 deletions
diff --git a/dev-ada/gpr/Manifest b/dev-ada/gpr/Manifest index bbdf31275e90..2271800a56f7 100644 --- a/dev-ada/gpr/Manifest +++ b/dev-ada/gpr/Manifest @@ -1,3 +1,3 @@ DIST gpr-23.0.0.tar.gz 1005298 BLAKE2B 475ac5ad89a4d038dc8cdb953826f46e0f8f2bbf09a858366a634b5bacfc4b0282db4206cf5d113900dffd3c2ad9423b6c6e56de8058215a7946020c30dacc8b SHA512 f1cfd2c2162ffa984c62238a472438919c22a83b61e03c9234f6bc601c1d1e50981f52d024106ad5196dd83ee7686e864c8728c56d451be06baf96161afd8bcc -EBUILD gpr-23.0.0-r2.ebuild 1506 BLAKE2B 3891f188acbd2cc0ee7172d75c570a13741a1fa3c7c869f72e1ccfac9933536e1f611bfb638c48f247b4f1d95280614ae7707edf5967e00b041692db9d182803 SHA512 7a02854b23fffbf53d2c52c116790f471da5da76385935f5da859801663230cb6a6f4f92450a1c08a109a5d2003a621ca8988532b58781f2462c70ecded0272d -MISC metadata.xml 357 BLAKE2B c6eab7337743f6969c01915cefeb70482bca367bac4437612a496779cf32e602decab0761488aa9156c61102fa9875fa948840b44493634933cfbd6903132c6e SHA512 2b1b0517ac9d91a17d12dae70dd8caaec1d20819246cb49dcf4cb7244c13f43dda6bad1b8b7224ce9bb40f82c94186c1364848f182d3040d149591241643a0f1 +EBUILD gpr-23.0.0-r3.ebuild 3131 BLAKE2B bdd5d1b38a62cb07d982ae4fa6ceab1320202600c6b0ec9a8a346b66997cf372f4a326210c63d338afcd3bf17824e1dd9ff9ca5ea54dfab94acf3115b308a505 SHA512 7a4eb81e4cb8998bad3a92040da7b276ec6d473792e22afc564e2c0ca74f2b86baffcc03947adc1108cbadd24dfd77e3605b074e5efa03c7df065c7a5b394673 +MISC metadata.xml 425 BLAKE2B f43600b21f72ac0a1e54e757848b52c070dafa69d36c142d60d7693cdd17c9f3049948da3b6c069a46a3b1e836bac18d268823a80c037f4e14e08f4822b8e1a3 SHA512 c6df0aded61f6d481d64a331b5db0da30dd6a75c56cc051ad5ba7f90cc7376f17ede0b7c2f94acd110ccc104773c138d961040b272edc7a11f1671d548008e7e diff --git a/dev-ada/gpr/gpr-23.0.0-r2.ebuild b/dev-ada/gpr/gpr-23.0.0-r2.ebuild deleted file mode 100644 index ce0429b7f624..000000000000 --- a/dev-ada/gpr/gpr-23.0.0-r2.ebuild +++ /dev/null @@ -1,65 +0,0 @@ -# Copyright 2022-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -ADA_COMPAT=( gnat_2021 gcc_12 ) -PYTHON_COMPAT=( python3_{9,10,11} ) - -inherit python-any-r1 ada multiprocessing - -DESCRIPTION="LibGPR2 - Parser for GPR Project files" -HOMEPAGE="https://github.com/AdaCore/gpr" -SRC_URI="https://github.com/AdaCore/${PN}/archive/refs/tags/v${PV}.tar.gz - -> ${P}.tar.gz" - -LICENSE="Apache-2.0" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -RDEPEND="${ADA_DEPS} - dev-ada/xmlada[${ADA_USEDEP}] - shared? ( dev-ada/xmlada[shared,static-pic] ) - dev-ada/gnatcoll-core[${ADA_USEDEP}] - shared? ( dev-ada/gnatcoll-core[shared,static-pic] ) - dev-ada/gnatcoll-bindings[${ADA_USEDEP},iconv,gmp] - shared? ( dev-ada/gnatcoll-bindings[shared,static-pic] )" - -DEPEND="${RDEPEND} - dev-ada/gprconfig_kb[${ADA_USEDEP}] - dev-ada/gprbuild[${ADA_USEDEP}]" - -BDEPEND="${PYTHON_DEPS} - $(python_gen_any_dep ' - dev-ada/langkit[${PYTHON_USEDEP}] - ')" - -IUSE="+shared" -REQUIRED_USE="${ADA_REQUIRED_USE}" - -python_check_deps() { - python_has_version "dev-ada/langkit[${PYTHON_USEDEP}]" -} - -src_configure() { - emake PROCESSORS=$(makeopts_jobs) \ - GPR2KBDIR=/usr/share/gprconfig \ - ENABLE_SHARED=$(usex shared) \ - setup -} - -src_compile() { - emake GPRBUILD_OPTIONS=-v -} - -src_install() { - emake install \ - prefix="${D}"/usr - einstalldocs - - rm "${D}"/usr/bin/gprclean || die - rm "${D}"/usr/bin/gprconfig || die - rm "${D}"/usr/bin/gprinstall || die - rm "${D}"/usr/bin/gprls || die - rm "${D}"/usr/bin/gprname || die -} diff --git a/dev-ada/gpr/gpr-23.0.0-r3.ebuild b/dev-ada/gpr/gpr-23.0.0-r3.ebuild new file mode 100644 index 000000000000..5ac3ae0f761c --- /dev/null +++ b/dev-ada/gpr/gpr-23.0.0-r3.ebuild @@ -0,0 +1,113 @@ +# Copyright 2022-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +ADA_COMPAT=( gnat_2021 gcc_12 ) +PYTHON_COMPAT=( python3_{9,10,11} ) + +inherit python-any-r1 ada multiprocessing + +DESCRIPTION="LibGPR2 - Parser for GPR Project files" +HOMEPAGE="https://github.com/AdaCore/gpr" +SRC_URI="https://github.com/AdaCore/${PN}/archive/refs/tags/v${PV}.tar.gz + -> ${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="+shared static-libs static-pic" +REQUIRED_USE="|| ( shared static-libs static-pic ) + ${ADA_REQUIRED_USE}" + +RDEPEND="${ADA_DEPS} + dev-ada/xmlada[${ADA_USEDEP}] + shared? ( dev-ada/xmlada[shared,static-pic] ) + dev-ada/gnatcoll-core[${ADA_USEDEP}] + shared? ( dev-ada/gnatcoll-core[shared,static-pic] ) + dev-ada/gnatcoll-bindings[${ADA_USEDEP},iconv,gmp] + shared? ( dev-ada/gnatcoll-bindings[shared,static-pic] )" + +DEPEND="${RDEPEND} + dev-ada/gprconfig_kb[${ADA_USEDEP}] + dev-ada/gprbuild[${ADA_USEDEP}]" + +BDEPEND="${PYTHON_DEPS} + $(python_gen_any_dep ' + dev-ada/langkit[${PYTHON_USEDEP}] + ')" + +python_check_deps() { + python_has_version "dev-ada/langkit[${PYTHON_USEDEP}]" +} + +src_configure() { + emake ENABLE_SHARED=$(usex shared) setup +} + +src_compile() { + build() { + gprbuild -p -m -v -j$(makeopts_jobs) -XGPR2_BUILD=release \ + -XLIBRARY_TYPE=$1 -XXMLADA_BUILD=$1 gpr2.gpr || die + } + mkdir -p .build/kb || die + gprbuild -p -P src/kb/collect_kb.gpr -XKB_BUILD_DIR=.build/kb \ + --relocate-build-tree || die + .build/kb/collect_kb -o .build/kb/config.kb /usr/share/gprconfig || die + emake -C langkit setup DEST="${S}/.build/lkparser" + if use shared; then + build relocatable + fi + if use static-libs; then + build static + fi + if use static-pic; then + build static-pic + fi + if use static-libs; then + libtype='static' + elif use static-pic; then + libtype='static-pic' + elif use shared; then + libtype='relocatable' + fi + + gprbuild -p -m -v -j$(makeopts_jobs) -XGPR2_BUILD=release \ + -XLIBRARY_TYPE=${libtype} -XXMLADA_BUILD=${libtype} gpr2-tools.gpr \ + || die + gprbuild -p -m -v -j$(makeopts_jobs) -XGPR2_BUILD=release \ + -XLIBRARY_TYPE=${libtype} -XXMLADA_BUILD=${libtype} \ + -XLANGKIT_SUPPORT_BUILD=${libtype} gpr2-name.gpr || die +} + +src_install() { + build() { + gprinstall -p -f -v -XGPR2_BUILD=release --prefix="${D}/usr" \ + -XLIBRARY_TYPE=$1 -XXMLADA_BUILD=$1 --build-name=$1 \ + --build-var=LIBRARY_TYPE \ + --build-var=GPR2_LIBRARY_TYPE gpr2.gpr || die + } + if use shared; then + build relocatable + fi + if use static-libs; then + build static + fi + if use static-pic; then + build static-pic + fi + gprinstall -p -f -v -XGPR2_BUILD=release --prefix="${D}/usr" \ + -XLIBRARY_TYPE=${libtype} -XXMLADA_BUILD=${libtype} \ + --build-name=${libtype} --mode=usage gpr2-tools.gpr || die + gprinstall -p -f -v -XGPR2_BUILD=release --prefix='${D}/usr' \ + -XLIBRARY_TYPE=${libtype} -XXMLADA_BUILD=${libtype} \ + -XLANGKIT_SUPPORT_BUILD=${libtype} --build-name=${libtype} \ + --mode=usage gpr2-name.gpr || die + + einstalldocs + + rm "${D}"/usr/bin/gprclean || die + rm "${D}"/usr/bin/gprconfig || die + rm "${D}"/usr/bin/gprinstall || die + rm "${D}"/usr/bin/gprls || die +} diff --git a/dev-ada/gpr/metadata.xml b/dev-ada/gpr/metadata.xml index 51966a8cdf1e..3551228a3310 100644 --- a/dev-ada/gpr/metadata.xml +++ b/dev-ada/gpr/metadata.xml @@ -6,6 +6,7 @@ </maintainer> <use> <flag name="shared">Build shared library</flag> + <flag name="static-pic">Build static library with pic code</flag> </use> <upstream> <remote-id type="github">AdaCore/gpr</remote-id> |