[CMake] Adding additional libraries at configuration or building time

2009-05-26 Thread Alberto Luaces
Hello, is there any way of appending additonal libraries to a CMake project without touching the CMakeLists.txt file? Something like cmake EXTRA_LIBS=-lfoo . or make EXTRA_LIBS=-lfoo My problem is that I have a system where some additonal system libraries are required at the end of the link

Re: [CMake] Mixing C/CPP and Fortran

2009-05-26 Thread Arjen Markus
Hello Alin, why not try to make Fortran the main language? If the linking step occurs via the Fortran compiler, then that should take care of the Fortran runtime libraries. This strategy won't work if you have C++ included in the mix, though - C++ requires the C++ compiler to do the linking, if I

Re: [CMake] Exclude file from build on a given target

2009-05-26 Thread Philip Lowman
If you want to exclude certain source files from certain targets you can use a list and then list(REMOVE_ITEM...) set(FOO_SRCS foo.cc bar.cc) list(REMOVE_ITEM FOO_SRCS bar.cc) add_library(foo ${FOO_SRCS}) Alternatively, only add the unusual source files to the targets you want. set(FOO_SRCS foo.

[CMake] Exclude file from build on a given target

2009-05-26 Thread Daniel Tavares
Is it possible to exclude a file from build for a specific build target? As far as I could read on the documentation and discussion threads, setting HEADER_FILE_ONLY to TRUE changes the file property for all targets. I'm converting a Visual Studio 2005 project to CMake and this project excludes

Re: [CMake] How to get the evaluated path to a target - MSVC

2009-05-26 Thread Steve Huston
Thanks, David. I put your ideas into the PowerShell script that sets up and runs my tests. It's working... -Steve -Original Message- From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf Of David Cole Sent: Saturday, May 23, 2009 7:38 AM To: Dmitry Bely Cc: cmake@cma

[CMake] Macro callbacks

2009-05-26 Thread KSpam
Is it possible to call variable macro names from within another macro? The following is a simple (non-working) example of what I would like to do: macro (do_something callback) # Call the callback macro and pass a message argument ${callback}("Hello world

Re: [CMake] cmake-gui app: Remember position/size

2009-05-26 Thread Robert Dailey
On Tue, May 26, 2009 at 3:07 PM, Clinton Stimpson wrote: > > It doesn't have that option. > > Feel free to put it in the bug tracker, or it gets forgotten. I wanted to confirm before I create a bug report. > Also feel free to submit a patch. I would love to, if I didn't have a job, a family,

Re: [CMake] cmake-gui app: Remember position/size

2009-05-26 Thread Clinton Stimpson
It doesn't have that option. Feel free to put it in the bug tracker, or it gets forgotten. Also feel free to submit a patch. Clint Robert Dailey wrote: Does the cmake-gui application on Windows have any option to enable the serialization of window size/position, as well as any divider positi

[CMake] cmake-gui app: Remember position/size

2009-05-26 Thread Robert Dailey
Does the cmake-gui application on Windows have any option to enable the serialization of window size/position, as well as any divider position? I like to make the window slightly larger and move the divider upwards so that the output window (bottom) is larger than the variables list (top). However,

Re: [CMake] Mixing C/CPP and Fortran

2009-05-26 Thread Alin M Elena
Hi Kyle, My personal opinion is that cmake should handle correctly and generate a binary in this case. libhello.a is generated by the project and is intended for the use within the project so cmake should do it. with shared libs things are ok. regards, Alin --

Re: [CMake] Mixing C/CPP and Fortran

2009-05-26 Thread Kyle Horne
On Tue, 26 May 2009 18:01:17 +0100 Alin M Elena wrote: > Hi All, > > > I try to mix some C and Fortran (I know not such a good idea). > > Anyhow I create a project and then use cmake to manage the build. (see attach) > C is the main language, if I may say so, It links. > > I get a linking err

[CMake] Mixing C/CPP and Fortran

2009-05-26 Thread Alin M Elena
Hi All, I try to mix some C and Fortran (I know not such a good idea). Anyhow I create a project and then use cmake to manage the build. (see attach) C is the main language, if I may say so, It links. I get a linking error Linking C executable bin/testme /usr/bin/cmake -E cmake_link_script CMak

Re: [CMake] VS2010 support

2009-05-26 Thread Bill Hoffman
Tyler Roscoe wrote: On Tue, May 26, 2009 at 12:32:20PM +0200, bielow wrote: Currently it seems that only NMake works since any previous VS generator version will trigger the conversion wizard and then in turn cmake again... There is a CMake variable which can disable the rule that makes CMake

Re: [CMake] VS2010 support

2009-05-26 Thread Tyler Roscoe
On Tue, May 26, 2009 at 12:32:20PM +0200, bielow wrote: > Currently it seems that only NMake works since any previous VS generator > version will trigger the conversion wizard and then in turn cmake again... There is a CMake variable which can disable the rule that makes CMake rerun when things ge

Re: [CMake] Problem with CTest and adding subdirectory

2009-05-26 Thread Eric Noulard
2009/5/26 Robert Matusewicz : > Hi all! > We are using Cmake and CTest in our project: OpenImageIO and have a liitle > problem. > We have project tree that looks like belowe: > * project > testsuit > src > ** test1 > ** test2 > And then, in CmakeList.txt we have something like tha

[CMake] VS2010 support

2009-05-26 Thread bielow
Hi, is there a roadmap VS2010 support?! Beta1 is out now. Currently it seems that only NMake works since any previous VS generator version will trigger the conversion wizard and then in turn cmake again... Regards, Chris ___ Powered by www.kitware.com

[CMake] Why "install" target depends on "all"?

2009-05-26 Thread Denis Scherbakov
I have a huge project with many libs and executables, but not all of them need to be installed. I'd say that only 20% of them have INSTALL command. When I issue "gmake install" the rest (80%) gets built and then only those 20% get installed. I thought that "install" must contain only a list of

[CMake] Set CMAKE_TOOLCHAIN_FILE from cmake-gui

2009-05-26 Thread Roland Waltersson
Hi, I am trying to get a user to choose target from cmake-gui, with: SET(TARGET "x86" CACHE STRING "Target (x86 or arm)") #some code here to construct CMAKE_TOOLCHAIN_FILE from TARGET variable This however don't work as the compiler settings are initialized when cmake-gui starts, not when the use

[CMake] Problem with CTest and adding subdirectory

2009-05-26 Thread Robert Matusewicz
Hi all! We are using Cmake and CTest in our project: OpenImageIO and have a liitle problem. We have project tree that looks like belowe: * project testsuit src ** test1 ** test2 And then, in CmakeList.txt we have something like that: include (CTest) add_subdirectory (test1) add_su

Re: [CMake] Problem with ASM and COMPILE_DEFINITIONS

2009-05-26 Thread Marcel Loose
Hi Tyler, Actually, I was hoping that CMake would not pass on any preprocessor definitions to the assembler, because -D is in general not understood by an assembler as a preprocessor directive. Do I need to change any of the CMakeASM*Information, CMakeDetermineASM*Compiler or CMakeTestASM*Compiler