projects
/
auto-debuild.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
8b39882
)
Support copying already installed files to another location
author
Ralf Jung
<post@ralfj.de>
Sun, 29 Jul 2012 21:03:46 +0000
(23:03 +0200)
committer
Ralf Jung
<post@ralfj.de>
Sun, 29 Jul 2012 21:03:46 +0000
(23:03 +0200)
auto_debuild.py
patch
|
blob
|
history
diff --git
a/auto_debuild.py
b/auto_debuild.py
index c2744125659bf3071c6bbbb6e97767f97989b835..cb2d840039af595a7a6f79ae545cb78e08b3294a 100755
(executable)
--- a/
auto_debuild.py
+++ b/
auto_debuild.py
@@
-1,5
+1,5
@@
#!/usr/bin/python
#!/usr/bin/python
-import os, stat, time, subprocess, sys
+import os, s
hutil, s
tat, time, subprocess, sys
from collections import OrderedDict
# some utility functions
from collections import OrderedDict
# some utility functions
@@
-149,6
+149,8
@@
def createDebianFiles(config):
# install file
with open('debian/'+binaryName+'.install', 'w') as f:
for line in config.get('binaryInstall', []):
# install file
with open('debian/'+binaryName+'.install', 'w') as f:
for line in config.get('binaryInstall', []):
+ if line.startswith('/'): # a file from within the package, not from the source tree
+ line = 'debian/'+binaryName+line
print >>f, line
# rules file: build system specific
with open('debian/rules', 'w') as f:
print >>f, line
# rules file: build system specific
with open('debian/rules', 'w') as f:
@@
-181,7
+183,7
@@
def createDebianFiles(config):
r.write(f)
mode = os.stat('debian/rules').st_mode
os.chmod('debian/rules', mode | stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH)
r.write(f)
mode = os.stat('debian/rules').st_mode
os.chmod('debian/rules', mode | stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH)
- # return list of files
affec
ted
+ # return list of files
that will be crea
ted
return files
def buildDebianPackage(config):
return files
def buildDebianPackage(config):
@@
-193,7
+195,7
@@
def buildDebianPackage(config):
###################################################################
# if we are called directly as script
if __name__ == "__main__":
###################################################################
# if we are called directly as script
if __name__ == "__main__":
- import imp
, shutil
+ import imp
# get config
config = imp.load_source('config', 'auto-debuild.conf').__dict__
os.remove('auto-debuild.confc')
# get config
config = imp.load_source('config', 'auto-debuild.conf').__dict__
os.remove('auto-debuild.confc')