change default cmake build directory to 'build', after I figured out how to make...
authorRalf Jung <post@ralfj.de>
Mon, 6 Aug 2012 13:48:55 +0000 (15:48 +0200)
committerRalf Jung <post@ralfj.de>
Mon, 6 Aug 2012 13:48:55 +0000 (15:48 +0200)
auto_debuild.py

index bb4387e9dc1493ab50576858a2bbdddb75b37468..c827a12fcb41428a0fb0bfabc947e61097c1b9e2 100755 (executable)
@@ -30,7 +30,9 @@ class RulesFile:
        def write(self, f):
                print >>f, "#!/usr/bin/make -f"
                print >>f, ""
        def write(self, f):
                print >>f, "#!/usr/bin/make -f"
                print >>f, ""
-               print >>f, "%:"
+               print >>f, ".PHONY: build" # there may be a directory called "build"
+               print >>f, ""
+               print >>f, "build %:" # need to mention "build" here again explicitly
                print >>f, '\t'+self.env2str()+' dh $@ '+safeCall(*self.dh)
                for rule in self.rules:
                        print >>f, ""
                print >>f, '\t'+self.env2str()+' dh $@ '+safeCall(*self.dh)
                for rule in self.rules:
                        print >>f, ""
@@ -40,7 +42,7 @@ class RulesFile:
 
 # build-system specific part of rules file
 def cmakeRules(config):
 
 # build-system specific part of rules file
 def cmakeRules(config):
-       buildDir = config.get('buildDir', 'build.dir') # "build" is not a good idea, as that's also the name of a target...
+       buildDir = config.get('buildDir', 'build')
        srcDir = os.getcwd()
        r = RulesFile()
        r.dh += ["--buildsystem=cmake", "--builddirectory="+buildDir] # dh parameters
        srcDir = os.getcwd()
        r = RulesFile()
        r.dh += ["--buildsystem=cmake", "--builddirectory="+buildDir] # dh parameters