Hi all,

I have a program that uses an external library whose path name depends on its version (32 or 64 bit).

Is there a direct way in cmake to test whether my cpu is 32 or 64 bit ?

The one I found up to now is the following:

if(CMAKE_SIZEOF_VOID_P EQUAL 8)
   set(arch_64 TRUE)
else()
    set(arch_64 FALSE)
endif()

thanks a lot and merry Christmas !

Eric


--
Eric Pellegrini
Calcul Scientifique
Institut Laue-Langevin
Grenoble, France

--

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 via email to