pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
sds: Use libtool
Module Name: pkgsrc-wip
Committed By: Michael Baeuerle <micha%NetBSD.org@localhost>
Pushed By: micha
Date: Wed Jul 14 13:23:02 2021 +0200
Changeset: a03a2f71c6692b45825955d684bb472be6140cd7
Modified Files:
sds/Makefile
sds/PLIST
sds/distinfo
sds/patches/patch-Makefile
Log Message:
sds: Use libtool
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=a03a2f71c6692b45825955d684bb472be6140cd7
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
sds/Makefile | 8 +++++---
sds/PLIST | 4 ++--
sds/distinfo | 2 +-
sds/patches/patch-Makefile | 19 ++++++++++++++-----
4 files changed, 22 insertions(+), 11 deletions(-)
diffs:
diff --git a/sds/Makefile b/sds/Makefile
index d6f3bb53aa..e44e55e0e9 100644
--- a/sds/Makefile
+++ b/sds/Makefile
@@ -11,13 +11,15 @@ COMMENT= Simple dynamic strings library for C
LICENSE= 2-clause-bsd
USE_LANGUAGES= c99
-TEST_TARGET= test
+USE_LIBTOOL= yes
INSTALLATION_DIRS= lib include
+TEST_TARGET= test
do-install:
- ${INSTALL_LIB} ${WRKSRC}/libsds.so ${DESTDIR}${PREFIX}/lib/libsds.so
- ${INSTALL_DATA} ${WRKSRC}/sds.h ${DESTDIR}${PREFIX}/include/sds.h
+ cd ${WRKSRC} && ${LIBTOOL} --mode=install \
+ ${INSTALL_LIB} libsds.la ${DESTDIR}${PREFIX}/lib
+ cd ${WRKSRC} && ${INSTALL_DATA} sds.h ${DESTDIR}${PREFIX}/include/sds.h
.include "../../wip/mk/git-package.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/sds/PLIST b/sds/PLIST
index 1cf58759e9..173f8b23ae 100644
--- a/sds/PLIST
+++ b/sds/PLIST
@@ -1,3 +1,3 @@
-@comment $NetBSD: PLIST,v 1.1 2015/07/10 21:24:03 travis-paul Exp $
+@comment $NetBSD$
include/sds.h
-lib/libsds.so
+lib/libsds.la
diff --git a/sds/distinfo b/sds/distinfo
index 41a3cf4d9d..de35acaba6 100644
--- a/sds/distinfo
+++ b/sds/distinfo
@@ -1,3 +1,3 @@
$NetBSD$
-SHA1 (patch-Makefile) = 5c7ca7dfd44f04877e1fc932316c1f996660f246
+SHA1 (patch-Makefile) = f98df3f692006a0ad09d93786d7f02d7bb377e40
diff --git a/sds/patches/patch-Makefile b/sds/patches/patch-Makefile
index 7c4524d379..f466419050 100644
--- a/sds/patches/patch-Makefile
+++ b/sds/patches/patch-Makefile
@@ -5,15 +5,24 @@ $NetBSD$
--- Makefile.orig 2021-07-14 10:28:45.000000000 +0000
+++ Makefile
-@@ -1,8 +1,16 @@
+@@ -1,8 +1,25 @@
-all: sds-test
++# ABI version for shared library
++MAJOR= 2
++MINOR= 0
++PATCH= 0
++
+all: sds-test libsds.so
+
-+sds.o: sds.c sds.h
-+ $(CC) $(CPPFLAGS) $(CFLAGS) -c -fpic -Wall -std=c99 -pedantic -O2 sds.c
++sds.lo: sds.c sds.h
++ libtool --tag=CC --mode=compile \
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -fpic -Wall -std=c99 -pedantic -O2 sds.c
+
-+libsds.so: sds.o
-+ $(CC) $(LDFLAGS) -shared -o libsds.so sds.o
++libsds.so: sds.lo
++ libtool --tag=CC --mode=link \
++ $(CC) $(LDFLAGS) -shared -o libsds.la sds.lo \
++ -rpath ${PREFIX}/lib \
++ -version-number ${MAJOR}:${MINOR}:${PATCH}
sds-test: sds.c sds.h testhelp.h
- $(CC) -o sds-test sds.c -Wall -std=c99 -pedantic -O2 -DSDS_TEST_MAIN
Home |
Main Index |
Thread Index |
Old Index