summaryrefslogtreecommitdiff
path: root/dev-lang/duktape
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-11-25 22:39:15 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-11-25 22:39:15 +0000
commitd934827bf44b7cfcf6711964418148fa60877668 (patch)
tree0625f358789b5e015e49db139cc1dbc9be00428f /dev-lang/duktape
parent2e34d110f164bf74d55fced27fe0000201b3eec5 (diff)
gentoo resync : 25.11.2020
Diffstat (limited to 'dev-lang/duktape')
-rw-r--r--dev-lang/duktape/Manifest5
-rw-r--r--dev-lang/duktape/duktape-2.5.0-r1.ebuild4
-rw-r--r--dev-lang/duktape/duktape-2.6.0.ebuild51
-rw-r--r--dev-lang/duktape/files/duktape-2.6.0-respect-tc-env.patch33
4 files changed, 90 insertions, 3 deletions
diff --git a/dev-lang/duktape/Manifest b/dev-lang/duktape/Manifest
index e61a38b2f2ea..c7fcb7f58f60 100644
--- a/dev-lang/duktape/Manifest
+++ b/dev-lang/duktape/Manifest
@@ -1,6 +1,9 @@
+AUX duktape-2.6.0-respect-tc-env.patch 1499 BLAKE2B eb400e6c7a1305490682e7e4d5db38491915168497302d0bc4c7c59c9c243130750631cb6097ce7228026fa975f0bcfe107402e00c7c62ef31924d87ecc2774a SHA512 b2b99410c070fc00c0eae2a23007ea6295cb7202adc24df84aec03156bd262f2a459dd1550393197fdd377ab22b84768d6b01bb84785961ee7c81f08559151e9
AUX duktape.pc 218 BLAKE2B 3864f90f3ec1d77733736e16f99c0bab796502d3306759106357cb500d038304dfd6dc9849c9cde2e77683bf1f38dc7707119b39b66a6b55961b802e8d679520 SHA512 0f4b4e20ea9b348ed8b69623ed4fa09c20a2a951ef4f281b6313961c4aa085be9fc511a948d67713a7d2d9dede984761d5409b25e09da1db10698eb615f7c6fb
DIST duktape-2.4.0.tar.xz 1027744 BLAKE2B 9fb74b0586a5ccf5ef80d69955ab0ddb94428d463e300a558b5ab6e279d2c416b794434466604caa80581883df85f889694af1dd3ea0aaa4a3d53babb855f3ef SHA512 be6b7c73ae7c3419e8ced375fcff9680946e780b71d30e3be4e4e3b4b3a2710aa8f86530081c64958507a11fc215cacc5409c7d3a1d30b757838a00c748fa281
DIST duktape-2.5.0.tar.xz 1031188 BLAKE2B 15d9190e9c723bacf8249ea31bf528793ca06e86d2697648192fee50b4ba2f7cf091e1392ac14a7a5c35b05a3ff5f200e0318cc8a4b873ad26f0c97683a2cb72 SHA512 230e298a91cb48407d7c2a4b7c85cf9d53151d550e2fd7ba6cb8f9115682abce295fb78a3c3cd22b4812ce86944dd6d28c2b25c3845668a17232e3a08ea63837
+DIST duktape-2.6.0.tar.xz 1035160 BLAKE2B 98155e1bf7e76aab37f5ccdb951d9d456df3d984ebed5058d8931e25317ffd94b4d95f08e102eb6eb2fa36ab6d2d60be6072b4101b7754e1c1440f7d6fb2c91b SHA512 d72a2aaa05391fa243861aca6ca6082f91a08b9c5d60c7b246d35d7161532b0048bb67bd8fec7996c700ee317ac2bb52e528582682e5425b0431757d8b1c5be4
EBUILD duktape-2.4.0.ebuild 984 BLAKE2B 639c3dbdb610048fc33134671a428deca1fe106f5f54cc7baee3d21b921265c63e168208501e6aaea0f91a578f2d33dd5b110d14f25a7d198542be944346a957 SHA512 7bcadb6b1e5a246bf2b62b3f3ccb7dfc50e9232508d86fbef1481b8b08fdd1b810e5010eff72fb8f88eb590f39ba711294bbd1b9207eeeb524032a57fb10170e
-EBUILD duktape-2.5.0-r1.ebuild 1072 BLAKE2B 2fe675e7e0de23c08fd446a8b00a2931cdc6d10d68b34c3b852e77e99cb8a70d9a826b31f054c83ade6cd22b6c55aed4312ea95a5af5f30e4d7d6670037bdf77 SHA512 3c1d0cbee75fe2cba9b814b0b33f6a9d5e46d4cef14f4985cc5a6ed8201ac7f5bbfd91d71f28eab725219d17ae9d30a92514fd12a326747119dbb532bc464b8f
+EBUILD duktape-2.5.0-r1.ebuild 1070 BLAKE2B 32767172e822423930b4bdfd536e5219039d3aab8edd7238a5da030e3e9932733a9b11a0e060180240c2cd82bc9520bd87be705ab6593dfbb56842b6310e2760 SHA512 e6c0e7e07ad49e8dd507cf41cfcc2986847df6d111f2db25fc2b8485f76daa38d4aad3776eb12d4fd2ec2d4c0b8505dc621fba340b1d8badd285a85b23759ec9
+EBUILD duktape-2.6.0.ebuild 1194 BLAKE2B 00c8239847f63013031cf86846f3fb0d48b8e3c7d83aa5cc1c8ab7c60863d0a9754fb2f3ac21e11e53e8f147bb8972dcd82c99db62af71774b0ddc6bb5a49440 SHA512 5a76c71249ea43a7d6cab0d84abbdf8952f5b6b17d8ff60f15d0fec47e997fe1362e2616b77ee58df22b6a37feb04e527a2164e61eddbca9ef86a69ade2fd0ff
MISC metadata.xml 337 BLAKE2B cccca86d6da0b932668171e11dcee8ae4e2261c9d701a56aa1e6edae82223f23616ecc71df2686df63fe36c11a3d9918f53621df798afca36907b0561c537f78 SHA512 31661ed6f1e4d86566e596bcf2f26bd8daf967b609fda7101abba3c4186246a3e952bb71c9d5e71ff3b2692bc9d016d96282387268e9a06231e22ce4bd5afa9d
diff --git a/dev-lang/duktape/duktape-2.5.0-r1.ebuild b/dev-lang/duktape/duktape-2.5.0-r1.ebuild
index b682d6b186fc..3f817f751d2b 100644
--- a/dev-lang/duktape/duktape-2.5.0-r1.ebuild
+++ b/dev-lang/duktape/duktape-2.5.0-r1.ebuild
@@ -11,7 +11,7 @@ SRC_URI="https://duktape.org/${P}.tar.xz"
LICENSE="MIT"
SLOT="0"
-KEYWORDS="amd64 ~arm ~arm64 ~ppc ~ppc64 x86"
+KEYWORDS="amd64 ~arm ~arm64 ppc ~ppc64 x86"
IUSE=""
DEPEND=""
@@ -21,7 +21,7 @@ src_prepare() {
eapply_user
# Set install path
- sed -i "s#INSTALL_PREFIX = /usr/local#INSTALL_PREFIX = ${D%/}/usr#" \
+ sed -i "s#INSTALL_PREFIX = /usr/local#INSTALL_PREFIX = ${ED}/usr#" \
Makefile.sharedlibrary || die "failed to set install path"
# Edit pkgconfig
diff --git a/dev-lang/duktape/duktape-2.6.0.ebuild b/dev-lang/duktape/duktape-2.6.0.ebuild
new file mode 100644
index 000000000000..1037f1a821ba
--- /dev/null
+++ b/dev-lang/duktape/duktape-2.6.0.ebuild
@@ -0,0 +1,51 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+DESCRIPTION="Embeddable Javascript engine"
+HOMEPAGE="https://duktape.org"
+SRC_URI="https://duktape.org/${P}.tar.xz"
+
+LICENSE="MIT"
+# Upstream don't maintain binary compatibility
+# https://github.com/svaarala/duktape/issues/1524
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-2.6.0-respect-tc-env.patch"
+)
+
+src_prepare() {
+ default
+
+ # Set install path
+ sed -i "s#INSTALL_PREFIX = /usr/local#INSTALL_PREFIX = ${ED}/usr#" \
+ Makefile.sharedlibrary || die "failed to set install path"
+
+ # Edit pkgconfig
+ sed "s#VERSION#${PV}#" "${FILESDIR}/${PN}.pc" > "${S}/${PN}.pc" || die
+ sed -i "s#LIBDIR#$(get_libdir)#" "${S}/${PN}.pc" || die
+
+ # Set lib folder
+ sed -i "s#(INSTALL_PREFIX)/lib#(INSTALL_PREFIX)/$(get_libdir)#" \
+ Makefile.sharedlibrary || die
+
+ mv Makefile.sharedlibrary Makefile || die "failed to rename makefile"
+}
+
+src_compile() {
+ emake CC="$(tc-getCC)"
+}
+
+src_install() {
+ dodir /usr/$(get_libdir)
+ dodir /usr/include
+ emake install
+
+ insinto /usr/$(get_libdir)/pkgconfig/
+ doins "${S}/${PN}.pc"
+}
diff --git a/dev-lang/duktape/files/duktape-2.6.0-respect-tc-env.patch b/dev-lang/duktape/files/duktape-2.6.0-respect-tc-env.patch
new file mode 100644
index 000000000000..cb92d0ab8d30
--- /dev/null
+++ b/dev-lang/duktape/files/duktape-2.6.0-respect-tc-env.patch
@@ -0,0 +1,33 @@
+diff --git a/Makefile.sharedlibrary b/Makefile.sharedlibrary
+index 156ea96..a0997b1 100644
+--- a/Makefile.sharedlibrary
++++ b/Makefile.sharedlibrary
+@@ -52,7 +52,7 @@ INSTALL_PREFIX = /usr/local
+ DUKTAPE_SRCDIR = ./src
+ #DUKTAPE_SRCDIR = ./src-noline
+
+-CC = gcc
++CC ?= gcc
+
+ .PHONY: all
+ all: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX)
+@@ -62,11 +62,11 @@ all: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX)
+ # to $INSTALL_PREFIX/include on installation.
+
+ libduktape.$(SO_REALNAME_SUFFIX):
+- $(CC) -shared -fPIC -Wall -Wextra -Os -Wl,$(LD_SONAME_ARG),libduktape.$(SO_SONAME_SUFFIX) \
++ $(CC) -shared -fPIC ${CFLAGS} ${LDFLAGS} -Wl,$(LD_SONAME_ARG),libduktape.$(SO_SONAME_SUFFIX) -lm \
+ -o $@ $(DUKTAPE_SRCDIR)/duktape.c
+
+ libduktaped.$(SO_REALNAME_SUFFIX):
+- $(CC) -shared -fPIC -g -Wall -Wextra -Os -Wl,$(LD_SONAME_ARG),libduktaped.$(SO_SONAME_SUFFIX) \
++ $(CC) -shared -fPIC ${CFLAGS} ${LDFLAGS} -Wl,$(LD_SONAME_ARG),libduktaped.$(SO_SONAME_SUFFIX) -lm \
+ -o $@ $(DUKTAPE_SRCDIR)/duktape.c
+
+ # Symlinks depend on platform conventions.
+@@ -85,4 +85,4 @@ install: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX)
+
+ CCOPTS = -I./examples/cmdline
+ duk:
+- $(CC) $(CCOPTS) -I$(INSTALL_PREFIX)/include -L$(INSTALL_PREFIX)/lib -Wall -Wextra -Os -o $@ ./examples/cmdline/duk_cmdline.c -lduktape -lm
++ $(CC) $(CCOPTS) -I$(INSTALL_PREFIX)/include -L$(INSTALL_PREFIX)/lib ${CFLAGS} -o $@ ./examples/cmdline/duk_cmdline.c -lduktape -lm