diff options
author | Andrei Horodniceanu <a.horodniceanu@proton.me> | 2024-09-12 15:49:58 +0300 |
---|---|---|
committer | Andrei Horodniceanu <a.horodniceanu@proton.me> | 2024-09-12 20:11:45 +0300 |
commit | fd6defc33f472265c28cf6bce66763ff45ffbed1 (patch) | |
tree | 0a39c7ec727d1aa143eb6ceff9042f6d740af65c /dev-lang | |
parent | x11-terms/tilix: enable dmd-2_109 and ldc2-1_39 (diff) | |
download | dlang-fd6defc33f472265c28cf6bce66763ff45ffbed1.tar.gz dlang-fd6defc33f472265c28cf6bce66763ff45ffbed1.tar.bz2 dlang-fd6defc33f472265c28cf6bce66763ff45ffbed1.zip |
dev-lang/ldc2: 1.39.0 use external patches
Signed-off-by: Andrei Horodniceanu <a.horodniceanu@proton.me>
Diffstat (limited to 'dev-lang')
-rw-r--r-- | dev-lang/ldc2/Manifest | 1 | ||||
-rw-r--r-- | dev-lang/ldc2/ldc2-1.39.0.ebuild | 29 |
2 files changed, 21 insertions, 9 deletions
diff --git a/dev-lang/ldc2/Manifest b/dev-lang/ldc2/Manifest index 6d39aef..31f9fe6 100644 --- a/dev-lang/ldc2/Manifest +++ b/dev-lang/ldc2/Manifest @@ -6,3 +6,4 @@ DIST ldc-1.36.0-src.tar.gz 8551871 BLAKE2B b0f09128ab37e332f2eebab3288cac687f91b DIST ldc-1.37.0-src.tar.gz 8555980 BLAKE2B ac93c903f9dbeec5b69e94c7cdf851ae3fa3168752dceccbd1262fbdae5cdda43e53b82bd7c8b24b0bb2dc06fb00f3b1c74a278a851ea68b948dc7e618460227 SHA512 488451dba58262cf533760f471f707f984d66edeb5c7dfff5a512efa0111742cead4ff23ed5ace39ea4d07e9bac290a846d0df3de49fd3fc276241a771aff0ed DIST ldc-1.38.0-src.tar.gz 8691096 BLAKE2B 7b25ba96c470a707d9ee7660ac030984c2cfecaf757a00015507dfb7c17075132ebcc546562ae700ab43eb19e117b4d1247cc1b2f62f455328a7cf9dc0ddf5d4 SHA512 1540a1a6f4bad3bc93da0f59bc28cd31dd4aeb58b8b4c744a204faa43692a1fe13d010ae56b3369e870a5e58724103b2aee58db8b40925698e7816f78f0f2de3 DIST ldc-1.39.0-src.tar.gz 8554301 BLAKE2B cb1dd5f6b4cc7a7344d8575d1e96fddbd1c34fc0e4f05cf96d29179bec725a997d7d8aee7bf0d97e53d0b36fb108f56e1c55eb66aa93e0075d1beb9d737e21e5 SHA512 d5c91043fa7d5faee9fc231fade52b6ac961907a7f6f8920d8337c9ba0b7052a5f98eb5f23ae56ca93510952c502ca78c9eec1d03f408aaa310fa4e4d57d9519 +DIST ldc2-1.39.0-patches-1.tar.gz 1176 BLAKE2B 7597fb1917f53ee5ee215cba73b92acf1d8347851d0d71223e5c01421da7ee6fd909ed7da217c99b162f3ca1602cdcddaf680ad13094db8957e98c635c72ecd1 SHA512 f78ddf97bb4ef0167328e1f58a3da7a35ec4a879a6c772f002dc161814bc9ac94b0ff543d3faf533375e0f5a9124a80c44b2371415810f0751617c2f13d56659 diff --git a/dev-lang/ldc2/ldc2-1.39.0.ebuild b/dev-lang/ldc2/ldc2-1.39.0.ebuild index 6ddfbce..b1630ae 100644 --- a/dev-lang/ldc2/ldc2-1.39.0.ebuild +++ b/dev-lang/ldc2/ldc2-1.39.0.ebuild @@ -8,11 +8,18 @@ LLVM_COMPAT=( {15..18} ) PYTHON_COMPAT=( python3_{10..12} ) inherit cmake llvm-r1 multilib-build multiprocessing python-any-r1 toolchain-funcs +PATCH_VER=1 +PATCH_TAG_NAME="${PV}-patches-${PATCH_VER}" +PATCH_URL_BASE="https://github.com/the-horo/ldc-patches/archive/refs/tags" + DESCRIPTION="LLVM D Compiler" HOMEPAGE="https://github.com/ldc-developers/ldc" MY_PV="${PV//_/-}" MY_P="ldc-${MY_PV}-src" -SRC_URI="https://github.com/ldc-developers/ldc/releases/download/v${MY_PV}/${MY_P}.tar.gz" +SRC_URI=" + https://github.com/ldc-developers/ldc/releases/download/v${MY_PV}/${MY_P}.tar.gz + ${PATCH_URL_BASE}/${PATCH_TAG_NAME}.tar.gz -> ${P}-patches-${PATCH_VER}.tar.gz +" S=${WORKDIR}/${MY_P} LICENSE="BSD" # dmd code + runtime lib, see dmd-r1.eclass for more details @@ -60,14 +67,6 @@ python_check_deps() { python_has_version "dev-python/lit[${PYTHON_USEDEP}]" } -PATCHES=( - "${FILESDIR}"/ldc2-1.15.0-link-defaultlib-shared.patch - "${FILESDIR}/${PN}"-1.36.0-lit-cfg-disable-gdb.patch - - # https://github.com/ldc-developers/ldc/issues/4614#issuecomment-2034169152 - "${FILESDIR}/${PN}"-remove-dmd-common-int128-unittest.patch -) - pkg_setup() { dlang_setup llvm-r1_pkg_setup @@ -75,6 +74,8 @@ pkg_setup() { } src_prepare(){ + apply_patches + # Disable GDB tests by passing GDB_FLAGS=OFF # Put this here to avoid trigerring reconfigurations later on. sed -i 's/\(GDB_FLAGS=\)\S\+/\1OFF/' "${S}"/tests/dmd/CMakeLists.txt @@ -179,3 +180,13 @@ pkg_postinst() { pkg_postrm() { "${EROOT}"/usr/bin/eselect dlang update ldc2 } + +apply_patches() { + local patches_dir="${WORKDIR}/ldc-patches-${PATCH_TAG_NAME}" + local patch + while read -rd '' patch; do + eapply "${patch}" + done < <(find "${patches_dir}" -mindepth 1 -maxdepth 1 \ + -type f -name '*.patch' \ + -print0) +} |