Le lundi 06 octobre 2008 à 17:35, Robin Cornelius a écrit : > On Mon, Oct 6, 2008 at 4:11 PM, Laurent Léonard <laurent@open-minds.org> wrote: > > Could you give me a sample rules file with cmake calls ? > > > > I put the cmake call in the "build-stamp" section, but when I use > > dpkg-builpackage it try to do a "make clean" before executing cmake... If > > I delete the "make clean" call the deb package is correctly generated but > > I have some problems to get clean sources again. What can I do in the > > "clean" section to clean the files generated by cmake ? > > > > Or perhaps I should execute cmake in the "configure-stamp" section ? > > cmake does not have a proper clean target in the unix makefiles in > generates, which is a pain. Or not one that cleans as you would fully > expect. It does keep its working files in the current directory so a > the way i have done this is to do something like :- > > for the main build :- > > mkdir build > cd build > cmake _DSOMEFLAGS:BOOL=true.............. > > then the clean rule can just purge "build/" > > this produces working debs and keeps the orig.tar.gz clean too. > > This does seem a little dirty which makes me think i'm not quite doing > it right though so if anyone has a better way to do this?, but it does > work. > > Regards Robin "cd build" doesn't work in the rules file because each line is executed in a separate shell... So I made this for the build section : mkdir build cd build && cmake -D CMAKE_INSTALL_PREFIX=/usr .. $(MAKE) -C build It works great for me... What about automoc4, where can I find some documentation to use it ? -- Laurent Léonard
Attachment:
signature.asc
Description: This is a digitally signed message part.