summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Rösner <rndxelement@protonmail.com>2021-12-16 22:35:56 +0100
committerSam James <sam@gentoo.org>2021-12-17 00:39:19 +0000
commit591f8c384c0d6791591c430b900f89575991a713 (patch)
treeb6d7456c7917c3a55847719aefe43459fb5f53f7 /dev-lang
parentdune.eclass: fix default value of DUNE_PKG_NAME (diff)
downloadgentoo-591f8c384c0d6791591c430b900f89575991a713.tar.gz
gentoo-591f8c384c0d6791591c430b900f89575991a713.tar.bz2
gentoo-591f8c384c0d6791591c430b900f89575991a713.zip
dev-lang/mujs: bump to 1.2.0
Added an ebuild for mujs 1.2.0 with support for EAPI 8. Also improved readability and fixed typos. Furthermore, added myself as maintainer. Closes: https://bugs.gentoo.org/829300 Package-Manager: Portage-3.0.28, Repoman-3.0.3 Signed-off-by: Philipp Roesner <rndxelement@protonmail.com> Closes: https://github.com/gentoo/gentoo/pull/23350 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/mujs/Manifest1
-rw-r--r--dev-lang/mujs/metadata.xml10
-rw-r--r--dev-lang/mujs/mujs-1.2.0.ebuild68
3 files changed, 76 insertions, 3 deletions
diff --git a/dev-lang/mujs/Manifest b/dev-lang/mujs/Manifest
index 4295a792c829..cc8ac7a4b2bf 100644
--- a/dev-lang/mujs/Manifest
+++ b/dev-lang/mujs/Manifest
@@ -1,3 +1,4 @@
DIST mujs-1.1.0.tar.gz 123450 BLAKE2B e7bc05d35566ff26346e713645e0f417a9acd1a73b5fb5c7f0c35bf940765fba1ab04199f4ed1dd6ce0e3bb2bf1547703335a1c125353da24de72f2b1adfb243 SHA512 10b61453f8483e3e67c95a742aa7868e255816b2ce25c84d8e24c5c737bad1f23ade67531c5c5bb914804be446da33c0cbe8e95a6d5889250dd8520ce56f23a0
DIST mujs-1.1.2.tar.xz 98340 BLAKE2B bbb290786c26fd604082eb123adc78a3b7d9387dafabf70df23bae97d016a3ad16a434fb1ab3a33da85c575cf813491d0a09d956ff351bd7c8d38cac675ec114 SHA512 66641855e6fe732541fb80a99fda4418545183965c6a6ffb4a05101084fd1cc073aca1e51115f37fffb56bc5518cec21a1586d0745c55aec08deb47736e33392
DIST mujs-1.1.3.tar.xz 98332 BLAKE2B 4dc2c0e657d7dcbbd7f82765556e75e7992cdcaf15c7986bb76c0fb6c244057ba0771a2a59c246eaf7bb9ff080e8af6ade8ef9a95606dc8ebde99f7d73c245c1 SHA512 6a8d0650f1924b5889039ddd8529438226677c63f9317b980492fac4e8380385d5c33fe8a315f26ebd0f7ae94c6c3bc90fdb75a8e4a0df367e6e4e355692e890
+DIST mujs-1.2.0.tar.xz 99108 BLAKE2B 3661fb56a3c316f529251e93b50e18ae1835077af10d5fb636e92e77a766fb63410af0f61ffca6e6c12d6c5c984548d4e36ccee03ead44835493c0c28ef610a9 SHA512 04cc246091bf878aadfa2382ef46c8c42cd04924d9459558016f27474ae3ebca7fc7a0fda7b4efee1bd668b8b051030a2e1f9f40722cb547700c7f84857f4071
diff --git a/dev-lang/mujs/metadata.xml b/dev-lang/mujs/metadata.xml
index ae5c7e5450f5..6ac2a7946bf4 100644
--- a/dev-lang/mujs/metadata.xml
+++ b/dev-lang/mujs/metadata.xml
@@ -1,9 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
- <maintainer type="person">
- <email>sam@gentoo.org</email>
- <name>Sam James</name>
+ <maintainer type="person" proxied="yes">
+ <email>rndxelement@protonmail.com</email>
+ <name>Philipp Rösner</name>
+ </maintainer>
+ <maintainer type="project" proxied="proxy">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
</maintainer>
<longdescription>
MuJS is a lightweight Javascript interpreter designed for embedding in
diff --git a/dev-lang/mujs/mujs-1.2.0.ebuild b/dev-lang/mujs/mujs-1.2.0.ebuild
new file mode 100644
index 000000000000..e25bff9dec49
--- /dev/null
+++ b/dev-lang/mujs/mujs-1.2.0.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit flag-o-matic toolchain-funcs
+
+DESCRIPTION="An embeddable JavaScript interpreter written in C"
+HOMEPAGE="https://mujs.com/ https://github.com/ccxvii/mujs"
+SRC_URI="https://mujs.com/downloads/${P}.tar.xz"
+
+LICENSE="ISC"
+# The subslot matches the SONAME
+SLOT="0/${PV}"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~ppc-macos ~x64-macos"
+
+RDEPEND="sys-libs/readline:="
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.1.1-flags.patch
+)
+
+src_prepare() {
+ default
+
+ tc-export AR CC
+
+ append-cflags -fPIC
+
+ # The library's ABI (and API) might change in new releases
+ # Diff 'usr/include/mujs.h' across releases to validate
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ append-cflags -Wl,-install_name,"${EPREFIX}"/usr/$(get_libdir)/lib${PN}.${PV}.dylib
+ else
+ append-cflags -Wl,-soname=lib${PN}.so.${PV}
+ fi
+}
+
+src_compile() {
+ # We need to use ${PV} for the pkgconfig file, see: #784461
+ emake \
+ VERSION=${PV} \
+ XCFLAGS="${CFLAGS}" \
+ XCPPFLAGS="${CPPFLAGS}" \
+ prefix=/usr \
+ shell shared
+}
+
+src_install() {
+ emake \
+ DESTDIR="${ED}" \
+ VERSION=${PV} \
+ libdir="/usr/$(get_libdir)" \
+ prefix=/usr \
+ install-shared
+
+ # TODO: Tidy up this logic, improve readability
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ mv -v "${ED}"/usr/$(get_libdir)/lib${PN}.so "${ED}"/usr/$(get_libdir)/lib${PN}.${PV}.dylib || die
+ dosym lib${PN}.${PV}.dylib /usr/$(get_libdir)/lib${PN}.dylib
+ dosym lib${PN}.${PV}.dylib /usr/$(get_libdir)/lib${PN}.${PV:0:1}.dylib
+ else
+ mv -v "${ED}"/usr/$(get_libdir)/lib${PN}.so{,.${PV}} || die
+ dosym lib${PN}.so.${PV} /usr/$(get_libdir)/lib${PN}.so
+ dosym lib${PN}.so.${PV} /usr/$(get_libdir)/lib${PN}.so.${PV:0:1}
+ fi
+}