blob: e3c3fe48f6de3756e07b3d27350f5e4bae9dbadf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
#! /bin/sh -e
oldInterpreter=$(../src/patchelf --print-interpreter ./simple)
echo "current interpreter is $oldInterpreter"
rm -rf scratch
mkdir -p scratch
cp main scratch/
cp libfoo.so scratch/
cp libbar.so scratch/
../src/patchelf --set-rpath $(pwd)/scratch scratch/main
../src/patchelf --set-rpath $(pwd)/scratch scratch/libfoo.so
exitCode=0
scratch/main || exitCode=$?
if test "$exitCode" != 46; then
echo "bad exit code!"
exit 1
fi
|