diff options
author | Sergei Trofimovich <slyfox@gentoo.org> | 2019-08-11 10:07:15 +0100 |
---|---|---|
committer | Sergei Trofimovich <slyfox@gentoo.org> | 2019-08-11 10:07:15 +0100 |
commit | 1a59549ee5b33d01b739bfc44e9c4463249af2ec (patch) | |
tree | 97efe3fb5495c9d4158e27f79b5fa94ddb21b48c /dev-lang/mujs/mujs-1.0.6.ebuild | |
parent | dev-util/re2c: bump up to 1.2.1 (diff) | |
download | gentoo-1a59549ee5b33d01b739bfc44e9c4463249af2ec.tar.gz gentoo-1a59549ee5b33d01b739bfc44e9c4463249af2ec.tar.bz2 gentoo-1a59549ee5b33d01b739bfc44e9c4463249af2ec.zip |
dev-lang/mujs: bumped up to 1.0.6, added subslot, bug #670106
Added a comment why gentoo adds such a fine-grained SONAME:
library changes ABI (and API) all the time: functions are
added and removed.
Reported-by: Andreas Sturmlechner
Closes: https://bugs.gentoo.org/670106
Package-Manager: Portage-2.3.71, Repoman-2.3.17
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Diffstat (limited to 'dev-lang/mujs/mujs-1.0.6.ebuild')
-rw-r--r-- | dev-lang/mujs/mujs-1.0.6.ebuild | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/dev-lang/mujs/mujs-1.0.6.ebuild b/dev-lang/mujs/mujs-1.0.6.ebuild new file mode 100644 index 000000000000..fdae6f9f0a1b --- /dev/null +++ b/dev-lang/mujs/mujs-1.0.6.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit flag-o-matic toolchain-funcs + +DESCRIPTION="An embeddable Javascript interpreter in C." +HOMEPAGE=" + https://mujs.com/ + https://github.com/ccxvii/mujs/ +" +SRC_URI="https://github.com/ccxvii/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="AGPL-3" +# subslot matches SONAME +SLOT="0/${PV}" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~ppc-macos ~x64-macos ~x86-macos" +IUSE="static-libs" + +RDEPEND="sys-libs/readline:0=" +DEPEND="${RDEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-1.0.5-flags.patch" +) + +src_prepare() { + default + + tc-export AR CC + + # library's ABI (and API) changes in ~each release: + # diff 'usr/includemujs.h' across releases to validate + append-cflags -fPIC -Wl,-soname=lib${PN}.so.${PV} +} + +src_compile() { + emake VERSION=${PV} prefix=/usr shared +} + +src_install() { + local myeconfargs=( + DESTDIR="${ED}" + install-shared + libdir="/usr/$(get_libdir)" + prefix="/usr" + VERSION="${PV}" + $(usex static-libs install-static '') + ) + + emake "${myeconfargs[@]}" + + 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} +} |