Date: Fri, 29 May 2009 00:44:19 +0200 (CEST) From: Kai Wang <kaiwang27@gmail.com> To: FreeBSD-gnats-submit@FreeBSD.org Cc: sem@FreeBSD.org Subject: ports/135047: [PATCH] devel/argp-standalone: build and install libargp.so Message-ID: <200905282244.n4SMiJUs039134@localhost.my.domain> Resent-Message-ID: <200905282320.n4SNK13n024319@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 135047 >Category: ports >Synopsis: [PATCH] devel/argp-standalone: build and install libargp.so >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu May 28 23:20:01 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Kai Wang >Release: FreeBSD 8.0-CURRENT amd64 >Organization: >Environment: System: FreeBSD viskning 8.0-CURRENT FreeBSD 8.0-CURRENT #2: Sat Apr 4 16:38:06 CEST >Description: Currently argp-standalone only build and install a static library libargp.a, while sometimes application might want to dynamically link to a libargp.so. (I'm currently working on an application that needs this dso) This patch change port argp-standalone to use libtool to build and install both dynamic shared object and static library. Added file(s): - files/patch-Makefile.am - files/patch-configure.ac - files/patch-testsuite::Makefile.am Port maintainer (sem@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.77 >How-To-Repeat: >Fix: --- argp-standalone-1.3.patch begins here --- diff -ruN --exclude=CVS /usr/ports/devel/argp-standalone/Makefile /usr/home/kaiw/argp-standalone/Makefile --- /usr/ports/devel/argp-standalone/Makefile 2008-10-18 15:38:13.000000000 +0200 +++ /usr/home/kaiw/argp-standalone/Makefile 2009-05-28 15:50:23.000000000 +0200 @@ -16,12 +16,26 @@ COMMENT= Standalone version of arguments parsing functions from GLIBC GNU_CONFIGURE= yes +USE_AUTOTOOLS= aclocal:110 autoconf:262 automake:110 libtool:15 +AUTOMAKE_ARGS= -c -a +ACLOCAL_ARGS= --acdir=${ACLOCAL_DIR} -I ${LOCALBASE}/share/aclocal +USE_LDCONFIG= yes -PLIST_FILES= lib/libargp.a include/argp.h +PLIST_FILES= lib/libargp.la lib/libargp.a \ + lib/libargp.so lib/libargp.so.0 \ + include/argp.h + +.include <bsd.port.pre.mk> + +pre-configure: + @cd ${WRKSRC}; ${SETENV} ${AUTOTOOLS_ENV} ${LIBTOOLIZE} --automake do-install: @cd ${WRKSRC}; \ - ${INSTALL_DATA} libargp.a ${PREFIX}/lib; \ - ${INSTALL_DATA} argp.h ${PREFIX}/include + ${INSTALL_DATA} argp.h ${PREFIX}/include; \ + ${INSTALL_DATA} .libs/libargp.la ${PREFIX}/lib; \ + ${INSTALL_DATA} .libs/libargp.a ${PREFIX}/lib; \ + ${INSTALL_PROGRAM} .libs/libargp.so.0 ${PREFIX}/lib + @cd ${PREFIX}/lib && ${LN} -sf libargp.so.0 libargp.so -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff -ruN --exclude=CVS /usr/ports/devel/argp-standalone/files/patch-Makefile.am /usr/home/kaiw/argp-standalone/files/patch-Makefile.am --- /usr/ports/devel/argp-standalone/files/patch-Makefile.am 1970-01-01 01:00:00.000000000 +0100 +++ /usr/home/kaiw/argp-standalone/files/patch-Makefile.am 2009-05-28 15:31:07.000000000 +0200 @@ -0,0 +1,28 @@ +--- Makefile.am.orig 2009-05-28 15:19:50.000000000 +0200 ++++ Makefile.am 2009-05-28 15:30:57.000000000 +0200 +@@ -21,20 +21,20 @@ + AUTOMAKE_OPTIONS = foreign + SUBDIRS = . testsuite + +-LIBOBJS = @LIBOBJS@ ++LTLIBOBJS = @LTLIBOBJS@ + +-noinst_LIBRARIES = libargp.a ++lib_LTLIBRARIES = libargp.la + noinst_PROGRAMS = argp-test + noinst_HEADERS = argp.h argp-fmtstream.h argp-namefrob.h # argp-comp.h + + EXTRA_DIST = mempcpy.c strchrnul.c strndup.c Versions + + # Leaves out argp-fs-xinl.c and argp-xinl.c +-libargp_a_SOURCES = argp-ba.c argp-eexst.c argp-fmtstream.c \ ++libargp_la_SOURCES = argp-ba.c argp-eexst.c argp-fmtstream.c \ + argp-help.c argp-parse.c argp-pv.c \ + argp-pvh.c + +-libargp_a_LIBADD = $(LIBOBJS) ++libargp_la_LIBADD = $(LTLIBOBJS) + +-argp_test_LDADD = libargp.a ++argp_test_LDADD = libargp.la + diff -ruN --exclude=CVS /usr/ports/devel/argp-standalone/files/patch-configure.ac /usr/home/kaiw/argp-standalone/files/patch-configure.ac --- /usr/ports/devel/argp-standalone/files/patch-configure.ac 1970-01-01 01:00:00.000000000 +0100 +++ /usr/home/kaiw/argp-standalone/files/patch-configure.ac 2009-05-28 15:21:22.000000000 +0200 @@ -0,0 +1,10 @@ +--- configure.ac.orig 2009-05-28 15:20:01.000000000 +0200 ++++ configure.ac 2009-05-28 15:21:06.000000000 +0200 +@@ -17,6 +17,7 @@ + AC_PROG_MAKE_SET + AC_PROG_RANLIB + AM_PROG_CC_STDC ++AC_PROG_LIBTOOL + + if test "x$am_cv_prog_cc_stdc" = xno ; then + AC_ERROR([the C compiler doesn't handle ANSI-C]) diff -ruN --exclude=CVS /usr/ports/devel/argp-standalone/files/patch-testsuite::Makefile.am /usr/home/kaiw/argp-standalone/files/patch-testsuite::Makefile.am --- /usr/ports/devel/argp-standalone/files/patch-testsuite::Makefile.am 1970-01-01 01:00:00.000000000 +0100 +++ /usr/home/kaiw/argp-standalone/files/patch-testsuite::Makefile.am 2009-05-28 15:28:19.000000000 +0200 @@ -0,0 +1,11 @@ +--- testsuite/Makefile.am.orig 2009-05-28 15:21:33.000000000 +0200 ++++ testsuite/Makefile.am 2009-05-28 15:21:41.000000000 +0200 +@@ -5,7 +5,7 @@ + + noinst_PROGRAMS = $(TS_PROGS) ex1 ex3 ex4 + +-LDADD = ../libargp.a ++LDADD = ../.libs/libargp.a + + EXTRA_DIST = $(TS_SH) run-tests + CLEANFILES = test.out --- argp-standalone-1.3.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905282244.n4SMiJUs039134>