core: restore the old DYLD_LIBRARY_PATH specifically
This commit is contained in:
parent
f9e4ea9ce8
commit
7c3b342add
|
@ -83,11 +83,12 @@ module Vagrant
|
|||
# If we're in the installer and the command is NOT included
|
||||
# in the installer (external), then remove the DYLD_IMPORT_PATH
|
||||
# environmental variable to run into linker issues. [GH-2219]
|
||||
if Vagrant.in_installer?
|
||||
if Vagrant.in_installer? && ENV["VAGRANT_ORIGINAL_DYLD_LIBRARY_PATH"]
|
||||
installer_dir = ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"].to_s.downcase
|
||||
if !@command[0].downcase.include?(installer_dir)
|
||||
@logger.info("Command not in the installer. Removing DYLD_LIBRARY_PATH")
|
||||
process.environment["DYLD_LIBRARY_PATH"] = ""
|
||||
process.environment["DYLD_LIBRARY_PATH"] =
|
||||
ENV["VAGRANT_ORIGINAL_DYLD_LIBRARY_PATH"]
|
||||
else
|
||||
@logger.debug("Command in installer, not touching env vars.")
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue