Re: [CMake] problem compiling with cmake

2011-03-28 Thread Michael Hertling
On 03/28/2011 04:47 PM, João Oliveira wrote: Hello, I am a student of Instituto Politecnico de Castelo Branco from Portugal and I having some problems compiling it is necessary to run the toolbox PCL. I am using cmake 2.8.4 and when I try to compile cminpack 1.0.4 the following error

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread Michael Hertling
On 03/28/2011 08:23 PM, David Doria wrote: I have setup a list of definitions: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} UNIX;) SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} PIXEL_DIMENSION=3;) I display them and apply them to my executable as follows:

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread Michael Hertling
On 03/29/2011 07:47 AM, Michael Hertling wrote: On 03/28/2011 08:23 PM, David Doria wrote: I have setup a list of definitions: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} UNIX;) SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} PIXEL_DIMENSION=3;) I display them and apply them

Re: [CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-24 Thread Michael Hertling
On 03/24/2011 03:44 PM, David Doria wrote: Is there a way to explicitly set the CMAKE_CXX_FLAGS for a particular executable? That is, if I set CMAKE_CXX_FLAGS and then have a add_executable line, then change CMAKE_CXX_FLAGS and then have another add_executable, will the first set of

Re: [CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-24 Thread Michael Hertling
On 03/24/2011 11:39 PM, David Doria wrote: On Thu, Mar 24, 2011 at 11:31 AM, Yuri Timenkov y...@timenkov.ru wrote: Use COMPILE_FLAGS target property. Like this: set_target_properties(Exec2 PROPERTIES COMPILE_FLAGS /flag1 /flag2) You can see full list of properties in CMake documentation.

Re: [CMake] FIND_LIBRARY and PATH_SUFFIXES: documentation or implementation bug

2011-03-24 Thread Michael Hertling
On 03/24/2011 10:55 AM, Marcel Loose wrote: Hi all, I stumbled upon this issue, while trying to track down why FindPythonLibs finds the static library libpython2.6.a in /usr/lib64/python2.6/config, instead of the shared library libpython2.6.so in /usr/lib64 on my system. On my system,

Re: [CMake] Building a DLL and test driver EXE using CMake -- error by design?

2011-03-23 Thread Michael Hertling
Of Michael Hertling Sent: Tuesday, March 22, 2011 7:30 PM To: cmake@cmake.org Subject: Re: [CMake] Building a DLL and test driver EXE using CMake -- error by design? [my original elided for brevity --CRV] The TARGET_LINK_LIBRARIES() command works transitively, i.e. TestDriver will be linked

Re: [CMake] Building a DLL and test driver EXE using CMake -- error by design?

2011-03-23 Thread Michael Hertling
On 03/23/2011 05:26 PM, Chris Volpe ARA/SED wrote: Jc- Thanks for the suggestions, but it's not clear if your suggestions are general suggestions, or if they actually address the problem I'm experiencing. Moreover, the problems that your suggestions claim to solve seem to be problems

Re: [CMake] how to place all executables in /build/bin directory

2011-03-22 Thread Michael Hertling
On 03/22/2011 11:33 PM, Jean-Christophe Fillion-Robin wrote: Hi Arvind, As documented herehttp://www.cmake.org/cmake/help/cmake2.6docs.html#variable:CMAKE_RUNTIME_OUTPUT_DIRECTORY, set the variable CMAKE_RUNTIME_OUTPUT_DIRECTORY instead. Usually I set this one just after I invoke

Re: [CMake] Building a DLL and test driver EXE using CMake -- error by design?

2011-03-22 Thread Michael Hertling
On 03/22/2011 03:16 PM, Chris Volpe ARA/SED wrote: I posted this question in the VTK Users mailing list originally, but have since determined that it is more of a CMake issue than a VTK issue, and the involvement of VTK is only tangential. I am trying to set up a source tree which will

Re: [CMake] One too many ../ instances in the relative paths generated by file(GLOB_RECURSE variable RELATIVE ...)

2011-03-19 Thread Michael Hertling
On 03/18/2011 09:28 PM, Alan W. Irwin wrote: I am using the following CMake code fragment to collect file depends for a custom target that generatates doxygen documentation: # Collect essentially same source code dependencies that are in Doxyfile # including most of the template

Re: [CMake] Is is possible to append to default module path?

2011-03-18 Thread Michael Hertling
On 03/18/2011 10:27 PM, Orion Poplawski wrote: I would like to have the standard cmake module path searched first before a local projects path. Is this possible to do? SET(CMAKE_MODULE_PATH ${CMAKE_ROOT}/Modules local-project-path) Regards, Michael

Re: [CMake] Adding new language.

2011-03-17 Thread Michael Hertling
On 03/15/2011 06:30 PM, arrowdodger wrote: On Tue, Mar 15, 2011 at 12:20 PM, Michael Wild them...@gmail.com wrote: Just one warning: AFAIK these rule variables are only used for Makefile-based generators, *NOT* for Xcode and VisualStudio and the like. I'd prefer the route via

Re: [CMake] No LANG_FLAGS_CONFIG target property.

2011-03-16 Thread Michael Hertling
On 03/15/2011 06:13 AM, Óscar Fuentes wrote: Michael Hertling mhertl...@online.de writes: So you add global compiler flags which are not meant to be global? A usual person would say: then do not set them globally!. It's really that simple... No, I want to replace those automatically

Re: [CMake] Adding new language.

2011-03-14 Thread Michael Hertling
On 03/14/2011 03:15 PM, arrowdodger wrote: Hello. I'm using CMake as build system for a C/CXX project and i've faced the following problem: I need to compile some sources as bytecode for VM. This is achieved by using different linker (with different flags) and, probably, different compiler. At

Re: [CMake] Adding new language.

2011-03-14 Thread Michael Hertling
On 03/14/2011 06:42 PM, arrowdodger wrote: On Mon, Mar 14, 2011 at 7:16 PM, Michael Hertling mhertl...@online.dewrote: 2) If you collect the affected files in a separate directory - which is probably recommendable anyway - you might set CMAKE_C_COMPILE_OBJECT

Re: [CMake] No LANG_FLAGS_CONFIG target property.

2011-03-14 Thread Michael Hertling
On 03/14/2011 11:55 PM, Óscar Fuentes wrote: Hendrik Sattler p...@hendrik-sattler.de writes: The COMPILE_FLAGS property sets additional compiler flags used to build sources within the target. So it *adds* flags. I want to *set* flags, i.e. replace the existing ones. So you add global

Re: [CMake] adding a custom command with the file name as a target

2011-03-11 Thread Michael Hertling
On 03/11/2011 08:00 PM, David Cole wrote: On Fri, Mar 11, 2011 at 12:05 PM, Jim Newsome jnews...@cmu.edu wrote: Unfortunately it seems that the target needs to have a different name from its dependencies. When building I get: make[2]: Circular CMakeFiles/hello.bin - hello.bin dependency

Re: [CMake] adding a custom command with the file name as a target

2011-03-11 Thread Michael Hertling
dependencies. Regards, Michael PS: If you use CMake 2.8.4, you should refer to the hello executable in the custom command's COMMAND clause by a generator expression. On Fri, Mar 11, 2011 at 2:30 PM, Michael Hertling mhertl...@online.de wrote: On 03/11/2011 08:00 PM, David Cole wrote: On Fri, Mar 11

Re: [CMake] Find Library would not find the library

2011-03-11 Thread Michael Hertling
On 03/10/2011 12:25 AM, Andreas Pakulat wrote: On 09.03.11 21:36:25, Ankur Handa wrote: I'm using find_library to find a library in a given directory but it has many different versions of this library listed as libcxcore.so, libcxcore.so.2.1 and libcxcore.so.2.1.0 I wrote a very simple cmake

Re: [CMake] newbie q - where do I put what in which CMakeLists file? out of source build

2011-03-10 Thread Michael Hertling
On 03/10/2011 03:11 AM, Pierre Abbat wrote: On Wednesday 09 March 2011 13:09:39 Michael Hertling wrote: Could you boil down your project to a minimal but complete example which demonstrates the issues with the header not being found and the files not being placed properly and post it here

Re: [CMake] adjusting CMAKE_Fortran_LINK_EXECUTABLE

2011-03-10 Thread Michael Hertling
On 03/10/2011 03:07 PM, Brad King wrote: On 03/10/2011 03:48 AM, Ilias Miroslav wrote: By default, the current CMAKE_Fortran_LINK_EXECUTABLE consists of several variables: CMAKE_Fortran_COMPILER CMAKE_Fortran_LINK_FLAGS LINK_FLAGS FLAGS OBJECTS -o TARGET LINK_LIBRARIES [snip] selected

Re: [CMake] newbie q - where do I put what in which CMakeLists file? out of source build

2011-03-09 Thread Michael Hertling
On 03/09/2011 05:54 PM, Pierre Abbat wrote: On Wednesday 09 March 2011 10:22:50 Michael Wild wrote: Make the ~/tone12/CMakeLists.txt your main CMake file (i.e. put the project() command in there and all other commands that apply to the whole project) and add a add_subdirectory(src) call, and

Re: [CMake] CMake command line arguments

2011-03-07 Thread Michael Hertling
On 03/06/2011 12:12 PM, Gabriel Petrovay wrote: Hi, Is there a way to read the arguments that were passed to CMake from inside a CMakeLists.txt file? There is a problem that some generators (like NMake Makefiles) set a default value for certain variables (like CMAKE_BUILD_TYPE=Debug,

Re: [CMake] CMake command line arguments

2011-03-07 Thread Michael Hertling
On 03/07/2011 11:33 AM, Michael Hertling wrote: On 03/06/2011 12:12 PM, Gabriel Petrovay wrote: Hi, Is there a way to read the arguments that were passed to CMake from inside a CMakeLists.txt file? There is a problem that some generators (like NMake Makefiles) set a default value

Re: [CMake] CMake command line arguments

2011-03-07 Thread Michael Hertling
and CMAKE_INSTALL_PREFIX anymore - possibly an issue to consider. On Mon, Mar 7, 2011 at 12:20 PM, Michael Hertling mhertl...@online.de wrote: On 03/07/2011 11:33 AM, Michael Hertling wrote: On 03/06/2011 12:12 PM, Gabriel Petrovay wrote: Hi, Is there a way to read the arguments that were passed

Re: [CMake] Looking for advice on creating targets that use external packages

2011-03-02 Thread Michael Hertling
On 03/01/2011 04:52 PM, L. A. Pritchett-Sheats wrote: Thanks for the reply. Just so I understand, is the following statement accurate: FIND_PACKAGE for XXX sets plural XXX_INCLUDE_DIRS and XXX_LIBRARIES which include all the needed include paths and libraries to compile and build anything

Re: [CMake] Is there an elegant way to get list of object files participating into a library?

2011-02-27 Thread Michael Hertling
On 02/27/2011 10:38 PM, Pere Mato Vila wrote: Hi, For the Windows platform I am generating the .DEF files with all defined symbols to be exported. For this I need to get the list of all object files (.obj) participating into a library. The question is whether this list is available

Re: [CMake] How too set properties on all executables

2011-02-24 Thread Michael Hertling
On 02/24/2011 09:34 PM, Hanna Symanska wrote: Hey, I have a fairly large project with multiple executables, about 90 to be exact and I would like to set the subsystem based on the LINK_FLAGS_* property. Is there a way for me to globally set this up in a top level CMakeLists.txt file so that

Re: [CMake] Looking for advice on creating targets that use external packages

2011-02-24 Thread Michael Hertling
On 02/24/2011 06:00 PM, L. A. Pritchett-Sheats wrote: I'm working on a software project that requires about a dozen external packages to build our libraries. What is the correct way to define the dependencies for our targets that depend on these external libraries? So far I have created

Re: [CMake] Include-Dir order problem

2011-02-15 Thread Michael Hertling
On 02/13/2011 01:27 AM, Andreas Pakulat wrote: Hi, I've got a somewhat tricky problem here with include directories. I'm building a couple of source files and for some of them I need to add an include-directory to the front of the list that cmake passes to the compiler. At the same time

Re: [CMake] detecting build configuration in Visual Studio

2011-02-15 Thread Michael Hertling
On 02/15/2011 03:49 PM, Dominik Szczerba wrote: In MSVC I need to link different libraries depending on the chosen build type. I have two questions: 1) If and how can I register my own build types

Re: [CMake] Include-Dir order problem

2011-02-15 Thread Michael Hertling
On 02/15/2011 07:36 PM, Andreas Pakulat wrote: On 15.02.11 17:54:29, Michael Hertling wrote: On 02/13/2011 01:27 AM, Andreas Pakulat wrote: Hi, I've got a somewhat tricky problem here with include directories. I'm building a couple of source files and for some of them I need to add

Re: [CMake] linking static vs dynamic

2011-02-14 Thread Michael Hertling
. Regards, Michael On Sunday 13 February 2011 12:08:58 AM Dominik Szczerba wrote: Yes, full paths seem to work fine for me. Many thanks for your feedback! Dominik On Sat, Feb 12, 2011 at 11:11 PM, Michael Hertling mhertl...@online.de wrote: On 02/12/2011 09:39 PM, Andreas Pakulat wrote

Re: [CMake] ADD_CUSTOM_COMMAND() cannot depend on ADD_CUSTOM_TARGET()

2011-02-14 Thread Michael Hertling
On 02/15/2011 12:58 AM, John McGehee wrote: I have a custom command that depends on a custom target. In the example below, it is as if ADD_CUSTOM_COMMAND(... DEPENDS t ...) has no effect: # CMakeLists.txt: CMAKE_MINIMUM_REQUIRED(VERSION 2.8 FATAL_ERROR) PROJECT(CUSTOMDEPENDS NONE)

Re: [CMake] Simple (?) problem with libraries executable dependencies

2011-02-14 Thread Michael Hertling
Apart from that, perhaps a MacOSX specialist on this ML can help. Regards, Michael On 14 Feb 2011, at 02:26, Michael Hertling wrote: On 02/14/2011 01:32 AM, Carminati Federico wrote: Hello, I have a problem with the dependencies of an executable. The executable depends on a number of shared

Re: [CMake] Boost macro behavior with respect to version

2011-02-12 Thread Michael Hertling
On 02/10/2011 09:17 PM, Adams, Brian M wrote: I'm curious if the behavior I'm seeing with respect to FindBoost.cmake is expected. (I realize I'm using these macros in a convoluted way, so understand if I can't make it work more cleanly.) What I'd like to be able to do is something like

Re: [CMake] linking static vs dynamic

2011-02-12 Thread Michael Hertling
On 02/12/2011 09:39 PM, Andreas Pakulat wrote: On 12.02.11 21:20:58, Dominik Szczerba wrote: I never actually saw a solution to this problem in cmake: I need to link (independent constraint from above) with libguide.a and not libguide.so (in intel compiler, does not matter much), but both are

Re: [CMake] Question about ADD_CUSTOM_COMMAND

2011-02-12 Thread Michael Hertling
On 02/12/2011 03:00 PM, Carminati Federico wrote: Dear All, I have a question about ADD_CUSTOM_COMMAND. I read in the doc If DEPENDS specifies any target (created by an ADD_* command) a target-level dependency is created to make sure the target is built before any target using this

Re: [CMake] find_package, quiet and yyyConfig files

2011-02-10 Thread Michael Hertling
On 02/10/2011 09:03 AM, Micha Renner wrote: There is a library, which is described with these TLIBConfig.cmake, TLIBConfigVersion.cmake files (The version of the library is 2.1). The library is used by FIND_PACKAGE(TLIB 2.30 QUIET) Is there a way to check the version of the library after

Re: [CMake] feed parsed information from source files into compile process

2011-02-10 Thread Michael Hertling
On 02/10/2011 02:11 PM, Verweij, Arjen wrote: Thanks Tyler, -Original Message- From: Tyler Roscoe [mailto:ty...@cryptio.net] You can't use add_custom_command() to drive this because the results of any custom commands will only be available at build time. You need stuff to happen

Re: [CMake] Recompiles everything every time

2011-02-10 Thread Michael Hertling
On 02/10/2011 09:47 PM, Collier, Jack wrote: I have a large project that I recently converted from autotools to cmake. Everything works great save for the fact that everytime I make the project every single source file is recompiled. I think the reason is that my build relies on a number

Re: [CMake] How to specify $1 for compiler?

2011-02-09 Thread Michael Hertling
On 02/08/2011 08:12 PM, Jed Brown wrote: On Mon, Feb 7, 2011 at 23:35, Jed Brown j...@59a2.org wrote: On Fri, Feb 4, 2011 at 01:31, Michael Hertling mhertl...@online.dewrote: With a Makefile generator, you might use a RULE_LAUNCH_COMPILE property: SET_TARGET_PROPERTIES(target PROPERTIES

Re: [CMake] get_target_property( LOCATION) and CMAKE_DEBUG_POSTFIX (aka: Installing PDB files)

2011-02-07 Thread Michael Hertling
On 02/07/2011 08:54 PM, Mathieu Malaterre wrote: Dear all, I am trying to retrieve the full path of a dll to be able to compute the full path of the associated pdb file. I thought I could simply use the get_target_property( LOCATION) API, however it fails to return the actual name of the

Re: [CMake] FindTCL.cmake has a problem?

2011-02-04 Thread Michael Hertling
with TCL_INCLUDE_PATH==FALSE certainly means some trouble, so this issue should be worth to take a closer look at. Regards, Michael On Wed, Feb 2, 2011 at 6:57 AM, Michael Hertling mhertl...@online.de wrote: On 01/31/2011 05:26 PM, kent williams wrote: I found this out on a RHEL6 machine, which

Re: [CMake] The CMake bug tracker and the backlog of unresolved issues

2011-02-04 Thread Michael Hertling
On 02/03/2011 11:34 PM, David Cole wrote: Hello CMakers, The CMake issue tracker is located at: http://public.kitware.com/Bug All of the issues except for the most recent 15 or so have been assigned and looked at by at least one CMake developer at one point in each issue's history.

Re: [CMake] CMake removing duplicated static libraries from target_link_libraries list?

2011-02-03 Thread Michael Hertling
reported is a bug or has anything to do with libraries treated as static or shared or the like. Of course, feel free to ask further if I missed your issue. Regards, Michael On 2/2/11 4:13 PM, Michael Hertling wrote: On 02/02/2011 03:04 PM, Marco wrote: Hi all, I'm wondering, if I understood

Re: [CMake] How to specify $1 for compiler?

2011-02-03 Thread Michael Hertling
On 02/03/2011 08:30 PM, Jed Brown wrote: I need to build a compilation command of the form win32fe f90 -with -options -and source.f -o path/to/source.f.o but setting CMAKE_Fortran_COMILER=/path/to/win32fe and CMAKE_Fortran_FLAGS=f90 -with -options does not work because CMake places

Re: [CMake] FindTCL.cmake has a problem?

2011-02-02 Thread Michael Hertling
On 01/31/2011 05:26 PM, kent williams wrote: I found this out on a RHEL6 machine, which comes stock with tclsh and wish but without the C header files for development. FindTCL.cmake sets TCL_FOUND, even though TCL_INCLUDE_PATH:PATH=TCL_INCLUDE_PATH-NOTFOUND Imagine the hilarity that

Re: [CMake] Action to perform unconditionally

2011-02-02 Thread Michael Hertling
On 02/02/2011 01:44 PM, Ilja Golshtein wrote: Hello! I am trying to generate version.h in my project as described http://addisu.taddese.com/blog/inserting-svn-revision-number-in-your-cc-code/ I think the most natural place to do it is my project root CMakeLists.txt. The problem is it

Re: [CMake] Action to perform unconditionally

2011-02-02 Thread Michael Hertling
On 02/02/2011 02:27 PM, Ilja Golshtein wrote: Michael, the problematic step is ADD_DEPENDENCIES. I don't have any suitable target. The referred CMakeLists.txt has main/main.c. Unfortunately mine does not - just add_subdirectory. But in the subdirectory, there's a target, isn't it? So,

Re: [CMake] Action to perform unconditionally

2011-02-02 Thread Michael Hertling
On 02/02/2011 03:11 PM, Ilja Golshtein wrote: 02.02.2011, 16:42, Michael Hertling mhertl...@online.de: On 02/02/2011 02:27 PM, Ilja Golshtein wrote: the problematic step is ADD_DEPENDENCIES. I don't have any suitable target. The referred CMakeLists.txt has main/main.c. Unfortunately

Re: [CMake] CMake removing duplicated static libraries from target_link_libraries list?

2011-02-02 Thread Michael Hertling
On 02/02/2011 03:04 PM, Marco wrote: Hi all, I'm wondering, if I understood correctly the behaviour of CMake, whether there'a a way to prevent CMake from deleting duplicated libraries in a target_link_libraries list. I have an executable which links against (all static) libraries A, B

Re: [CMake] namespace support

2011-02-02 Thread Michael Hertling
On 02/02/2011 04:21 PM, Peter Kümmel wrote: On 02.02.2011 16:17, Michael Wild wrote: namespace(a) include_directories(a) add_library(a MODULE a/a.cpp) endnamespace() Put a CMakeLists.txt file in a/ and b/ and do the include_directories() Exactly this is what I don't wanna do

Re: [CMake] Adding a custom line to CMake's makefiles?

2011-02-02 Thread Michael Hertling
On 02/02/2011 03:34 PM, Clifford Yapp wrote: Is there any way to customize the Makefile output from CMake to include user-defined lines (say, something like #include Makefile.inc) at the end of each Make file? With GNU Make, you might do the following: CMAKE_MINIMUM_REQUIRED(VERSION 2.8

Re: [CMake] Find_package: general question

2011-01-26 Thread Michael Hertling
On 01/21/2011 02:59 PM, Vincent Garcia wrote: Dear CMake users, I have this BIG project which has tons of subdirectories (many levels). In each (final) subdirectory, I create targets (executables and libraires). So I have my top level CMakeLists.txt and one CMakeLists.txt file (which is

Re: [CMake] Produce only an object file (*.o) from a CMake build target

2011-01-25 Thread Michael Hertling
On 01/24/2011 06:37 PM, Helseth, Nicholas H wrote: I'm trying to build an object file using CMake, but I can't seem to get CMake to build something other than a complete executable. I'm basically looking for the result of the following compilation (the result will be loaded on a VxWorks

Re: [CMake] Restrictions on where a binary can be put?

2011-01-25 Thread Michael Hertling
On 01/21/2011 08:47 AM, Andreas Pakulat wrote: On 21.01.11 01:37:41, Michael Hertling wrote: So, what's your conclusion in this matter? Should the behavior in question be considered as a bug or is it alright? IMO, such a subtle side effect of a read operation on a subsequent write operation

Re: [CMake] Restrictions on where a binary can be put?

2011-01-25 Thread Michael Hertling
On 01/21/2011 04:41 PM, Alexander Neundorf wrote: On Friday 21 January 2011, Michael Hertling wrote: On 01/20/2011 07:01 PM, Alexander Neundorf wrote: On Sunday 09 January 2011, Michael Hertling wrote: ... I don't really understand why you want to get the LOCATION from your target, anyway

Re: [CMake] add_custom_command and generated true

2011-01-25 Thread Michael Hertling
On 01/25/2011 10:17 AM, Micha Renner wrote: Recently, I learned that ADD_CUSTOM_COMMAND generated the property GENERATED TRUE for the generated file. Somehow I have trouble in this situation: In a top level CMakeLists file a source file, blue.c, is generated. This file should be used in a

Re: [CMake] Restrictions on where a binary can be put?

2011-01-20 Thread Michael Hertling
On 01/20/2011 07:01 PM, Alexander Neundorf wrote: On Sunday 09 January 2011, Michael Hertling wrote: On 01/09/2011 09:47 PM, Nizar Khalifa Sallem wrote: At Sun, 09 Jan 2011 21:42:49 +0100, Michael Hertling wrote: On 01/09/2011 09:09 PM, Andreas Pakulat wrote: On 09.01.11 21:05:21, Andreas

Re: [CMake] Does PATH_SUFFIXES work?

2011-01-18 Thread Michael Hertling
On 01/19/2011 06:00 AM, Jack Poulson wrote: I've thoroughly read through the CMake documentation for the 2.8 release and for the life of me I can't seem to get a simple case working for find_library using PATH_SUFFIXES. For instance, I am trying to find the library libiomp5.a located at

Re: [CMake] text file modifications while Install

2011-01-17 Thread Michael Hertling
On 01/17/2011 02:53 PM, Ilja Golshtein wrote: Hello, list, please, suggest proper way to do some text file modifications while Install. Basically I need something similar with RPATH change Cmake does, but against a configuration file. Currently I create amended version of the config

Re: [CMake] retrieve the path of an object file

2011-01-14 Thread Michael Hertling
On 01/14/2011 12:17 PM, Andrea Galeazzi wrote: Given a source file (path/foo.c), does CMake provide a way to retrieve the obj file path/filename generate by the compiler? With the Makefile generators, you might use the RULE_LAUNCH properties to intercept the compiling/linking phase, including

Re: [CMake] problem getting defines quoted properly

2011-01-14 Thread Michael Hertling
On 01/14/2011 08:25 PM, Andreas Pakulat wrote: Hi, I'm trying to set a define so that it can be used as string-literal in C++ code using add_definitions. This: add_definition( -DMYFOO=\BAR BAZ\ ) works fine on linux, but breaks with MSVC6 on windows. I always thought I understood

Re: [CMake] conditional selection of either local just built or system versions of a library

2011-01-12 Thread Michael Hertling
On 01/11/2011 05:46 PM, Marco wrote: Dear CMake experts, I'm facing the following problem. I have a project with many subdirectories, all at the same hierarchical level: /my/project/path/CMakeLists.txt /my/project/path/A - include |- src |-

Re: [CMake] CMake Error: Error required internal CMake variable not set, ...

2011-01-12 Thread Michael Hertling
On 01/12/2011 04:29 PM, Enrique Izaguirre wrote: Hello, I am new to CMake and following a few examples, I am now trying to cross-compile a C++ program from Cygwin to Linux, and I got the following errors: CMake Error: Error required internal CMake variable not set, cmake may be not be

Re: [CMake] CPack and configure_file

2011-01-11 Thread Michael Hertling
On 01/11/2011 09:48 AM, Eric Noulard wrote: 2011/1/11 Michael Hertling mhertl...@online.de: On 01/11/2011 12:55 AM, Tobias Ellinghaus wrote: Because some information (like latest git commit as version string) is no longer available when using a source package. Of course I can put

Re: [CMake] add_subdirectory and link_directories

2011-01-10 Thread Michael Hertling
On 01/10/2011 06:24 PM, Andrea Galeazzi wrote: I've got a main project which relies on several sub-library projects, so the main CMakeLists.txt add_subdirectory(W:/Omega/Kernel ${CMAKE_CURRENT_BINARY_DIR}/myLib1) ... and then I also specify the directory where all libraries have

Re: [CMake] Restrictions on where a binary can be put?

2011-01-09 Thread Michael Hertling
On 01/09/2011 12:58 PM, Andreas Pakulat wrote: Hi, I'm having a bit of a problem here changing the runtime output directory for a binary. Its an executable target named 'setup' and I'd like to put it into the top-level directory. Unfortunately it always ends up in the bin/ directory, which

Re: [CMake] Restrictions on where a binary can be put?

2011-01-09 Thread Michael Hertling
On 01/09/2011 09:32 PM, Nizar Khalifa Sallem wrote: At Sun, 9 Jan 2011 21:09:37 +0100, Andreas Pakulat wrote: [1 text/plain; us-ascii (7bit)] On 09.01.11 21:05:21, Andreas Pakulat wrote: On 09.01.11 14:24:16, Michael Hertling wrote: On 01/09/2011 12:58 PM, Andreas Pakulat wrote: Hi, I'm

Re: [CMake] Restrictions on where a binary can be put?

2011-01-09 Thread Michael Hertling
On 01/09/2011 09:47 PM, Nizar Khalifa Sallem wrote: At Sun, 09 Jan 2011 21:42:49 +0100, Michael Hertling wrote: On 01/09/2011 09:09 PM, Andreas Pakulat wrote: On 09.01.11 21:05:21, Andreas Pakulat wrote: On 09.01.11 14:24:16, Michael Hertling wrote: On 01/09/2011 12:58 PM, Andreas Pakulat

Re: [CMake] Installing Python Modules with CMake

2011-01-06 Thread Michael Hertling
On 01/04/2011 08:50 AM, Michael Wild wrote: On 01/03/2011 06:23 PM, Todd Gamblin wrote: On Jan 3, 2011, at 1:34 AM, Michael Wild wrote: On 01/03/2011 09:11 AM, Todd Gamblin wrote: Is there some standard way in CMake to get a project-local install destination for python libraries, e.g.:

Re: [CMake] How to find the path to the currently include() or find_package file()

2011-01-03 Thread Michael Hertling
On 01/04/2011 05:47 AM, John McGehee wrote: I am using CMake 2.8 on Linux and Windows. When I include() or find_package() a .cmake file, is there a variable that I can use within the included .cmake file that will tell me its path? For example, # In CMakeLists.txt

Re: [CMake] How to find the path to the currently include() or find_package file()

2011-01-03 Thread Michael Hertling
On 01/04/2011 07:41 AM, Michael Hertling wrote: On 01/04/2011 05:47 AM, John McGehee wrote: I am using CMake 2.8 on Linux and Windows. When I include() or find_package() a .cmake file, is there a variable that I can use within the included .cmake file that will tell me its path

Re: [CMake] CMAKE uses wrong symlink to so

2011-01-01 Thread Michael Hertling
On 12/31/2010 03:43 PM, Michael Wild wrote: On 12/31/2010 02:48 PM, Michael Hertling wrote: On 12/31/2010 11:56 AM, Michael Wild wrote: On 12/30/2010 07:55 PM, j s wrote: Hello Michael Wild, I regret deciding to go with an Python parser for my application. I use such a small subset

Re: [CMake] How to make a ProjectConfig.cmake

2010-12-31 Thread Michael Hertling
On 12/30/2010 06:59 PM, Ian Monroe wrote: On Thu, Dec 30, 2010 at 09:42, Michael Wild them...@gmail.com wrote: On 12/30/2010 03:34 PM, Ian Monroe wrote: On Thu, Dec 30, 2010 at 08:08, Michael Hertling mhertl...@online.de wrote: On 12/30/2010 11:33 AM, Ian Monroe wrote: To create my

Re: [CMake] CMAKE uses wrong symlink to so

2010-12-31 Thread Michael Hertling
2.6 is frozen. In the future, the Python people are hoping to stabilize the ABI in the 3 series so that I can just link against a libpython3.so: http://www.python.org/dev/peps/pep-0384/ As stated by Michael Hertling, the symlinks are not being recursively resolved. The soname is encoded

Re: [CMake] CMAKE uses wrong symlink to so

2010-12-30 Thread Michael Hertling
On 12/30/2010 12:28 AM, j s wrote: I specified the full name to an so in CMAKE 2.8.1. Unfortunately it links against the versioned so name, libpython2.6.so.1.0 instead of the exact name I specified. /usr/lib/libpython2.6.so SET (PYTHON_ARCHIVE /usr/lib/libpython2.6.so)

Re: [CMake] How to make a ProjectConfig.cmake

2010-12-30 Thread Michael Hertling
On 12/30/2010 11:33 AM, Ian Monroe wrote: To create my QyotoConfig.cmake I need to know the full path of a library so that I can set a variable like QYOTO_LIBRARY. This is pretty standard requirement right? Its what we're supposed to do in *Config.cmake's? Yes. So anyways, how do I that?

Re: [CMake] FLTKConfig.cmake on Microsoft Windows

2010-12-30 Thread Michael Hertling
On 12/30/2010 11:01 AM, Julia Jacobson wrote: With your help, everything seems to work now. My final subdirectory src/CMakeLists.txt looks like this: SET(FLTK_DIR C:/Program Files/fltk-1.1.9/) SET(FLTK_BASE_LIBRARY C:/Program Files/fltk-1.1.9/lib/) SET(FLTK_FORMS_LIBRARY C:/Program

Re: [CMake] proper setup to create file and have it installed

2010-12-28 Thread Michael Hertling
On 12/28/2010 09:10 AM, edA-qa mort-ora-y wrote: On 12/27/2010 09:51 PM, Michael Hertling wrote: You might use the ALL option of ADD_CUSTOM_TARGET() to incorporate the language target in CMake's all target which, in turn, is built as a prerequisite of the install target. Alternatively

Re: [CMake] Problem building libraries with no sources with Visual Studio 9 (2008)

2010-12-22 Thread Michael Hertling
On Dec 22, 2010, at 12:09 AM, Michael Hertling wrote: On 12/21/2010 08:45 PM, Bill Hoffman wrote: On 12/21/2010 2:17 PM, Michael Hertling wrote: AFAIK, this is because CMake does not know how to handle a .def file for incorporation in the target, i.e. ${library}.def has no LANGUAGE Actually

Re: [CMake] Problem building libraries with no sources with Visual Studio 9 (2008)

2010-12-21 Thread Michael Hertling
On 12/21/2010 04:13 PM, Pere Mato Vila wrote: Dear all, I am trying to build shared libraries on Windows exporting all symbols. This is as an alternative of instrumenting the code with dllimport/dllexport declarations. For this I do build first a static library from which I get all the

Re: [CMake] Problem building libraries with no sources with Visual Studio 9 (2008)

2010-12-21 Thread Michael Hertling
On 12/21/2010 08:45 PM, Bill Hoffman wrote: On 12/21/2010 2:17 PM, Michael Hertling wrote: AFAIK, this is because CMake does not know how to handle a .def file for incorporation in the target, i.e. ${library}.def has no LANGUAGE Actually, it should... Something like this should work

Re: [CMake] granular install advice

2010-12-17 Thread Michael Hertling
On 12/17/2010 03:31 PM, luxInteg wrote: Greetings, I am learning cmake. If I were to have some homebrewed ModulesForCMakeIdiots.cmake from my learning project in say ${CMAKE_SOURCE_DIR}/modules and I set this command:- install(FILES ${CMAKE_SOURCE_DIR}/modules/*.cmake

Re: [CMake] Linking archives in a sibling directory

2010-12-08 Thread Michael Hertling
On 12/03/2010 04:26 PM, Raymond Wan wrote: Hi Michael, Thank you for your continued advice! On Fri, Dec 3, 2010 at 19:13, Michael Hertling mhertl...@online.de wrote: Nevertheless, I wonder why you want to build main by configuring its own source directory and alternatively via the top

Re: [CMake] Dependency rule not included

2010-12-08 Thread Michael Hertling
On 12/08/2010 04:28 PM, Vivien Delmon wrote: On 12/08/2010 04:13 PM, Michael Wild wrote: On 12/08/2010 03:54 PM, Micha Renner wrote: Am Mittwoch, den 08.12.2010, 14:55 +0100 schrieb Vivien Delmon: CMAKE_MINIMUM_REQUIRED(VERSION 2.8) ADD_CUSTOM_COMMAND(OUTPUT toto.h toto.c COMMAND

Re: [CMake] How to apply the --as-needed linker flag?

2010-12-07 Thread Michael Hertling
On 11/28/2010 09:10 AM, Alan W. Irwin wrote: On 2010-11-28 06:39+0100 Michael Hertling wrote: On 11/27/2010 06:45 PM, Alan W. Irwin wrote: I just discovered that many Linux distros these days use the --as-needed Linux linker option by default. At first glance that option makes a lot

Re: [CMake] providing library information, what's the cmake way

2010-12-05 Thread Michael Hertling
On 12/01/2010 05:57 PM, Johannes Zarl wrote: On 12/01/2010 at 16:06, Michael Hertling mhertling at online.de wrote: FIND_PACKAGE(XXX COMPONENTS YYY) ... ADD_SUBDIRECTORY(subdir) ... TARGET_LINK_LIBRARIES(AAA ${XXX_LIBRARIES}) TARGET_LINK_LIBRARIES(BBB ${XXX_LIBRARIES} ${XXX_YYY_LIBRARIES

Re: [CMake] providing library information, what's the cmake way

2010-12-05 Thread Michael Hertling
On 11/30/2010 05:53 AM, Kishore wrote: On Tuesday 23 Nov 2010 5:27:56 pm Johannes Zarl wrote: Another somehow related topic seems to be import/export of targets. Should a LibraryConfig.cmake or FindLibrary.cmake file create imported targets for the library? Thanks for this thread. It has

Re: [CMake] Linking archives in a sibling directory

2010-12-03 Thread Michael Hertling
On 12/02/2010 03:13 PM, Raymond Wan wrote: Hi Michael, On Thu, Dec 2, 2010 at 19:40, Michael Hertling mhertl...@online.de wrote: On 12/01/2010 06:03 PM, Raymond Wan wrote: Ah! I see. Then is it recommended that this top-level CMakeLists.txt have just these lines, or should I move

Re: [CMake] find_package with ###Config.cmake

2010-12-03 Thread Michael Hertling
On 12/03/2010 08:45 AM, Andreas Pakulat wrote: On 03.12.10 07:11:23, Micha Renner wrote: There is a small library TLib which is installed like this Install the project... -- Install configuration: Debug -- Installing: /usr/local/lib/libTLibd.so -- Installing:

Re: [CMake] Linking archives in a sibling directory

2010-12-02 Thread Michael Hertling
On 12/01/2010 06:03 PM, Raymond Wan wrote: Hi Michael, On Thu, Dec 2, 2010 at 01:03, Michael Hertling mhertl...@online.de wrote: On 12/01/2010 08:18 AM, Raymond Wan wrote: Hi all, I'm having a problem understanding how I can link to an archive in another directory which

Re: [CMake] providing library information, what's the cmake way

2010-12-01 Thread Michael Hertling
On 11/30/2010 01:32 PM, Johannes Zarl wrote: - Do multiple consecutive FIND_PACKAGE(XXX ...) invocations act in an accumulative manner on the invocation-specific variables? Generally speaking, I would say: yes. At least this is the way of the least surprise for the user, as in sufficiently

Re: [CMake] (no subject)

2010-12-01 Thread Michael Hertling
On 12/01/2010 03:45 PM, Gary%20G.%20Little%20%40%20comcast wrote: I have a Visual Studio 2010 solution and I am trying to set the Configuration Properties - General - Platform Toolset of one particular project to use V90 to allow this project to build with the VS 2008 tool set. I followed

Re: [CMake] Linking archives in a sibling directory

2010-12-01 Thread Michael Hertling
On 12/01/2010 08:18 AM, Raymond Wan wrote: Hi all, I'm having a problem understanding how I can link to an archive in another directory which is not a subdirectory. For example: myproj +-- main +-- CMakeLists.txt +-- source files for main program +-- dir-A +--

Re: [CMake] providing library information, what's the cmake way

2010-11-30 Thread Michael Hertling
On 11/29/2010 02:28 PM, Johannes Zarl wrote: Sorry for the late response, but your mail was simply to long for a swift response... No problem, this topic is not exactly trivial. On 11/26/2010 at 05:47, Michael Hertling mhertl...@online.de wrote: On 11/24/2010 04:51 PM, Johannes Zarl wrote

Re: [CMake] Problems to find xmlrpc_server_abyss++.so on FreeBSD

2010-11-30 Thread Michael Hertling
On 11/30/2010 12:27 AM, Renato Botelho wrote: On Mon, Nov 29, 2010 at 9:20 PM, Renato Botelho rbga...@gmail.com wrote: Hi, It's the first project i'm migrating from autotools to cmake, and it's going really well, in 4 days it's almost done. \o/ The only issue I have now is following, i have

Re: [CMake] Relink on library rebuild dilema

2010-11-29 Thread Michael Hertling
On 11/29/2010 05:05 AM, Bill Hoffman wrote: On 11/28/2010 3:19 AM, Sebastian Schaetz wrote: Michael Hertlingmhertl...@... writes: 1) In the top-level CMakeLists.txt, you might say SET_SOURCE_FILES_PROPERTIES( main.cpp PROPERTIES OBJECT_DEPENDS

<    1   2   3   4   5   6   7   8   >