gcc: no need to special case macos/linux wrt rpaths (#37243)

This commit is contained in:
Harmen Stoppels 2023-04-27 15:52:28 +02:00 committed by GitHub
parent f6464abfcb
commit 8be2f017e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -968,12 +968,7 @@ def write_rpath_specs(self):
# Add easily-overridable rpath string at the end
out.write("*link_libgcc_rpath:\n")
if "platform=darwin" in self.spec:
# macOS linker requires separate rpath commands
out.write(" ".join("-rpath " + lib for lib in rpath_libdirs))
else:
# linux linker uses colon-separated rpath
out.write("-rpath " + ":".join(rpath_libdirs))
out.write("\n")
set_install_permissions(specs_file)
tty.info("Wrote new spec file to {0}".format(specs_file))