When installing graphics/darktable, if the LUA option is unselected, an incorrect plist will generate an error and package installation will fail with: ====> Compressing man pages (compress-man) ===> Installing ldconfig configuration file ===> Installing for darktable-1.4.2 ===> Registering installation for darktable-1.4.2 pkg-static: lstat(/usr/ports/graphics/darktable/work/stage/usr/local/share/darktable/lua/darktable/): No such file or directory pkg-static: lstat(/usr/ports/graphics/darktable/work/stage/usr/local/share/darktable/lua/): No such file or directory *** Error code 74 Stop. make[2]: stopped in /usr/ports/graphics/darktable *** Error code 1 Stop. make[1]: stopped in /usr/ports/graphics/darktable *** Error code 1 Stop. How-To-Repeat: 1. cd $PORTSDIR/graphics/darktable 2. make config, disable LUA 3. make (re)install Fix: Fix pkg-plist & Makefile, the following worked on my system: Index: pkg-plist =================================================================== --- pkg-plist (revision 356237) +++ pkg-plist (working copy) @@ -238,8 +238,6 @@ @dirrmtry %%DATADIR%%/pixmaps/plugins/darkroom @dirrmtry %%DATADIR%%/pixmaps/plugins @dirrmtry %%DATADIR%%/pixmaps -@dirrmtry %%DATADIR%%/lua/darktable -@dirrmtry %%DATADIR%%/lua @dirrmtry %%DATADIR%%/latex @dirrmtry %%DATADIR%%/kernels @dirrmtry %%DATADIR%%/js Index: Makefile =================================================================== --- Makefile (revision 356237) +++ Makefile (working copy) @@ -20,7 +20,7 @@ ONLY_FOR_ARCHS= i386 amd64 ONLY_FOR_ARCHS_REASON= uses SSE extensions -USES= cmake:outsource pkgconfig tar:xz ninja desktop-file-utils +USES= cmake:outsource pkgconfig tar:xz desktop-file-utils USE_GNOME= librsvg2 USE_SQLITE= yes USE_LDCONFIG= ${PREFIX}/lib/${PORTNAME} @@ -120,7 +120,9 @@ .if ${PORT_OPTIONS:MLUA} USES+= lua PLIST_FILES+= %%DATADIR%%/lua/darktable/debug.lua \ - %%DATADIR%%/luarc + %%DATADIR%%/luarc \ + @dirrmtry %%DATADIR%%/lua/darktable \ + @dirrmtry %%DATADIR%%/lua .else CMAKE_ARGS+= -DUSE_LUA:BOOL=OFF .endif
Created attachment 143366 [details] Fix plist by using PLIST_SUB and comments Hello! You're right that the plist is broken if Lua support is disabled, but your patch breaks the Lua-enabled case. You previously reported this in GNATS and I failed to find a solution at that time... I looked in other ports to know what they do (I'm very new to ports) and here's a patch (attached), based on PLIST_SUB and comments in pkg-plist. I tested it with all options checked and all options unchecked. It's working for me. Could you please give it a try?
As far as my option set is concerned, packaging and installation proceeds fine.
Just a follow-up to let you know that I'm still working on this issue: I submitted the patch for review on Phabricator and Baptiste (bapt@) is helping me improving it: https://phabric.freebsd.org/D178
The final patch was committed in r357572. Do you confirm that the issue is resolved for you?
Seems fine with me. Bug report can be closed, thanks.