Bug 250551

Summary: misc/far2l: add an option for build with wxWidgets 3.1
Product: Ports & Packages Reporter: Vladimir Druzenko <vvd>
Component: Individual Port(s)Assignee: Alexey Dokuchaev <danfe>
Status: In Progress ---    
Severity: Affects Some People Flags: bugzilla: maintainer-feedback? (danfe)
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
Add an option for build with wxWidgets 3.1 vvd: maintainer-approval?

Description Vladimir Druzenko freebsd_committer freebsd_triage 2020-10-23 02:09:12 UTC
Created attachment 218993 [details]
Add an option for build with wxWidgets 3.1

Tested in 12.1-p10 amd64: make check-plist/install/run with wxWidgets 3.0, 3.1 and without both.

Upstream added support of the wxWidgets 2 months ago: https://github.com/elfmz/far2l/issues/726
Comment 1 Alexey Dokuchaev freebsd_committer freebsd_triage 2020-10-23 05:09:35 UTC
(In reply to VVD from comment #0)
> Upstream added support of the wxWidgets 2 months ago
If you'd read the log and the diff for ports r552954 more carefully, you would have noticed that the port is "USE_WX=3.0+" now (before was just 3.0 :-).  So you should be able to set your preferred WITH_WX_VER in the /etc/make.conf, and as long as it satisfies the USE_WX range, it would be used instead of the default.

However, I now see this code in the CMakeLists.txt:

>   if (${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
>     if (DEFINED wxWidgets_CONFIG_EXECUTABLE)
>       ...
But apparently wxWidgets_CONFIG_EXECUTABLE is not defined, and it looks for wx-config itself, first for 3.1, then for 3.0.  I'll look into this.  Regardless, port's options is not the right place for wxWidgets version selection.
Comment 2 Vladimir Druzenko freebsd_committer freebsd_triage 2020-11-16 01:02:43 UTC
(In reply to Alexey Dokuchaev from comment #1)
> So you should be able to set your preferred WITH_WX_VER in the /etc/make.conf
Plz, no again:
.if ${.CURDIR:M*/misc/far2l*}
WITH_WX_VER=3.1
.endif

> But apparently wxWidgets_CONFIG_EXECUTABLE is not defined, and it looks for wx-config itself, first for 3.1, then for 3.0.  I'll look into this.  Regardless, port's options is not the right place for wxWidgets version selection.
Already tested - it handle 3.0 1st if both are installed.

Option in ports look better than custom /etc/make.conf.