Summary: | audio/lmms bash completion script stages in PREFIX not STAGEDIR | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | alt2600 | ||||||
Component: | Individual Port(s) | Assignee: | Rodrigo Osorio <rodrigo> | ||||||
Status: | Closed Overcome By Events | ||||||||
Severity: | Affects Only Me | CC: | vvelox | ||||||
Priority: | --- | Flags: | bugzilla:
maintainer-feedback?
(rodrigo) |
||||||
Version: | Latest | ||||||||
Hardware: | Any | ||||||||
OS: | Any | ||||||||
Attachments: |
|
Description
alt2600
2020-07-25 22:43:14 UTC
Created attachment 217074 [details]
lmms Makefile diff
figured out my syntax added appropriate CMAKE_ARGS to set the BASHCOMP_PKG_PATH variable to stage. this is the diff
Created attachment 217075 [details]
audio/lmms/Makefile proposed
this is the full fixed Makefile
audio/lmms/Makefile
must have had poor syntax in my previous tests, added CMAKE_ARGS to set BASHCOMP_PKG_PATH for STAGEDIR/PREFIX it now stages, packages, and it installs fine. I'm using it now. Not sure how to make a correct patch but its a one liner in the Makefile. -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/vst_plugin_file.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/whatsthis.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/white_key.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/white_key_pressed.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/white_noise_wave_active.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/white_noise_wave_inactive.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/zoom.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/zoom_x.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/zoom_y.png -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/classic/style.css -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/themes/default/style.css -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/wavetables/moog.bin -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/wavetables/saw.bin -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/wavetables/sqr.bin -- Installing: /usr/ports/audio/lmms/work/stage/usr/local/share/lmms/wavetables/tri.bin Installing bash completion... Bash completion for lmms has been installed to /usr/ports/audio/lmms/work/stage/usr/local/share/bash-completion/completions/lmms ====> Compressing man pages (compress-man) /usr/ports/audio/lmms|$} sudo make package ===> Building package for lmms-1.2.1_1,2 Hi, How do you perform the build && install ? I built lmms in poudriere without issue. I probably need more details on what you are trying to accomplish :) Regards -- drigigo (In reply to Rodrigo Osorio from comment #4) I'm just trying to install the program from base ports. In this case actually just upgrade it. cd /usr/ports/audio/lmms sudo make install clean or sudo portmaster -GDb lmms or any upgrade variant of portmaster such as sudo sh -c 'PAGER=echo portmaster -GDba --no-confirm' all of these break at the install phase/packaging phase in portmaster as the bash_completion scripts get installed directly into the system not the staging directory, and the referenced files are missing from the pkg-plist to install/package them. poudriere is not in base, it builds things that don't work in base ports on the regular. don't think poudriere builds as root if I recall correctly from my lost arm64 cross compiling setup, which means I think the cmake files respect prefix of ${STAGEDIR}/${PREFIX} because it detects the non-root build. In this case it uses the CMAKE_INSTALL_PREFIX which I believe is effectively the same staging directory. Not sure why but the completion scripts cmake module ignores the CMAKE_INSTALL_PREFIX by default for root builds, hence it works in poudriere but not ports. from the bash completion Cmake module # Always provide a fallback for non-root INSTALL() SET(BASHCOMP_USER_PATH "${CMAKE_INSTALL_PREFIX}/share/bash-completion/completions") # Cmake doesn't allow easy use of conditional logic at INSTALL() time # this is a problem because ${BASHCOMP_PKG_PATH} may not be writable and we # need sane fallback behavior for bundled INSTALL() (e.g. .AppImage, etc). # # The reason this can't be detected by cmake is that it's fairly common to # run "cmake" as a one user (i.e. non-root) and "make install" as another user # (i.e. root). # # - Creates a script called "install_${SCRIPT_NAME}_completion.sh" into the # working binary directory and invokes this script at install. # - Script handles INSTALL()-time conditional logic for sane ballback behavior # when ${BASHCOMP_PKG_PATH} is unwritable (i.e. non-root); Something cmake # can't handle on its own at INSTALL() time) Actually it does not work in poudriere. Bash completion for lmms has been installed to /usr/local/share/bash-completion/completions/lmms ====> Compressing man pages (compress-man) =========================================================================== =======================<phase: package >============================ ===> Building package for lmms-1.2.1_2,2 pkg-static: Unable to access file /wrkdirs/usr/ports/audio/lmms/work/stage/usr/local/share/bash-completion/completions/lmms:No such file or directory *** Error code 1 (In reply to Zane C. Bowers-Hadley from comment #6) This port has been bumped a few times, and so I've done the edits a couple of times to the Makefile and confirm things work fine outside poudriere so they should work in it try making a copy of the port Makefile to back it up edit it and under the CMAKE_ON=QT5 add this line, all on one line incase its getting split up. You can copy and paste for the proposed Makefile attachment above. CMAKE_ARGS+= -DBASHCOMP_PKG_PATH=${STAGEDIR}${PREFIX}/share/bash-completion/completions to avoid all confusion for others as to what I am talking about cd /usr/ports/audio/lmms sudo cp Makefile Makefile.old sudo ee Makefile (add the line in, or use the editor of your choice to do the same thing like with mousepad or copy paste whatever) (save the Makefile) it should then build and package fine. It has been for me since I posted the bug report. Fixed in 1.2.2 release |