- def configure(self, force=False): # force is ignored
- self.autoDebuildConfig['version'] = self.vcs.version() # by now, data has been fetched, so this is possible
- os.chdir(self.sourceFolder)
- print self.sourceFolder,self.autoDebuildConfig
- self.files = auto_debuild.createDebianFiles(self.autoDebuildConfig)
- self.configured = True
-
- def build(self):
- if not self.configured: self.configure()
+ def build(self, reconfigure=False): # reconfigure is ignored (we always do a reconfiguration)
+ # create auto-debuild configuration
+ autoDebuildConfig = {
+ 'sourceName': self.module['name'],
+ 'buildSystem': self.module['build-system'],
+ 'debDir': self.debDir,
+ 'buildDir': self.buildFolder,
+ 'name': self.debName,
+ 'email': self.debEMail,
+ 'parallelJobs': self.jobs,
+ 'version': self.vcs.version()
+ }
+ if self.autoDebuildConfig['version'] is None:
+ raise Exception("VCS did not provide us with a proper version number, please fix this")
+ # copy some more optional configuration
+ for option in ('dbgPackage', 'binarySkipFiles', 'binaryInstallFiles', 'buildDepends', 'binaryDepends', 'binaryRecommends',
+ 'binaryProvides', 'cmakeParameters', 'automakeParameters'):
+ if option in self.module:
+ autoDebuildConfig[option] = self.module[option]
+ # create Debian files