Quantcast

Detect 64 bit library when doing find_library?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Detect 64 bit library when doing find_library?

James Bigler
Is it possible to detect if find_library has found a 32 or 64 bit library on windows?

Thanks,
James

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Detect 64 bit library when doing find_library?

David Cole
Not easily and directly via a cmake property or variable....

But you could use output from "dumpbin" to analyze the found library.

"dumpbin /?" from a Visual Studio command prompt will get you started.

For example, if you do a:
dumpbin /headers mylib.lib

You should see a line in the output like:
  Machine      : 14C (x86)

(for an x86, 32-bit build --- and other text for the different 64-bit builds...)


HTH,
David


On Thu, Jul 9, 2009 at 5:27 PM, James Bigler <[hidden email]> wrote:
Is it possible to detect if find_library has found a 32 or 64 bit library on windows?

Thanks,
James

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
Loading...