I have to check in CMake script if I have a 32-bit or a 64-bit Linux in order to know how to build a C++ program. Which command is the best choice :
- getconf LONG_BIT
- arch
- uname -m
I have to check in CMake script if I have a 32-bit or a 64-bit Linux in order to know how to build a C++ program. Which command is the best choice :
Using CMake one possible way is to check the CMAKE_SIZEOF_VOID_P variable: