Skip to content

Commit

Permalink
Setup PATH to correctly handle rpaths (dynamic linking) on windows, l…
Browse files Browse the repository at this point in the history
…inux & macos.
  • Loading branch information
helmesjo committed Aug 12, 2020
1 parent 4425a5a commit 4499dc4
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions recipes/corrade/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,10 @@ def package_info(self):
if self.settings.os == "Linux":
self.cpp_info.system_libs = ["m", "dl"]

self.cpp_info.builddirs = [os.path.join(self.package_folder, "lib", "cmake", "Corrade")]

bindir = os.path.join(self.package_folder, "bin")
self.output.info("Appending PATH environment variable: {}".format(bindir))
self.env_info.PATH.append(bindir)
self.env_info.PATH.append(os.path.join(self.package_folder, "bin"))
if self.options.shared:
# Help linker find rpaths
if self.settings.os == "Linux":
self.env_info.LD_LIBRARY_PATH.append(os.path.join(self.package_folder, "lib"))
if self.settings.os == "Macos":
self.env_info.DYLD_LIBRARY_PATH.append(os.path.join(self.package_folder, "lib"))

0 comments on commit 4499dc4

Please sign in to comment.