[packages/duktape] up to 2.7.0 (new soname)

atler atler at pld-linux.org
Wed May 4 12:12:23 CEST 2022


commit 4156923fda14803e4817034242bcb30e49f8a30f
Author: Jan Palus <jpalus at fastmail.com>
Date:   Wed May 4 12:10:02 2022 +0200

    up to 2.7.0 (new soname)

 duktape-build.patch | 64 +++++++++++++++++++----------------------------------
 duktape.spec        | 15 ++++++++-----
 2 files changed, 32 insertions(+), 47 deletions(-)
---
diff --git a/duktape.spec b/duktape.spec
index 7504fa7..91e6aa7 100644
--- a/duktape.spec
+++ b/duktape.spec
@@ -1,11 +1,11 @@
 Summary:	Embeddable Javascript engine with a focus on portability and compact footprint
 Name:		duktape
-Version:	2.6.0
+Version:	2.7.0
 Release:	1
 License:	MIT
 Group:		Libraries
 Source0:	https://duktape.org/%{name}-%{version}.tar.xz
-# Source0-md5:	01ee8ecf3dd5c6504543c8679661bb20
+# Source0-md5:	b3200b02ab80125b694bae887d7c1ca6
 Patch0:		%{name}-build.patch
 URL:		https://duktape.org/
 BuildRequires:	tar >= 1:1.22
@@ -58,15 +58,17 @@ Pliki nagłówkowe biblioteki %{name}.
 %{__make} -f Makefile.sharedlibrary \
 	CC="%{__cc}" \
 	CFLAGS="%{rpmcppflags} %{rpmcflags}" \
-	LDFLAGS="%{rpmldflags}"
+	LDFLAGS="%{rpmldflags}" \
+	INSTALL_PREFIX=%{_prefix} \
+	LIBDIR="/%{_lib}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 %{__make} -f Makefile.sharedlibrary install \
 	DESTDIR=$RPM_BUILD_ROOT \
-	LIBDIR=%{_libdir} \
-	INCLUDEDIR=%{_includedir}
+	INSTALL_PREFIX=%{_prefix} \
+	LIBDIR="/%{_lib}"
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -78,10 +80,11 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %doc AUTHORS.rst README.rst
 %attr(755,root,root) %{_libdir}/libduktape.so.*.*
-%attr(755,root,root) %ghost %{_libdir}/libduktape.so.206
+%attr(755,root,root) %ghost %{_libdir}/libduktape.so.207
 
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libduktape.so
 %{_includedir}/duk_config.h
 %{_includedir}/duktape.h
+%{_pkgconfigdir}/duktape.pc
diff --git a/duktape-build.patch b/duktape-build.patch
index ac00cd2..57506db 100644
--- a/duktape-build.patch
+++ b/duktape-build.patch
@@ -1,56 +1,38 @@
---- duktape-2.6.0/Makefile.sharedlibrary.orig	2020-10-13 00:23:10.000000000 +0200
-+++ duktape-2.6.0/Makefile.sharedlibrary	2021-04-17 18:50:26.613861274 +0200
-@@ -46,6 +46,8 @@
- 
- # Change to actual path for actual distribution packaging.
- INSTALL_PREFIX = /usr/local
-+LIBDIR = $(INSTALL_PREFIX)/lib
-+INCLUDEDIR = $(INSTALL_PREFIX)/include
- 
- # The 'noline' variant may be more appropriate for some distributions; it
- # doesn't have #line directives in the combined source.
-@@ -55,15 +57,15 @@
- CC = gcc
+--- duktape-2.7.0/Makefile.sharedlibrary.orig	2022-02-18 22:22:19.000000000 +0100
++++ duktape-2.7.0/Makefile.sharedlibrary	2022-05-04 11:55:01.566004402 +0200
+@@ -63,15 +63,15 @@
+ CC := $(CC)
  
  .PHONY: all
--all: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX)
-+all: libduktape.$(SO_REALNAME_SUFFIX)
+-all: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX) duktape.pc
++all: libduktape.$(SO_REALNAME_SUFFIX) duktape.pc
  
  # If the default duk_config.h is not suitable for the distribution, modify it
  # before compiling the shared library and copy the same, edited duk_config.h
  # 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) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -shared -fPIC -Wall -Wextra -Os -Wl,$(LD_SONAME_ARG),libduktape.$(SO_SONAME_SUFFIX) \
 -		-o $@ $(DUKTAPE_SRCDIR)/duktape.c
-+	$(CC) -shared -fPIC -Wall -Wextra -Os $(CFLAGS) $(LDFLAGS) -Wl,$(LD_SONAME_ARG),libduktape.$(SO_SONAME_SUFFIX) \
++	$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -shared -fPIC -Wall -Wextra -Wl,$(LD_SONAME_ARG),libduktape.$(SO_SONAME_SUFFIX) \
 +		-o $@ $(DUKTAPE_SRCDIR)/duktape.c -lm
  
  libduktaped.$(SO_REALNAME_SUFFIX):
- 	$(CC) -shared -fPIC -g -Wall -Wextra -Os -Wl,$(LD_SONAME_ARG),libduktaped.$(SO_SONAME_SUFFIX) \
-@@ -71,17 +73,14 @@
+ 	$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -shared -fPIC -g -Wall -Wextra -Os -Wl,$(LD_SONAME_ARG),libduktaped.$(SO_SONAME_SUFFIX) \
+@@ -86,15 +86,12 @@
  
  # Symlinks depend on platform conventions.
  .PHONY: install
--install: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX)
--	mkdir -p $(INSTALL_PREFIX)/lib/
--	cp $+ $(INSTALL_PREFIX)/lib/
--	rm -f $(INSTALL_PREFIX)/lib/libduktape.so $(INSTALL_PREFIX)/lib/libduktape.$(SO_SONAME_SUFFIX)
--	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(INSTALL_PREFIX)/lib/libduktape.so
--	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(INSTALL_PREFIX)/lib/libduktape.$(SO_SONAME_SUFFIX)
--	rm -f $(INSTALL_PREFIX)/lib/libduktaped.so $(INSTALL_PREFIX)/lib/libduktaped.$(SO_SONAME_SUFFIX)
--	ln -s libduktaped.$(SO_REALNAME_SUFFIX) $(INSTALL_PREFIX)/lib/libduktaped.so
--	ln -s libduktaped.$(SO_REALNAME_SUFFIX) $(INSTALL_PREFIX)/lib/libduktaped.$(SO_SONAME_SUFFIX)
--	mkdir -p $(INSTALL_PREFIX)/include/
--	cp $(DUKTAPE_SRCDIR)/duktape.h $(DUKTAPE_SRCDIR)/duk_config.h $(INSTALL_PREFIX)/include/
-+install: libduktape.$(SO_REALNAME_SUFFIX)
-+	mkdir -p $(DESTDIR)$(LIBDIR)
-+	cp $+ $(DESTDIR)$(LIBDIR)
-+	rm -f $(DESTDIR)$(LIBDIR)/libduktape.so $(DESTDIR)$(LIBDIR)/libduktape.$(SO_SONAME_SUFFIX)
-+	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(LIBDIR)/libduktape.so
-+	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(LIBDIR)/libduktape.$(SO_SONAME_SUFFIX)
-+	mkdir -p $(DESTDIR)$(INCLUDEDIR)
-+	cp $(DUKTAPE_SRCDIR)/duktape.h $(DUKTAPE_SRCDIR)/duk_config.h $(DESTDIR)$(INCLUDEDIR)
- 
- CCOPTS = -I./examples/cmdline
- duk:
+-install: libduktape.$(SO_REALNAME_SUFFIX) libduktaped.$(SO_REALNAME_SUFFIX) duktape.pc
++install: libduktape.$(SO_REALNAME_SUFFIX) duktape.pc
+ 	mkdir -p $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/pkgconfig
+ 	cp $+ $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/
+ 	rm -f $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktape.so $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktape.$(SO_SONAME_SUFFIX)
+ 	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktape.so
+ 	ln -s libduktape.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktape.$(SO_SONAME_SUFFIX)
+-	rm -f $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktaped.so $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktaped.$(SO_SONAME_SUFFIX)
+-	ln -s libduktaped.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktaped.so
+-	ln -s libduktaped.$(SO_REALNAME_SUFFIX) $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/libduktaped.$(SO_SONAME_SUFFIX)
+ 	mv $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/duktape.pc $(DESTDIR)$(INSTALL_PREFIX)$(LIBDIR)/pkgconfig/
+ 	mkdir -p $(DESTDIR)$(INSTALL_PREFIX)/include/
+ 	cp $(DUKTAPE_SRCDIR)/duktape.h $(DUKTAPE_SRCDIR)/duk_config.h $(DESTDIR)$(INSTALL_PREFIX)/include/
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/duktape.git/commitdiff/4156923fda14803e4817034242bcb30e49f8a30f



More information about the pld-cvs-commit mailing list