Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Mar 2021 19:16:41 +0000 (UTC)
From:      Sunpoet Po-Chuan Hsieh <sunpoet@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r569584 - in head/textproc/discount: . files
Message-ID:  <202103301916.12UJGfkT003920@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: sunpoet
Date: Tue Mar 30 19:16:41 2021
New Revision: 569584
URL: https://svnweb.freebsd.org/changeset/ports/569584

Log:
  Build and install shared library
  
  - Bump PORTREVISION for package change
  
  PR:		254071 (based on)
  Submitted by:	yuri

Modified:
  head/textproc/discount/Makefile
  head/textproc/discount/files/patch-Makefile.in
  head/textproc/discount/pkg-plist

Modified: head/textproc/discount/Makefile
==============================================================================
--- head/textproc/discount/Makefile	Tue Mar 30 19:16:36 2021	(r569583)
+++ head/textproc/discount/Makefile	Tue Mar 30 19:16:41 2021	(r569584)
@@ -4,6 +4,7 @@
 PORTNAME=	discount
 PORTVERSION=	2.2.7
 DISTVERSIONPREFIX=	v
+PORTREVISION=	1
 CATEGORIES=	textproc devel
 
 MAINTAINER=	sunpoet@FreeBSD.org
@@ -18,12 +19,13 @@ USE_GITHUB=	yes
 GH_ACCOUNT=	Orc
 
 CFLAGS+=	-fPIC
-CONFIGURE_ARGS=	--mandir=${PREFIX}/share/man --prefix=${PREFIX}
+CONFIGURE_ARGS=	--mandir=${PREFIX}/share/man --prefix=${PREFIX} --shared
 CONFIGURE_SCRIPT=	configure.sh
 HAS_CONFIGURE=	yes
 MAKE_JOBS_UNSAFE=	yes # libmarkdown is used before it is built
 INSTALL_TARGET=	install install.man
 TEST_TARGET=	test
+USE_LDCONFIG=	yes
 
 CONFLICTS_INSTALL=	markdown
 
@@ -37,5 +39,12 @@ TAB8_DESC=	Use a tabstop of 8 (default is 4)
 EXTRA_CONFIGURE_ON=	--with-dl=both --with-fenced-code --with-github-tags --with-id-anchor
 SAMPLES_INSTALL_TARGET=	install install.samples
 TAB8_CONFIGURE_ON=	--with-tabstops=8
+
+post-configure:
+	@${REINPLACE_CMD} -e 's|/sbin/ldconfig|#&|' ${WRKSRC}/librarian.sh
+
+post-install:
+	${INSTALL_DATA} ${WRKSRC}/libmarkdown.a ${STAGEDIR}${PREFIX}/lib/libmarkdown.a
+	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libmarkdown.so
 
 .include <bsd.port.mk>

Modified: head/textproc/discount/files/patch-Makefile.in
==============================================================================
--- head/textproc/discount/files/patch-Makefile.in	Tue Mar 30 19:16:36 2021	(r569583)
+++ head/textproc/discount/files/patch-Makefile.in	Tue Mar 30 19:16:41 2021	(r569584)
@@ -17,3 +17,11 @@
  	done
  	$(INSTALL_DIR) $(DESTDIR)$(MANDIR)/man7
  	$(INSTALL_DATA) markdown.7 mkd-extensions.7 $(DESTDIR)$(MANDIR)/man7
+@@ -128,6 +128,7 @@ main.o: main.c mkdio.h config.h
+ 
+ $(MKDLIB): $(OBJS)
+ 	./librarian.sh make $(MKDLIB) VERSION $(OBJS)
++	ar crv $(MKDLIB).a $(OBJS)
+ 
+ verify: echo tools/checkbits.sh
+ 	@./echo -n "headers ... "; tools/checkbits.sh && echo "GOOD"

Modified: head/textproc/discount/pkg-plist
==============================================================================
--- head/textproc/discount/pkg-plist	Tue Mar 30 19:16:36 2021	(r569583)
+++ head/textproc/discount/pkg-plist	Tue Mar 30 19:16:41 2021	(r569584)
@@ -4,6 +4,9 @@ bin/markdown
 %%SAMPLES%%bin/theme
 include/mkdio.h
 lib/libmarkdown.a
+lib/libmarkdown.so
+lib/libmarkdown.so.2
+lib/libmarkdown.so.2.2.7
 libdata/pkgconfig/libmarkdown.pc
 %%SAMPLES%%share/man/man1/makepage.1.gz
 share/man/man1/markdown.1.gz



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202103301916.12UJGfkT003920>