Subject Re: [firebird-support] isql DYLD_LIBRARY_PATH Mac OSX
Author John Bellardo
Todd,

On Jan 15, 2005, at 9:20 PM, Todd Fisher wrote:

>
> Hi,
> I'm trying to run isql command on the mac osx 10.3. The problem I
> have now after having built firebird, is that when I execute isql
> command without having run make install, I get:
>
> dyld: $HOME/projects/firebird-1.5.2.4731/gen/firebird//bin/isql
> Undefined symbols:
> $HOME/projects/firebird-1.5.2.4731/gen/firebird//bin/isql undefined
> reference to __ZdlPv expected to be defined in Firebird
> $HOME/projects/firebird-1.5.2.4731/gen/firebird//bin/isql undefined
> reference to __Znwm expected to be defined in Firebird
>
> I believe, I should just have to point DYLD_LIBRARY_PATH to
> $HOME/projects/firebird-1.5.2.4731/gen/firebird/lib and all should be
> well. So, in my makefile I have:
>
> FBISQL=DYLD_LIBRARY_PATH=$(FIREBIRDDIST)/lib:$DYLD_LIBRARY_PATH
> $(FIREBIRDDIST)/bin/isql
>
> Then I just call $(FBISQL) -input file.sql ...
>
> Any suggestions on how this should work on the mac? This works in
> linux fine replacing DYLD_LIBRARY_PATH with LD_LIBRARY_PATH.
>
> Perhaps, I am missing something about how the dynamic linker works?

The .dyld is created assuming it will only be used from within a
framework. As a result the library paths that get imbedded in isql and
the dyld itself don't work appropriately with DYLD_LIBRARY_PATH. In
fact the code looks for resources within the framework, so even if the
dynamic linker was able to resolve all the symbols it still wouldn't
work correctly. Instead of DYLD_LIBRARY_PATH try using
DYLD_FRAMEWORK_PATH and point it at
$HOME/projects/firebird-1.5.2.4731/gen/firebird . Of course you need
to make sure the framework is actually there as well :-)

-John