[CMake] Force rebuild

Min Cu min.cu at hotmail.com
Mon Mar 26 20:38:05 EST 2007


I did try to do that. However, the generated target is empty and the 
generarated header file is not part of the project. If I try to make it part 
of another library (the one where it gets included) the library does not 
pick the newest version of the file. The thing I do not know is how to use 
ADD_CUSTOM_TARGET so that it includes the header file which it builds.

Thanks,
Min


>From: Bill Hoffman <bill.hoffman at kitware.com>
>Reply-To: billlist at nycap.rr.com
>To: Min Cu <min.cu at hotmail.com>
>CC: billlist at nycap.rr.com, cmake at cmake.org
>Subject: Re: [CMake] Force rebuild
>Date: Mon, 26 Mar 2007 21:20:37 -0400
>
>Min Cu wrote:
>>Yes, that is more or less what I need. I have a project that generates a 
>>header file which is included in other projects. However, once the project 
>>is built when make is called the next time it does not get rebuilt. So, I 
>>guess my question is "How do I make the custom target run every built?" 
>>The solution needs to work on both Windows and Linux/Unix so I can't use 
>>the pre-build event. It is probably a silly question but I am new to CMake 
>>and don't know it well yet.
>add a custom target that depends on all.  Then use add_dependency to make 
>other targets depend on it.  So, look at these commends:
>
>add_dependencies
>add_custom_target
>
>here:
>http://www.cmake.org/HTML/Documentation.html
>
>-Bill
>
>_______________________________________________
>CMake mailing list
>CMake at cmake.org
>http://www.cmake.org/mailman/listinfo/cmake

_________________________________________________________________
Get Hotmail, News, Sport and Entertainment from MSN on your mobile.  
http://www.msn.txt4content.com/



More information about the CMake mailing list