[CMake] FIND_LIBRARY finding .dylib or .a

2007-07-31 Thread Mike Jackson
what is the magic incantation to tell FIND_LIBRARY to prefer .dylibs  
instead of .a (shared vs static)? I have what seem to be the same  
command yet one will find the .a and the other will find the .dylib.  
The commands look the same to me?


Any help is appreciated.. cmake --help-command FIND_LIBRARY wasn't  
any help


This is with cmake 2.4.6 on OS X 10.4.10 (intel)
--
Mike Jackson
imikejackson  gmail * com



___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] FIND_LIBRARY finding .dylib or .a

2007-07-31 Thread Brandon Van Every
On 7/31/07, Mike Jackson [EMAIL PROTECTED] wrote:
 what is the magic incantation to tell FIND_LIBRARY to prefer .dylibs
 instead of .a (shared vs static)? I have what seem to be the same
 command yet one will find the .a and the other will find the .dylib.
 The commands look the same to me?

 Any help is appreciated.. cmake --help-command FIND_LIBRARY wasn't
 any help

 This is with cmake 2.4.6 on OS X 10.4.10 (intel)

Static linkage is officially depreciated on OS X.  The MacOS linker
does extremely obnoxious things like grabbing any dynamic library
available anywhere in preference to the static library you name, if
the static and dynamic libraries have the same name.  This has nothing
to do with CMake per se.  Autotools works its way around this problem
somehow apparently, but the correct answer for almost everybody is not
to do static linking on OS X at all.


Cheers,
Brandon Van Every
___
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake