On 2/18/25 11:21 PM, Stuart Henderson wrote:
On 2025/02/18 22:59, Benjamin Stürz wrote:
Hi ports@,
updating cad/yosys requires a new dependency: cxxopts.
It's a single-header C++ library for parsing the command line.
I'm wasn't sure, if I should just vendor it inside yosys,
so I just made a new port, like for the other dependency: cad/abc
there are at least two other ports using cxxopts (from looking at bulk
build logs); graphics/maim and graphics/slop. it's vendored upstream in
both cases. if this is done in a new port, it would be good to check
that those don't pick up a separately installed version affecting
their builds (either that or make sure that they _do_ use it and add
the dep).
I built both and there are no problems.
Both vendor cxxopts.h directly and #include it with "", and not <>,
so no changes are required.
yosys uses git submodules, so it would have been a little more annoying
to vendor cxxopts, that's why I decided to make it a new port.
WWW: https://github.com/jarro2783/cxxopts
DESCR: Lightweight C++ command line option parser.
I hope Thunderbird doesn't mess with my patch:
it didn't, but please send tars for new ports, it avoids thinking about
which patch options to use to get the right directory created, and also
cleaning .orig files.
Sorry for this oversight, usually I do send tgz's for new ports.
diff 6368aa1d825fc2e706fe74348a0d726e329b5e6d
2c7899bf99caadefb6bede7e5ac0eff52b7656a1
commit - 6368aa1d825fc2e706fe74348a0d726e329b5e6d
commit + 2c7899bf99caadefb6bede7e5ac0eff52b7656a1
blob - /dev/null
blob + be4fd0120dfc647226382d3077df5c603554409b (mode 644)
--- /dev/null
+++ devel/cxxopts/Makefile
@@ -0,0 +1,16 @@
+COMMENT = lightweight C++ command line option parser
+
+GH_ACCOUNT = jarro2783
+GH_PROJECT = cxxopts
+GH_TAGNAME = v3.2.0
+
+CATEGORIES = devel
+
+# MIT
+PERMIT_PACKAGE = Yes
+
+COMPILER = base-clang ports-gcc
+
+MODULES = devel/cmake
+
+.include <bsd.port.mk>
blob - /dev/null
blob + 54359e770c5ef3fc9d65134b0f5f0e3357bf98f6 (mode 644)
--- /dev/null
+++ devel/cxxopts/distinfo
@@ -0,0 +1,2 @@
+SHA256 (cxxopts-3.2.0.tar.gz) =
n0P6lyUy5d9sX9WtD1usYGzexUHMrxcyRj2AcLu38Ds=
+SIZE (cxxopts-3.2.0.tar.gz) = 160534
blob - /dev/null
blob + 284abdb25f4d7f5669c460084769a435dc86529c (mode 644)
--- /dev/null
+++ devel/cxxopts/pkg/DESCR
@@ -0,0 +1 @@
+Lightweight C++ command line option parser
blob - /dev/null
blob + d4ee57c552e898220bff5c6dd9b16c2394163392 (mode 644)
--- /dev/null
+++ devel/cxxopts/pkg/PLIST
@@ -0,0 +1,7 @@
+include/cxxopts.hpp
+lib/cmake/
+lib/cmake/cxxopts/
+lib/cmake/cxxopts/cxxopts-config-version.cmake
+lib/cmake/cxxopts/cxxopts-config.cmake
+lib/cmake/cxxopts/cxxopts-targets.cmake
+lib/pkgconfig/cxxopts.pc