Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

BREW doctor: setting DYLD_* vars #18990

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

BREW doctor: setting DYLD_* vars #18990

kuorq opened this issue Apr 5, 2013 · 13 comments

Comments

@kuorq
Copy link

kuorq commented Apr 5, 2013

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
Copy link
Member

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
Copy link
Author

kuorq commented Apr 5, 2013

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
Copy link
Member

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
Copy link
Contributor

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
Copy link
Author

kuorq commented Apr 6, 2013

:) 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
Copy link
Contributor

OS X does not set any DYLD_* vars. so it has to be in one of the shell
init scripts. Perhaps it sources another script which sets that vars.
Do you have fink installed - I think they (recommend to) set a DYLD_*
var.

What is the content of that var? (echo $DYLD....)

There is the unlikely chance that a this var is set in an environment
plist file (I forgot which one - but that would be pretty exotic).

Where are all those 30 config scripts?

@kuorq
Copy link
Author

kuorq commented Apr 8, 2013

On Sun, Apr 7, 2013 at 4:08 AM, Samuel John notifications@github.comwrote:

OS X does not set any DYLD_* vars. so it has to be in one of the shell
init scripts. Perhaps it sources another script which sets that vars.
Do you have fink installed - I think they (recommend to) set a DYLD_*
var.

Yes, I had fink installed. When I migrated from Snow Leopard to MLion it
stopped working. Then I switched to macport.
A big mess, isn't it?

What is the content of that var? (echo $DYLD....)

echo $DYLD_FALLBACK_LIBRARY_PATH
/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources:/usr/local/scisoft///lib:/usr/local/scisoft///lib

echo $DYLD_FRAMEWORK_PATH
/usr/local/scisoft/Library/Frameworks

They seem both related to scisoft.

There is the unlikely chance that a this var is set in an environment
plist file (I forgot which one - but that would be pretty exotic).

Where are all those 30 config scripts?

The main part of them are in /sw/bin/, some are
/Library/Frameworks/Python.framework and some in /usr/local/scisoft/bin/


Reply to this email directly or view it on GitHubhttps://github.com//issues/18990#issuecomment-16011292
.

Davide Lena
RIT Graduate Student
Astrophysical Science and Technology
54 Lomb Memorial Dr, Rochester, NY 14623 dxl1840@g.rit.edu
http://saturn.cis.rit.edu/~dxl1840/

@samueljohn
Copy link
Contributor

Hmmm perhaps greping through all files in home to find where the var gets set?

@jacknagel
Copy link
Contributor

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.

@davejoyce
Copy link

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
Copy link

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
Copy link

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
Copy link

shaomeng commented Feb 6, 2014

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!

@Homebrew Homebrew 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.
Projects
None yet
Development

No branches or pull requests

8 participants