Created attachment 190983 [details] Patch Update to 27. Per request of mr@, add a slave port cad/ngspice-shlib (installs as ngspice_rework-shlib) that CONFLICTS with ngspice. This installs the port with SHLIB set, instead of the default X11. This would be more appropriately a FLAVOR, since one and only one option (either X11 or SHLIB) can be set. However, we did not obtain a response from portmgr@.
I'm the maintainer here, can we please have a committer take a look?
Better than a slave port, I would suggest to default to the option SHLIB. cad/kicad 5.0.0 needs the shared libraries of ngspice and it would simplify packaging. BTW, ngspice-28 is the latest stable release, according to http://ngspice.sourceforge.net/download.html
(In reply to Thierry Thomas from comment #2) My concern with that is that as of ngspice 27, SHLIB will disable the CLI. I'm going to see if there's a way to build both in 28.
Created attachment 196426 [details] Patch to upgrade to 28 The attached patch upgrades ngspice to release 28. Unfortunately, the options X11 and SHLIB are still incompatible, due to the redefinition of stdio functions. Remark: ngsconvert ngproc2mod ngmultidec ngmakeidx nghelp are considered as old and outdated applications and they are no more built, unless you set --enable_oldapps
@portmgr: the proposed patch creates a new slave port for the SHLIB option; is that still correct, or should we prefer a flavor?
Approved. I think it might be possible to build the two ports separately and just make sure the files they install don't overlap.
(In reply to Kevin Zheng from comment #6) Great! It would be fine!
Created attachment 197335 [details] Patch to build both options as flavors The proposed patch uses flavors to build the two versions, x11 and shlib, without using a slave port.
(In reply to Thierry Thomas from comment #8) Approved. Let's get this in the tree.
A commit references this bug: Author: thierry Date: Sat Sep 22 16:30:27 UTC 2018 New revision: 480393 URL: https://svnweb.freebsd.org/changeset/ports/480393 Log: Upgrade to 28, and use flavors to build the x11 application and the shared library. PR: 226191 Submitted by: Kevin Zheng (maintainer) Approved by: portmgr (bapt) Changes: head/cad/ngspice_rework/Makefile head/cad/ngspice_rework/distinfo head/cad/ngspice_rework/pkg-plist