BREW doctor: setting DYLD_* vars #18990

Closed
kuorq opened this Issue Apr 5, 2013 · 13 comments

8 participants

@kuorq

Hi everyone,
sorry I am not sure if this is the right place to ask the question, anyway: I am trying to have homebrew working. I am still in the phase of solving the warnings produced by doctor and this is the last one:

Warning: Setting DYLD_* vars can break dynamic linking.
Set variables:
DYLD_FALLBACK_LIBRARY_PATH
DYLD_FRAMEWORK_PATH

Anyone could tell me what am I supposed to do?
Thanks in advance. Cheers

@mistydemeo

Those environment variables are probably being set in your ~/.bash_profile (or equivalent). As the warning says, they can break dynamic linking; I recommend removing them from your profile, particularly if you didn't deliberately set them and/or don't know what they're for.

@kuorq

Thanks for your reply. I couldn't figure out which file contains these variables.
What if I unset the variables and use homebrew to do whatever I need to do? In that session doctor homebrew doesn't give me any error. I know it is not the best thing in the world, but...

@mistydemeo

Those environment variables can cause issues at runtime, not just compile-time. It's not recommended to use them unless you really have a reason why you know you need them (and are prepared to potentially break other software).

If you really need to use them, you should try to have them exported only when you need their effects.

@samueljohn

Note that files starting with a dot are hidden in the finder. You need to use the Terminal to check the .profile or .bash_profile most likely.

@kuorq

:) yes I know that. I have just .tcshrc and no sign of DYLD inside.
I tried to unset the variables and install what I needed (python). Though at the beginning doctor wasn't complaining, at the end it couldn't link something, and in addition, it gave me the following:

Warning: "config" scripts exist outside your system or Homebrew directories.
./configure scripts often look for *-config scripts to determine if
software packages are installed, and what additional flags to use when
compiling and linking.
Having additional scripts in your path can confuse software installed via
Homebrew if the config script overrides a system or Homebrew provided
script of the same name. We found the following "config" scripts:

list of about 30 files...

Warning: You have unlinked kegs in your Cellar...

And now I am really lost.

@samueljohn
@kuorq
@samueljohn
@jacknagel

There could be multiple levels of indirection, something could be getting evaled, etc. Basically they are getting set by something and it appears to be related to scisoft. But we can't just keep guessing at it here, you'll have to do some digging and find out.

@jacknagel jacknagel closed this Apr 13, 2013
@davejoyce

Even though this issue is closed, I thought that I would share this. I'm having this issue too, because of DYLD_LIBRARY_PATH. When I do an echo $DYLD_LIBRARY_PATH, I find the culprit:
:/Users/xxxx/weblogic/wlserver/server/native/macosx

So, it looks like the Oracle Weblogic install script will put this into your environment. If you're a Java/JEE developer and you install Weblogic under your HOME directory, be prepared to encounter this issue. HTH.

@aarongeiser

I was experiencing this same issue and discovered that when attempting to setup Wine some time ago - there is some mention of setting this environment variable. See following link:

http://wiki.winehq.org/MacOSX/FAQs#head-a233c72ca2fc1b18482ec604dbd1d139a309318c

Removed Wine because I was not using it. I found that the variable was set in my system-wide /etc/profile

Removed the two lines:
alias wine=/Applications/Wine.app/Contents/Resources/bin/wine
export DYLD_FALLBACK_LIBRARY_PATH=/usr/X11/lib:/usr/lib::

All is right in the world.

@CourtJesterG

I just did a Brew Doctor after installing Cuda drivers for my graphics card with developer tools the latest one on Mac OS X: Am following these instructions: http://docs.nvidia.com/cuda/cuda-getting-started-guide-for-mac-os-x/index.html#install-cuda-driver-and-software

It tells you to export: To change the environment variables for 64-bit operating systems:

export PATH=/Developer/NVIDIA/CUDA-5.5/bin:$PATH
export DYLD_LIBRARY_PATH=/Developer/NVIDIA/CUDA-5.5/lib:$DYLD_LIBRARY_PATH

I did that and put it in my Bash_profile

Brew doctor than stated: Warning: Setting DYLD_* vars can break dynamic linking.
Set variables:
DYLD_LIBRARY_PATH

So am kinda confused what to do: Cuda is symlinked in usr/local/cuda with ~/developer/Nvidia/CUDA-5.5

I did see another instructional doc, but wasn't for MAC OS X: http://developer.download.nvidia.com/compute/cuda/repos/howto_install_cuda_deb_packages.txt

It says to export to usr/local

So.... what to do?

@shaomeng

Re: CourtJesterG

I installed CUDA and experienced the same issue. Now I have this DYLD_LIBRARY_PATH in my .bash_profile because otherwise one of my libraries doesn't work!

I haven't found any problem brought to me by this DYLD_LIBRARY_PATH. I'm also wondering if there's a better solution!

@xu-cheng xu-cheng locked and limited conversation to collaborators Feb 16, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.