On 2026/11/12 20:17, Jan Klemkow wrote:
> On Thu, Nov 12, 2026 at 05:46:11PM +0000, Stuart Henderson wrote:
> > ok? I've built everything that depends on it.
> > 
> > (was prompted by looking at updating naev so I could update
> > libunibreak, and that needed cmark>=0.31, but that got a bit
> > more complicated than I wanted to deal with, but since I've
> > tested the cmark update anyway thought I'd send it out).
> > 
> > Index: pkg/PLIST
> > ===================================================================
> > RCS file: /cvs/ports/textproc/cmark/pkg/PLIST,v
> > diff -u -p -r1.3 PLIST
> > --- pkg/PLIST       30 Aug 2022 11:26:26 -0000      1.3
> > +++ pkg/PLIST       12 Nov 2026 17:42:11 -0000
> > @@ -8,7 +8,6 @@ lib/cmake/cmark/cmark-config-version.cma
> >  lib/cmake/cmark/cmark-config.cmake
> >  lib/cmake/cmark/cmark-targets${MODCMAKE_BUILD_SUFFIX}
> >  lib/cmake/cmark/cmark-targets.cmake
> > -@static-lib lib/libcmark.a
> 
> Cloud we keep the static library?
> 
> I need it, for a private project, where I have to compile static C
> program, which runs chrooted in /var/www.
> 

It can be done like this but it's pretty ugly and I'm not sure if
I got it right for pkg_add -u to work properly.

Upstream intentionally changed to only building one or other version of
the library in 
https://github.com/commonmark/cmark/commit/853cf7c9549acc5a7b45de9dc8f5fb044cb96d63
which is a bit big to revert and maintain.

Index: Makefile
===================================================================
RCS file: /cvs/ports/textproc/cmark/Makefile,v
diff -u -p -r1.8 Makefile
--- Makefile    6 May 2024 12:24:07 -0000       1.8
+++ Makefile    17 Nov 2026 16:46:37 -0000
@@ -2,10 +2,9 @@ COMMENT =      CommonMark parsing and renderi
 
 GH_ACCOUNT =   commonmark
 GH_PROJECT =   cmark
-GH_TAGNAME =   0.30.3
-REVISION =     0
+GH_TAGNAME =   0.31.2
 
-SHARED_LIBS += cmark                     0.1 # 0.29
+SHARED_LIBS += cmark                     0.2
 
 CATEGORIES =   textproc
 
@@ -18,10 +17,18 @@ PERMIT_PACKAGE =    Yes
 
 WANTLIB += c
 
-MODULES =      devel/cmake \
-               lang/python
+MODULES =      devel/cmake
 
-# tests only
-MODPY_RUNDEP =         No
+FLAVORS =      static
+FLAVOR ?=
+
+.if ${FLAVOR:Mstatic}
+CONFIGURE_ARGS = -DBUILD_SHARED_LIBS=Off
+.else
+CONFIGURE_ARGS = -DBUILD_SHARED_LIBS=On
+.endif
+
+# for tests
+BUILD_DEPENDS =        lang/python/3
 
 .include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/textproc/cmark/distinfo,v
diff -u -p -r1.4 distinfo
--- distinfo    14 Feb 2023 15:37:19 -0000      1.4
+++ distinfo    17 Nov 2026 16:46:37 -0000
@@ -1,2 +1,2 @@
-SHA256 (cmark-0.30.3.tar.gz) = hen7UVUxzCya4XbWk/mHF3SDDPHzI6Z1j7GHpRSNexY=
-SIZE (cmark-0.30.3.tar.gz) = 246916
+SHA256 (cmark-0.31.2.tar.gz) = +bxco4vLC3J/AFYQD6xNdD52iHLjus7HdG3ij1cA1pc=
+SIZE (cmark-0.31.2.tar.gz) = 267259
Index: pkg/PFRAG.no-static
===================================================================
RCS file: pkg/PFRAG.no-static
diff -N pkg/PFRAG.no-static
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ pkg/PFRAG.no-static 17 Nov 2026 16:46:37 -0000
@@ -0,0 +1,16 @@
+@option no-default-conflict
+@conflict cmark-*-!static
+@bin bin/cmark
+include/cmark.h
+include/cmark_export.h
+include/cmark_version.h
+lib/cmake/
+lib/cmake/cmark/
+lib/cmake/cmark/cmark-config-version.cmake
+lib/cmake/cmark/cmark-config.cmake
+lib/cmake/cmark/cmark-targets${MODCMAKE_BUILD_SUFFIX}
+lib/cmake/cmark/cmark-targets.cmake
+@lib lib/libcmark.so.${LIBcmark_VERSION}
+lib/pkgconfig/libcmark.pc
+@man man/man1/cmark.1
+@man man/man3/cmark.3
Index: pkg/PFRAG.static
===================================================================
RCS file: pkg/PFRAG.static
diff -N pkg/PFRAG.static
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ pkg/PFRAG.static    17 Nov 2026 16:46:37 -0000
@@ -0,0 +1,3 @@
+@option no-default-conflict
+@conflict cmark-*-static
+@static-lib lib/libcmark.a
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/textproc/cmark/pkg/PLIST,v
diff -u -p -r1.3 PLIST
--- pkg/PLIST   30 Aug 2022 11:26:26 -0000      1.3
+++ pkg/PLIST   17 Nov 2026 16:46:37 -0000
@@ -1,15 +1,2 @@
-@bin bin/cmark
-include/cmark.h
-include/cmark_export.h
-include/cmark_version.h
-lib/cmake/
-lib/cmake/cmark/
-lib/cmake/cmark/cmark-config-version.cmake
-lib/cmake/cmark/cmark-config.cmake
-lib/cmake/cmark/cmark-targets${MODCMAKE_BUILD_SUFFIX}
-lib/cmake/cmark/cmark-targets.cmake
-@static-lib lib/libcmark.a
-@lib lib/libcmark.so.${LIBcmark_VERSION}
-lib/pkgconfig/libcmark.pc
-@man man/man1/cmark.1
-@man man/man3/cmark.3
+%%static%%
+!%%static%%

Reply via email to