On 1/15/2016 11:26 AM, mozzis wrote:
You can not change the generator.  It is better to remove the entire
build tree.  Out of source builds are a best practice with CMake.  Once
a build tree has been configured with one compiler, it must be
completely removed to change to a new compiler

Clearly, "can not" is incorrect, since I did. "must be" seems also
incorrect.

You can do it by changing the CMakeCache.txt file, but it won't work in the general case. You should put them in separate directories: build-32 and build-64.
It seems like the developers don't understand about 32-bit vs. 64-bit
builds, or don't intend for this tool to be used with software that is a
product. Determining that after painstakingly configuring all of the build
options, the user must throw it all away in order to build for the other
"bitness", seems wrong. Almost anyone that is intending to build software
that can be installed (without the end user having to build it from source
every time, that way lies madness) needs to produce a 32-bit and a 64-bit
package these days.

You can build both 32 and 64 from the same SOURCE tree, just not the same build tree.

src
build32   (cmake ../src -G"Visual Studio 10 2010")
build64   (cmake ../src -G"Visual Studio 10 2010 Win64")

You seem to be trying to reuse the same build tree for different builds which is not a supported use case. I think if you stopped doing that your life might get easier when working with CMake projects.


-Bill

--

Powered by www.kitware.com

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

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

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

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to