* [gentoo-commits] repo/user/dlang:master commit in: dev-util/gdmd/
@ 2024-06-02 5:29 Horodniceanu Andrei
0 siblings, 0 replies; 2+ messages in thread
From: Horodniceanu Andrei @ 2024-06-02 5:29 UTC (permalink / raw
To: gentoo-commits
commit: 35c179492506ae06f74e9213dbebc403ca57c690
Author: Andrei Horodniceanu <a.horodniceanu <AT> proton <DOT> me>
AuthorDate: Sat Jun 1 11:24:53 2024 +0000
Commit: Horodniceanu Andrei <a.horodniceanu <AT> proton <DOT> me>
CommitDate: Sat Jun 1 16:54:01 2024 +0000
URL: https://gitweb.gentoo.org/repo/user/dlang.git/commit/?id=35c17949
dev-util/gdmd: add 14
Additionally:
- use symlinks instead of hardlinks for gdmd -> ${CHOST}-gdmd
- call gcc-config in pkg_postinst if the selected configuration matches
this package's SLOT. This creates a symlink under /usr/bin which is
required for rdmd from dev-util/dlang-tools to find the default compiler.
- restrict tests as there aren't any.
Signed-off-by: Andrei Horodniceanu <a.horodniceanu <AT> proton.me>
dev-util/gdmd/gdmd-14.ebuild | 62 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 62 insertions(+)
diff --git a/dev-util/gdmd/gdmd-14.ebuild b/dev-util/gdmd/gdmd-14.ebuild
new file mode 100644
index 0000000..fc256ad
--- /dev/null
+++ b/dev-util/gdmd/gdmd-14.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DESCRIPTION="Wrapper script for gdc that emulates the dmd command"
+HOMEPAGE="https://www.gdcproject.org/"
+
+RELEASE="0.1.0"
+SRC_URI="https://codeload.github.com/D-Programming-GDC/gdmd/tar.gz/script-${RELEASE} -> gdmd-${RELEASE}.tar.gz"
+S="${WORKDIR}/gdmd-script-${RELEASE}"
+LICENSE="GPL-3+"
+
+SLOT="${PV}"
+KEYWORDS="~amd64 ~arm64 ~x86"
+RESTRICT="test" # no tests
+
+RDEPEND="sys-devel/gcc:${PV}[d]"
+
+PATCHES="${FILESDIR}/${PN}-no-dmd-conf.patch"
+
+src_compile() {
+ :
+}
+
+src_install() {
+ local binPath="/usr/${CHOST}/gcc-bin/${PV}"
+ exeinto "${binPath}"
+ newexe dmd-script "${CHOST}-gdmd"
+ dosym "${CHOST}-gdmd" "${binPath}/gdmd"
+}
+
+pkg_postinst() {
+ maybe_update_gcc_config
+}
+
+# We can't really call gcc-config in postrm since it won't know which
+# symlinks under /usr/bin were left by us. If it turns out to be a
+# problem we could try to remove the symlink manually.
+
+maybe_update_gcc_config() {
+ # Call gcc-config if the current configuration if for the same slot
+ # we are installing to. This is needed to make gdmd available in
+ # $PATH.
+
+ local CTARGET=${CTARGET:-${CHOST}}
+
+ # Logic taken from toolchain.eclass and simplified a little
+ local curr_config
+ curr_config=$(gcc-config -c ${CTARGET} 2>&1) || return 0
+
+ local curr_config_ver=$(gcc-config -S ${curr_config} | awk '{print $2}')
+ local curr_specs=$(gcc-config -S ${curr_config} | awk '{print $3}')
+
+ if [[ ${curr_config_ver} == ${SLOT} && ! ${curr_specs} ]]; then
+ # We should call gcc-config to make sure the addition of gdmd is
+ # propagated in $PATH. Don't do anything if not on a traditional
+ # layout, the risk of breaking something outweights having the
+ # script in $PATH.
+ gcc-config "${CTARGET}-${SLOT}"
+ fi
+}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/user/dlang:master commit in: dev-util/gdmd/
@ 2024-07-14 19:44 Horodniceanu Andrei
0 siblings, 0 replies; 2+ messages in thread
From: Horodniceanu Andrei @ 2024-07-14 19:44 UTC (permalink / raw
To: gentoo-commits
commit: a6a1eab72c6dff8fabf458235967ba4971b5ccca
Author: Andrei Horodniceanu <a.horodniceanu <AT> proton <DOT> me>
AuthorDate: Sun Jul 14 16:10:49 2024 +0000
Commit: Horodniceanu Andrei <a.horodniceanu <AT> proton <DOT> me>
CommitDate: Sun Jul 14 16:36:03 2024 +0000
URL: https://gitweb.gentoo.org/repo/user/dlang.git/commit/?id=a6a1eab7
dev-util/gdmd: unkeyword 11 for ppc64
Follow up the <sys-devel/gcc-12 package.mask for the ppc64le profile.
This makes pkgcheck happy again.
Signed-off-by: Andrei Horodniceanu <a.horodniceanu <AT> proton.me>
dev-util/gdmd/gdmd-11.ebuild | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dev-util/gdmd/gdmd-11.ebuild b/dev-util/gdmd/gdmd-11.ebuild
index 8943312..ae3142e 100644
--- a/dev-util/gdmd/gdmd-11.ebuild
+++ b/dev-util/gdmd/gdmd-11.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -8,7 +8,7 @@ HOMEPAGE="https://www.gdcproject.org/"
LICENSE="GPL-3+"
SLOT="${PV}"
-KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 x86"
+KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~m68k ~mips ppc ~riscv ~s390 x86"
RDEPEND="sys-devel/gcc:${PV}[d]"
RELEASE="0.1.0"
SRC_URI="https://codeload.github.com/D-Programming-GDC/gdmd/tar.gz/script-${RELEASE} -> gdmd-${RELEASE}.tar.gz"
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-07-14 19:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-02 5:29 [gentoo-commits] repo/user/dlang:master commit in: dev-util/gdmd/ Horodniceanu Andrei
-- strict thread matches above, loose matches on Subject: below --
2024-07-14 19:44 Horodniceanu Andrei
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox