[Cmake-commits] CMake branch, master, updated. v3.15.0-rc2-113-gf2bce26

2019-06-21 Thread Kitware Robot
t a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake index ad0386e..8494d39 100644 --- a/Source/CMakeVersion.cmake +++ b/Source/CMakeVersion.cmake @@ -1,5 +1,5 @@ # CMake version number components. set(CMake_VERSION_MAJOR 3) set(CMake_VERSION_MINOR 15) -set(CMake_VERSION_PATCH 20190621) +set(CMake_VER

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread Michael Jackson
David, I think a bit more explanation of the philosophy (at least how I interpret it) is needed. I see in your emails that you are “targeting makefiles”. With CMake you need to really stop thinking this way. Rarely do you need to target any specific build system (although those times do

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Aldrich
> > > What would best practice be to provide convenient commands for our > > developers to easily build the target ? > > For the Makefile generator, best practice is to use separate build > directories (i.e., places where you run cmake) for different > configurations (i.e., different settings

[CMake] using variables in ExternalProject_Add arguments

2019-06-21 Thread Kris Thielemans
Dear all We have a Superbuild https://github.com/CCPPETMR/SIRF-SuperBuild. I'm trying to introduce variables to reduce duplication. However, I'm getting weird errors. 2 examples below. Any ideas? (I'm running this on Windows 10 at present with CMake 3.13.2). Many thanks Kris 1.

[Cmake-commits] CMake branch, master, updated. v3.15.0-rc2-112-g12c65a5

2019-06-21 Thread Kitware Robot
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "CMake". The branch, master has been updated via 12c65a52bd3c8eee564cf766a260b98602942a5f (commit) via

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread Braden McDaniel
On Fri, 2019-06-21 at 15:28 +0100, David Aldrich wrote: > > > I would also like this to work if I use the make targets e.g. > > make > > > debug. > > > > I think that's outside the scope of the Makefile generator. For > > that > > generator, CMAKE_BUILD_TYPE is a configuration-wide setting. If

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Aldrich
> > > I would also like this to work if I use the make targets e.g. make > > debug. > > I think that's outside the scope of the Makefile generator. For that > generator, CMAKE_BUILD_TYPE is a configuration-wide setting. If you > want a different configuration, you need a different build

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread Braden McDaniel
On Fri, 2019-06-21 at 14:19 +0100, David Aldrich wrote: > Thanks for the help I have received in the past few days. I am making > incremental improvements to my CMake project and have a new > challenge. I am running CMake 3.13 on Centos 7.6, targeting make. > My CMake file successfully builds

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Demelier
Le 21/06/2019 à 15:42, David Aldrich a écrit : Do never test CMAKE_BUILD_TYPE in CMakeLists.txt files, it is ignored in multiple generators (e.g. Visual Studio). Does that mean I shouldn't have this in CMakeLists.txt? : # Specify a Release build by default if(NOT CMAKE_BUILD_TYPE)

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Aldrich
> > Do never test CMAKE_BUILD_TYPE in CMakeLists.txt files, it is ignored in > multiple generators (e.g. Visual Studio). > Does that mean I shouldn't have this in CMakeLists.txt? : # Specify a Release build by default if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release") message(STATUS

Re: [CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Demelier
Le 21/06/2019 à 15:19, David Aldrich a écrit : I now want to support separate target directories: build/debug and build/release.  I've shown my CMakeLists.txt below. So far I've just added an attempt to support build/debug: if (CMAKE_BUILD_TYPE EQUAL "DEBUG")     message("debug mode")    

[CMake] How to support separate debug and release build directories?

2019-06-21 Thread David Aldrich
Thanks for the help I have received in the past few days. I am making incremental improvements to my CMake project and have a new challenge. I am running CMake 3.13 on Centos 7.6, targeting make. My CMake file successfully builds debug or release targets and puts the executable in an

[CMake] Building a c++ library using CMake in Android Studio

2019-06-21 Thread dexter810
I built this C++ library using CMake 3.10.2 in Ubuntu 18.04 and it was built successfully. I'm trying to build it using the same CMakeLists.txt and folder structure in Android Studio which is also using Cmake 3.10.2. On running inspection results inside Android Studio, inside C++, declaration

Re: [CMake] How to specify Redhat Developer Toolset compiler?

2019-06-21 Thread David Aldrich
Thanks for all the replies. I decided to set CC and CXX in .bashrc: source scl_source enable devtoolset-7 export CXX="/opt/rh/devtoolset-7/root/usr/bin/g++" export CC="/opt/rh/devtoolset-7/root/usr/bin/gcc" For reference, the FAQ entry is:

Re: [CMake] ExternalProjectAdd and patch on Windows

2019-06-21 Thread Kris Thielemans
Thanks Cristian That works wonderfully! Kris From: Cristian Adam Sent: 20 June 2019 12:28 To: Kris Thielemans Cc: CMake Mail List Subject: Re: [CMake] ExternalProjectAdd and patch on Windows Hi, If the users have git installed, you could try find_program(git...), and then