diff options
author | Alfredo Tupone <tupone@gentoo.org> | 2024-03-17 22:25:57 +0100 |
---|---|---|
committer | Alfredo Tupone <tupone@gentoo.org> | 2024-03-17 22:26:10 +0100 |
commit | a059a23f2c8f104f2d3f3f824ebf83b30ec0e434 (patch) | |
tree | 8a8d30336d2c5493bffaec7d718eb0ec907562fe /dev-ada/libadalang | |
parent | app-misc/tmuxp: add 1.43.0, drop 1.42.0 (diff) | |
download | gentoo-a059a23f2c8f104f2d3f3f824ebf83b30ec0e434.tar.gz gentoo-a059a23f2c8f104f2d3f3f824ebf83b30ec0e434.tar.bz2 gentoo-a059a23f2c8f104f2d3f3f824ebf83b30ec0e434.zip |
dev-ada/libadalang: add 24.0.0
Signed-off-by: Alfredo Tupone <tupone@gentoo.org>
Diffstat (limited to 'dev-ada/libadalang')
-rw-r--r-- | dev-ada/libadalang/Manifest | 1 | ||||
-rw-r--r-- | dev-ada/libadalang/libadalang-24.0.0.ebuild | 110 |
2 files changed, 111 insertions, 0 deletions
diff --git a/dev-ada/libadalang/Manifest b/dev-ada/libadalang/Manifest index 1bbb55f0ff69..04ebe7a163b8 100644 --- a/dev-ada/libadalang/Manifest +++ b/dev-ada/libadalang/Manifest @@ -1 +1,2 @@ DIST libadalang-23.0.0.tar.gz 2604724 BLAKE2B 0e415c92fdd150e19288cee87a011c448962531b629b7f77be3b22a7e6662017a6cfd5132a5895c68ffee4b28b7ac35e4b5abc07f015a84638ecb1843976e3e5 SHA512 ed80d751d3a2e07b0d612bda24c0f1d753d15237cde3d9e3bbb6c79c8c98d6af050151c499d161e619282ed8cb742968bbfb5423008aa593a6673fcf0375c7d3 +DIST libadalang-24.0.0.tar.gz 2783238 BLAKE2B 6d3b3df1dbb645ea8cba8f8088c7cdd40e9114ce2a5100bf93fefe8089d944f185fe343f5fefc35e17f64f5bf4f3dde358a398614db7d1a1b62dd136efdbb334 SHA512 fb2ed8aee075ef5dd66527a099acb5eef9103a8bf244ed437ff9fa38360d7de1712e6375ed98b691a745fa27ef841eb5daa6651641c552c5146986c5ed977131 diff --git a/dev-ada/libadalang/libadalang-24.0.0.ebuild b/dev-ada/libadalang/libadalang-24.0.0.ebuild new file mode 100644 index 000000000000..9635eb6d6899 --- /dev/null +++ b/dev-ada/libadalang/libadalang-24.0.0.ebuild @@ -0,0 +1,110 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +ADA_COMPAT=( gnat_2021 gcc_12 gcc_13 ) + +inherit ada python-single-r1 multiprocessing + +DESCRIPTION="high performance semantic engine for the Ada programming language" +HOMEPAGE="https://libre.adacore.com/" +SRC_URI="https://github.com/AdaCore/${PN}/archive/refs/tags/v${PV}.tar.gz + -> ${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~x86" +IUSE="test +static-libs static-pic" +REQUIRED_USE="${PYTHON_REQUIRED_USE} + ${ADA_REQUIRED_USE}" +# Need java +RESTRICT="test" + +RDEPEND="dev-python/pyyaml + dev-ada/gnatcoll-bindings[${ADA_USEDEP},gmp,iconv] + dev-ada/gnatcoll-bindings[shared,static-libs?,static-pic?] + ${ADA_DEPS} + ${PYTHON_DEPS} + >=dev-ada/gpr-24.0.0[${ADA_USEDEP},shared,static-libs?,static-pic?] + >=dev-ada/langkit-24.0.0[${ADA_USEDEP},shared,static-libs?,static-pic?] + $(python_gen_cond_dep ' + dev-ada/langkit[${PYTHON_USEDEP}] + ')" +DEPEND="${RDEPEND} + dev-ada/gprbuild[${ADA_USEDEP}] +" +BDEPEND="test? ( + dev-ml/dune + dev-ml/zarith + dev-ml/camomile + dev-ml/ocaml-ctypes + dev-ada/e3-testsuite + <dev-lang/ocaml-4.14 + )" + +PATCHES=( "${FILESDIR}"/${PN}-23.0.0-test.patch ) + +pkg_setup() { + python-single-r1_pkg_setup + ada_pkg_setup + libType='' + if use static-libs; then + libType+=',static' + fi + if use static-pic; then + libType+=',static-pic' + fi + libType+=',relocatable' + libType=${libType:1} +} + +src_prepare() { + default + rm -r testsuite/tests/misc/copyright || die + rm -r testsuite/tests/name_resolution/field_hiding_2 || die + rm -r testsuite/tests/ocaml_api/auto_provider || die + rm -r testsuite/tests/ocaml_api/project_unit_provider || die +} + +src_configure() { + ${EPYTHON} manage.py generate -v debug || die +} + +src_compile() { + ${EPYTHON} manage.py build -v \ + --build-mode "prod" \ + -j$(makeopts_jobs) \ + --disable-java \ + --gargs "-cargs:C ${CFLAGS} -cargs:Ada ${ADAFLAGS} -largs ${LDFLAGS}" \ + --library-types=${libType} || die + GPR_PROJECT_PATH="${S}"/build \ + gprbuild -P contrib/highlight/highlight.gpr \ + -j$(makeopts_jobs) -v \ + -XBUILD_MODE=prod \ + -XLIBRARY_TYPE=relocatable \ + -XXMLADA_BUILD=relocatable \ + -cargs:C ${CFLAGS} -cargs:Ada ${ADAFLAGS} \ + -largs ${LDFLAGS} \ + || die +} + +src_test() { + BUILD_MODE=prod \ + ${EPYTHON} manage.py test \ + --build-mode "prod" \ + --restricted-env -j 1 \ + |& tee libadalang.testOut + grep -qw FAIL libadalang.testOut && die +} + +src_install() { + ${EPYTHON} manage.py \ + install "${D}"/usr \ + --build-mode "prod" \ + --library-types=${libType} || die + rm -r "${D}"/usr/python || die + python_domodule build/python/libadalang + rm -r "${D}"/usr/ocaml || die +} |