diff options
| author | Danilo M. <danix@danix.xyz> | 2026-11-11 18:14:01 +0100 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-11-11 18:14:01 +0100 |
| commit | 78d4e94b38621159fa3c643fe95201b8f21278c7 (patch) | |
| tree | 5b87a8fd5e32b981ed3784564e2bb9b8d2f0c1c6 | |
| parent | d47c72e67b8a30663c3cd4485c385c930bc6fe50 (diff) | |
| download | sbo-slackbuilds-78d4e94b38621159fa3c643fe95201b8f21278c7.tar.gz sbo-slackbuilds-78d4e94b38621159fa3c643fe95201b8f21278c7.zip | |
The extracted test-build package lacks its symlinks (makepkg -l y puts
them in doinst.sh), so the embedded ruby cannot find libruby.so.3.4.
Run doinst.sh in the extract dir and set LD_LIBRARY_PATH. Write the
generator output to the scratch dir first, so a failed run cannot
empty the tracked completion file.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
| -rw-r--r-- | AGENTS.md | 18 |
1 files changed, 16 insertions, 2 deletions
@@ -144,19 +144,33 @@ Pointing the gem vars at the extracted tree fixes it. Note `3.4.0` in that path is the embedded **ruby version** and moves when upstream bumps ruby; check `$FW/embedded/lib/ruby/gems/` if the path is wrong. +**The extracted tree also needs its symlinks and library path.** makepkg +`-l y` moves every symlink into `install/doinst.sh`, so a bare `tar xf` +leaves out `libruby.so.3.4` and the run dies with `error while loading +shared libraries: libruby.so.3.4`. Run `doinst.sh` inside the extract dir +(it holds only relative `rm -rf`/`ln -sf` lines; check that before running +it) and set `LD_LIBRARY_PATH`, since the binary's RPATH points at +`/opt/metasploit-framework`. Write the output to the scratch dir first: a +failed run redirected straight onto the tracked file empties it. (Found +2026-11-11 during the 6.5.10 bump.) + ```bash +REPO=$PWD # sbo-slackbuilds root KEPT=/data/sbo-test-build/kept/metasploit-framework-bin-$VERSION-x86_64-*.tgz +mkdir -p $SCRATCH/msf-extract tar xf $KEPT -C $SCRATCH/msf-extract +(cd $SCRATCH/msf-extract && sh install/doinst.sh) FW=$SCRATCH/msf-extract/opt/metasploit-framework curl -o $SCRATCH/gen.rb \ https://gitlab.com/kalilinux/packages/metasploit-framework/-/raw/kali/master/debian/generate-msfvenom-bash-completion.rb cd $FW/embedded/framework +LD_LIBRARY_PATH=$FW/embedded/lib \ GEM_HOME=$FW/embedded/lib/ruby/gems/3.4.0 \ GEM_PATH=$FW/embedded/lib/ruby/gems/3.4.0 \ BUNDLE_GEMFILE=$FW/embedded/framework/Gemfile \ $FW/embedded/bin/ruby \ - -I$FW/embedded/framework/lib $SCRATCH/gen.rb \ - > network/metasploit-framework-bin/msfvenom.bash-completion + -I$FW/embedded/framework/lib $SCRATCH/gen.rb > $SCRATCH/new.bc +cp $SCRATCH/new.bc $REPO/network/metasploit-framework-bin/msfvenom.bash-completion ``` **Do not fall back to running the generator against a live |
