diff --git a/sources/libs/serd-static/debian/changelog b/sources/libs/serd-static/debian/changelog new file mode 100644 index 0000000..c800015 --- /dev/null +++ b/sources/libs/serd-static/debian/changelog @@ -0,0 +1,5 @@ +serd-static (6:0.30.10-1kxstudio1) focal; urgency=medium + + * Initial package + + -- falkTX Sun, 17 Apr 2022 15:05:47 +0100 diff --git a/sources/libs/serd-static/debian/control b/sources/libs/serd-static/debian/control new file mode 100644 index 0000000..c4e042b --- /dev/null +++ b/sources/libs/serd-static/debian/control @@ -0,0 +1,29 @@ +Source: serd-static +Section: libs +Priority: optional +Maintainer: falkTX +Build-Depends: debhelper-compat (= 13), + kxstudio-build-scripts, + python3 +Standards-Version: 4.5.0 +Homepage: http://drobilla.net/software/serd/ +Rules-Requires-Root: no + +Package: serd-static +Architecture: any +Depends: ${misc:Depends} +Description: lightweight RDF syntax library (static) + Serd is a lightweight C library for RDF syntax which supports reading + and writing Turtle and NTriples. + . + This package provides the static library used in KXStudio builds. + +Package: serdi +Architecture: any +Section: text +Depends: ${misc:Depends}, ${shlibs:Depends} +Description: lightweight RDF syntax library - serdi tool + Serd is a lightweight C library for RDF syntax which supports reading + and writing Turtle and NTriples. + . + This package provides the utility 'serdi'. diff --git a/sources/libs/serd-static/debian/patches/01_dont-run-ldconfig.patch b/sources/libs/serd-static/debian/patches/01_dont-run-ldconfig.patch new file mode 100644 index 0000000..06a2450 --- /dev/null +++ b/sources/libs/serd-static/debian/patches/01_dont-run-ldconfig.patch @@ -0,0 +1,13 @@ +diff --git a/wscript b/wscript +index 088ea0b..819c7d1 100644 +--- a/wscript ++++ b/wscript +@@ -173,8 +173,6 @@ def build(bld): + # Man page + bld.install_files('${MANDIR}/man1', 'doc/serdi.1') + +- bld.add_post_fun(autowaf.run_ldconfig) +- + + class LintContext(Build.BuildContext): + fun = cmd = 'lint' diff --git a/sources/libs/serd-static/debian/patches/02_hidden-serd-api.patch b/sources/libs/serd-static/debian/patches/02_hidden-serd-api.patch new file mode 100644 index 0000000..4be992f --- /dev/null +++ b/sources/libs/serd-static/debian/patches/02_hidden-serd-api.patch @@ -0,0 +1,21 @@ +diff --git a/include/serd/serd.h b/include/serd/serd.h +index e550541..c2ee87d 100644 +--- a/include/serd/serd.h ++++ b/include/serd/serd.h +@@ -25,15 +25,7 @@ + #include + #include + +-#if defined(_WIN32) && !defined(SERD_STATIC) && defined(SERD_INTERNAL) +-# define SERD_API __declspec(dllexport) +-#elif defined(_WIN32) && !defined(SERD_STATIC) +-# define SERD_API __declspec(dllimport) +-#elif defined(__GNUC__) +-# define SERD_API __attribute__((visibility("default"))) +-#else +-# define SERD_API +-#endif ++#define SERD_API + + #ifdef __GNUC__ + # define SERD_PURE_FUNC __attribute__((pure)) diff --git a/sources/libs/serd-static/debian/patches/03_force-libs.patch b/sources/libs/serd-static/debian/patches/03_force-libs.patch new file mode 100644 index 0000000..81e439c --- /dev/null +++ b/sources/libs/serd-static/debian/patches/03_force-libs.patch @@ -0,0 +1,10 @@ +--- serd-0.18.2.orig/serd.pc.in ++++ serd-0.18.2/serd.pc.in +@@ -6,6 +6,6 @@ includedir=@INCLUDEDIR@ + Name: Serd + Version: @SERD_VERSION@ + Description: Lightweight RDF syntax library +-Libs: -L${libdir} -l@LIB_SERD@ ++Libs: -L${libdir} -l@LIB_SERD@ -lm + Libs.private: -lm + Cflags: -I${includedir}/serd-@SERD_MAJOR_VERSION@ diff --git a/sources/libs/serd-static/debian/patches/series b/sources/libs/serd-static/debian/patches/series new file mode 100644 index 0000000..2421932 --- /dev/null +++ b/sources/libs/serd-static/debian/patches/series @@ -0,0 +1,3 @@ +01_dont-run-ldconfig.patch +02_hidden-serd-api.patch +03_force-libs.patch diff --git a/sources/libs/serd-static/debian/rules b/sources/libs/serd-static/debian/rules new file mode 100755 index 0000000..c88a920 --- /dev/null +++ b/sources/libs/serd-static/debian/rules @@ -0,0 +1,29 @@ +#!/usr/bin/make -f + +KXSTUDIO_NO_FASTMATH = y +include /usr/share/dpkg/kxstudio.mk + +WAF = python3 ./waf + +override_dh_auto_configure: + $(WAF) configure \ + --static \ + --no-shared \ + --prefix=/opt/kxstudio \ + --strict \ + --test + +override_dh_auto_build: + $(WAF) + +override_dh_auto_clean: + $(WAF) clean || true + +override_dh_auto_install: + $(WAF) install --destdir=$(CURDIR)/debian/tmp + +override_dh_auto_test: + $(WAF) test + +%: + dh $@ diff --git a/sources/libs/serd-static/debian/source/format b/sources/libs/serd-static/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/sources/libs/serd-static/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt)