[CMake] How do I allow an ExternalProject to fail?

2015-11-13 Thread Nicholas Braden
I want to use ExternalProject_Add to download a git repository and try to compile it, and allow it to fail so I can either fall back on another method or disable certain functionality in my project. It looks like try_compile can try to compile a whole project, but I am not sure of an easy way to us

[CMake] CMake port to OpenVMS - confusing behavior in cmliblzma code tree, specifically the config.h file generated from config.h.in

2015-11-13 Thread Custin, Jay (CSC Sw Middleware)
After somewhat of an archeological dig I have finally traced down the following error message: [ 12%] Building C object Utilities/cmliblzma/CMakeFiles/cmliblzma_dir/liblzma/check/check.c.o cd /PRJ_ROOT/CMAKE-3_3_2/Utilities/cmliblzma && /bin/cc -Wc/warnings=disable=all/lis/show=all -w -I/PRJ_

Re: [CMake] Executable using a library (.a or .so)

2015-11-13 Thread J Decker
On Fri, Nov 13, 2015 at 9:51 AM, J Decker wrote: > is this library required to be separate from the executable? > If not; it's far easier... > # in MyLib/CmakeLists.txt > add_library( MyLib libsource1.c > libsource2.cpp ) # in MyExe/CmakeLists.txt > add_exectubable( MyExe exesource1.c ) > targe

Re: [CMake] Executable using a library (.a or .so)

2015-11-13 Thread J Decker
is this library required to be separate from the executable? If not; it's far easier... add_library( MyLib libsource1.c libsource2.cpp ) add_exectubable( MyExe exesource1.c ) target_link_libraries( MyExe MyLib ) On Fri, Nov 13, 2015 at 9:28 AM, houssen wrote: > Hello, > > How to write a librar

[CMake] Executable using a library (.a or .so)

2015-11-13 Thread houssen
Hello, How to write a library (myLib as .a or .so) that can be used from an executable (myExe) ? I read the CMake doc but, obviously, I still miss some major points !... My understanding is that, I need : - to write a FindMyLib.cmake for myExe to find myLib (= finding include/library directo

Re: [CMake] Benchmarking with CMake

2015-11-13 Thread Nagy-Egri Máté Ferenc via CMake
Thank you all for your resonses, My use case is that I have a set of executables that function as unit tests. Currently I use the return value of the .exe as a means of indicating success, though I know there is way to match std::cout against a regex for more complex tests. However, the timings