Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--inhibit-rpath "" passed to executable. #71

Open
baryluk opened this issue Oct 31, 2022 · 0 comments
Open

--inhibit-rpath "" passed to executable. #71

baryluk opened this issue Oct 31, 2022 · 0 comments

Comments

@baryluk
Copy link

baryluk commented Oct 31, 2022

Please include the following information if you're reporting an issue.

  • Which operating system you're using. Centos 8. amd64.
  • Which Python version. Python 3.6
  • Which exodus package version. exodus-bundler 2.0.4
  • The command that you're running (please include the --verbose flag so that the stack trace is included).
  • The full output of the command.
centos8$ exodus \
  --verbose \
  --add /lib64/libnss_files.so.2 \
  --add /lib64/libnss_dns.so.2 \
  --add /lib64/libnss_myhostname.so.2 \
  --add /lib64/libresolv.so.2 \
  foo.bar.aksjdkadj.2210311345 > foo.bar.aksjdkadj.2210311345.installer
WARNING: Installing either the musl or diet C libraries will result in more efficient launchers (currently using bash fallbacks instead).
centos8$ 

So the issue appears to be the startup wrapper script.

centos9$ cat ./.exodus/bin/foo.bar.aksjdkadj.2210311345
#! /bin/bash

current_directory="$(dirname "$(readlink -f "$0")")"
executable="${current_directory}/./foo.bar.aksjdkadj.2210311345-x"
library_path="../../lib64:../../usr/lib64:../../lib:../../usr/lib:../../lib32:../../usr/lib32"
library_path="${current_directory}/${library_path//:/:${current_directory}/}"
linker="${current_directory}/./linker-68e1553cd79d844f7efe46e38dadc34b8af4af011c78c701f4b377ccf8f6df9a"
if [ "true" == "true" ]; then
    exec "${linker}" --library-path "${library_path}" --inhibit-rpath "" "${executable}" "$@"
else
    exec "${linker}" --library-path "${library_path}" "${executable}" "$@"
fi
centos9$

The bundled linker looks to support this flag:

centos9$ ./.exodus/bundles/210dfd9330e9bed177209f5e9545314ce45943c20426fc5f859f2ddc4c059d4b/home/witek/linker-68e1553cd79d844f7efe46e38dadc34b8af4af011c78c701f4b377ccf8f6df9a --help | grep inhibit-rpath
  --inhibit-rpath LIST  ignore RUNPATH and RPATH information in object names
centos9$ ./.exodus/bundles/210dfd9330e9bed177209f5e9545314ce45943c20426fc5f859f2ddc4c059d4b/home/witek/linker-68e1553cd79d844f7efe46e38dadc34b8af4af011c78c701f4b377ccf8f6df9a --version
ld.so (GNU libc) stable release version 2.28.
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
centos9$

But when I try to run the wrapper script with extra commands to pass to the target executable, it does not work properly:

foo@centos9$ /home/foo/.exodus/bin/foo.bar.aksjdkadj.2210311345 ./cfg/foo1.json
20221031-18:30:25 [ERROR] WARNING: expected "--inhibit-rpath" to be config filename (file.cc:270)
20221031-18:30:25 [ERROR] Uncaught exception from thread 140441755105152: expected "--inhibit-rpath" to be config filename (log/log.cc:510)
(stack trace from my C++ app)
foo@centos9$ 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant