forked from mirrors/nixpkgs
autoPatchelfHook: Patch PIC exes/libs as well
If there is a shared object or executable that's using position-independent code, the file's mime type is "application/x-pie-executable", so until this change its dependencies wouldn't be patched. This simply adds the mime type to the search loop. Signed-off-by: aszlig <aszlig@nix.build>
This commit is contained in:
parent
673628e10c
commit
ff5cecf821
|
@ -15,6 +15,7 @@ findElfs() {
|
|||
while [ -n "$1" ]; do
|
||||
mimeType="$(file -b -N --mime-type "$1")"
|
||||
if [ "$mimeType" = application/x-executable \
|
||||
-o "$mimeType" = application/x-pie-executable \
|
||||
-o "$mimeType" = application/x-sharedlib ]; then
|
||||
echo "$1"
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue