Re: [CMake] static libs and more

2008-07-17 Thread David Cole
On Thu, Jul 17, 2008 at 7:48 PM, Philip Lowman <[EMAIL PROTECTED]> wrote: Does anyone know of any other platforms that share filename extensions for > archive vs. shared libraries other than MSVC/Win32? > The .lib files associated with DLLs on Windows are not really "shared libraries". The DLLs t

Re: [CMake] static libs and more

2008-07-17 Thread Philip Lowman
On Thu, Jul 17, 2008 at 6:25 PM, Alin M Elena <[EMAIL PROTECTED]> wrote: > Hi All, > > I do not really think is any need to test if the lib is static or dynamic. > In real life you should already now that. > > Let us take as an example a package XXX we know from documentation that > provides a st

Re: [CMake] static libs and more

2008-07-17 Thread clinton
I also noticed that dumpbin /exports mylib.lib printed symbols out if it was an import library, but didn't if it was a static library. Clint On Thursday 17 July 2008 3:03:02 pm David Cole wrote: > If you do...: > dumpbin /symbols mylib.lib > > ...then: > The output will contain "_IMPORT_DESCRIP

Re: [CMake] static libs and more

2008-07-17 Thread Alin M Elena
Hi All, I do not really think is any need to test if the lib is static or dynamic. In real life you should already now that. Let us take as an example a package XXX we know from documentation that provides a static link libA.lib and a dynamic link libB.lib (windows case). i want to write a mod

Re: [CMake] static libs and more

2008-07-17 Thread David Cole
If you do...: dumpbin /symbols mylib.lib ...then: The output will contain "_IMPORT_DESCRIPTOR" if the .lib is an import library for a .dll file. It will (most likely) not contain this output if it is a static .lib file. It's a heuristic as I'm pretty sure the static .lib file will contain that ou

Re: [CMake] static libs and more

2008-07-17 Thread David Cole
If you do...: dumpbin /symbols mylib.lib ...then: The output will contain "_IMPORT_DESCRIPTOR" if the .lib is an import library for a .dll file. It will (most likely) not contain this output if it is a static .lib file. It's a heuristic as I'm pretty sure the static .lib file will contain that ou

Re: [CMake] static libs and more

2008-07-17 Thread Philip Lowman
.. Original Message ... On Thu, 17 Jul 2008 22:10:11 +0400 "Yuri Timenkov" <[EMAIL PROTECTED]> wrote: >On Thursday 17 July 2008 23:00:15 Alin M Elena wrote: >The main problem AFAIK for VS is that static and dynamic libraries are >indistinguishable by extension. They both have a .lib on

Re: [CMake] static libs and more

2008-07-17 Thread Alin M Elena
Hi, > The main problem AFAIK for VS is that static and dynamic libraries are > indistinguishable by extension. They both have a .lib one. And you don't > know in advance is some library is static one or just import library for > some dynamic one. > > For cygwin/mingw things may be more similar to

Re: [CMake] static libs and more

2008-07-17 Thread Yuri Timenkov
On Thursday 17 July 2008 23:00:15 Alin M Elena wrote: > Hi, > > 1. Few days ago maybe weeks on the list I have seen a discussion about > static/dynamic linking. > > One of the solution proposed there to achieve a static linking was > > if (UNIX) > set(CMAKE_FIND_LIBRARY_SUFFIXES ".a;.so") > endif

[CMake] static libs and more

2008-07-17 Thread Alin M Elena
Hi, 1. Few days ago maybe weeks on the list I have seen a discussion about static/dynamic linking. One of the solution proposed there to achieve a static linking was if (UNIX) set(CMAKE_FIND_LIBRARY_SUFFIXES ".a;.so") endif(UNIX) Something similar can be done for windows I suspect. Maybe yo