Re: [CMake] qt .qrc file modifications require two builds

2009-12-17 Thread Brad King
Clinton Stimpson wrote: If I specify the input (path to test.h.in) & output (path to generated test.h) for the "CMake Rules" build phase, the problem goes away. Maybe we can put all inputs and all outputs in there for generated files in that project? The script (makefile) it calls already has t

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Clinton Stimpson
On Dec 16, 2009, at 5:36 PM, David Cole wrote: > On Wed, Dec 16, 2009 at 6:16 PM, Clinton Stimpson > wrote: > On Wednesday 16 December 2009 04:05:22 pm Brad King wrote: > > Clinton Stimpson wrote: > > > It looks like a bug in the Xcode generator. > > > Here's an even simpler example: > > > > >

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread David Cole
On Wed, Dec 16, 2009 at 6:16 PM, Clinton Stimpson wrote: > On Wednesday 16 December 2009 04:05:22 pm Brad King wrote: > > Clinton Stimpson wrote: > > > It looks like a bug in the Xcode generator. > > > Here's an even simpler example: > > > > > > project(test_xcode) > > > > > > add_custom_command(O

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Clinton Stimpson
On Wednesday 16 December 2009 04:05:22 pm Brad King wrote: > Clinton Stimpson wrote: > > It looks like a bug in the Xcode generator. > > Here's an even simpler example: > > > > project(test_xcode) > > > > add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/test.h > > COMMAND cp ${CMAKE_SOURCE_DIR}/te

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Brad King
Clinton Stimpson wrote: > It looks like a bug in the Xcode generator. > Here's an even simpler example: > > project(test_xcode) > > add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/test.h > COMMAND cp ${CMAKE_SOURCE_DIR}/test.h.in ${CMAKE_BINARY_DIR}/test.h > DEPENDS ${CMAKE_SOURCE_DIR}/test

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Clinton Stimpson
It looks like a bug in the Xcode generator. Here's an even simpler example: project(test_xcode) add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/test.h COMMAND cp ${CMAKE_SOURCE_DIR}/test.h.in ${CMAKE_BINARY_DIR}/test.h DEPENDS ${CMAKE_SOURCE_DIR}/test.h.in ) include_directories(${CMAK

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Glenn Hughes
Here's a very short example that demonstrates the problem. This is a CMake file for the "states" qt 4.6 example (Developer/Examples/Qt/animation/states) #--- PROJECT(states) # the name of your project CMAKE_MINIMUM_REQUIRED(VERSION 2.4.0) FIND_PACKAGE(Qt4 REQUIRED) # find and setup Qt4 for this

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread John Drescher
On Wed, Dec 16, 2009 at 3:27 PM, Glenn Hughes wrote: > Removed the globbing, same exact behavior. > Any other ideas? > > Does this normally work for people? Any examples? > Works fine for me. Although I rarely update the .qrc files. John ___ Powered by

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Clinton Stimpson
Do you have a minimal example to demonstrate it? I wonder if its related to how dependencies for qrc files are handled. Clint On Wednesday 16 December 2009 01:27:55 pm Glenn Hughes wrote: > Removed the globbing, same exact behavior. > Any other ideas? > > Does this normally work for people? Any

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Glenn Hughes
Removed the globbing, same exact behavior. Any other ideas? Does this normally work for people? Any examples? G ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep m

Re: [CMake] qt .qrc file modifications require two builds

2009-12-16 Thread Michael Jackson
On Dec 15, 2009, at 7:24 PM, Glenn Hughes wrote: Really? How could it? Suppose I only have 1 qrc file, named foo.qrc: wouldn't these two lines be equivalent? FILE (GLOB my_RESOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "res/ *.qrc" ) SET( my_RESOURCES "res/foo.qrc") ??? TIA G On Tue, Dec

Re: [CMake] qt .qrc file modifications require two builds

2009-12-15 Thread Glenn Hughes
Really? How could it? Suppose I only have 1 qrc file, named foo.qrc: wouldn't these two lines be equivalent? FILE (GLOB my_RESOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "res/*.qrc" ) SET( my_RESOURCES "res/foo.qrc") ??? TIA G On Tue, Dec 15, 2009 at 7:15 PM, John Drescher wrote: >> The CMake

Re: [CMake] qt .qrc file modifications require two builds

2009-12-15 Thread John Drescher
> The CMake script in question looks more or less like: > > FILE (GLOB my_RESOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "res/*.qrc"  ) > QT4_ADD_RESOURCES( my_RESOURCES_SOURCES ${my_RESOURCES} ) > > ... It's always best to not do any file globbing and add each file by hand. I believe this is caus

[CMake] qt .qrc file modifications require two builds

2009-12-15 Thread Glenn Hughes
If I modify my .qrc file, the first build regenerates the cxx output file, but the cxx file itself is not compiled and linked in until I build again. Is there a way to add an additional dependency to allow the system to realize that the cxx file needs a rebuild on the first pass? The CMake script