Skip to content

Commit 8db82fc

Browse files
committed
fix: resolve issue with relative paths during linking
1 parent 46fc91f commit 8db82fc

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

pylib/gyp/generator/make.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1738,7 +1738,8 @@ def WriteTarget(
17381738
# into the link command, so we need lots of escaping.
17391739
ldflags.append(r"-Wl,-rpath=\$$ORIGIN/")
17401740
ldflags.append(r"-Wl,-rpath-link=\$(builddir)/")
1741-
library_dirs = config.get("library_dirs", [])
1741+
if library_dirs := config.get("library_dirs", []):
1742+
library_dirs = [Sourceify(self.Absolutify(i)) for i in library_dirs]
17421743
ldflags += [("-L%s" % library_dir) for library_dir in library_dirs]
17431744
self.WriteList(ldflags, "LDFLAGS_%s" % configname)
17441745
if self.flavor == "mac":

0 commit comments

Comments
 (0)