git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a591b84
)
build: nicer error message on missing file in waf dist
author
Andrew Tridgell
<tridge@samba.org>
Fri, 9 Apr 2010 11:00:49 +0000
(21:00 +1000)
committer
Andrew Tridgell
<tridge@samba.org>
Fri, 9 Apr 2010 11:12:09 +0000
(21:12 +1000)
buildtools/wafsamba/samba_dist.py
patch
|
blob
|
history
diff --git
a/buildtools/wafsamba/samba_dist.py
b/buildtools/wafsamba/samba_dist.py
index b4a6cbb2405e1b8d9685b5b4792ceeeec73ae3a2..0fa8dbee032284f157d6afbd0925a6ec084d2dbc 100644
(file)
--- a/
buildtools/wafsamba/samba_dist.py
+++ b/
buildtools/wafsamba/samba_dist.py
@@
-1,14
+1,18
@@
# customised version of 'waf dist' for Samba tools
# uses git ls-files to get file lists
# customised version of 'waf dist' for Samba tools
# uses git ls-files to get file lists
-import Utils, os, sys, tarfile, stat, Scripting
+import Utils, os, sys, tarfile, stat, Scripting
, Logs
from samba_utils import *
dist_dirs = None
def add_tarfile(tar, fname, abspath):
'''add a file to the tarball'''
from samba_utils import *
dist_dirs = None
def add_tarfile(tar, fname, abspath):
'''add a file to the tarball'''
- tinfo = tar.gettarinfo(name=abspath, arcname=fname)
+ try:
+ tinfo = tar.gettarinfo(name=abspath, arcname=fname)
+ except OSError:
+ Logs.error('Unable to find file %s - missing from git checkout?' % abspath)
+ sys.exit(1)
tinfo.uid = 0
tinfo.gid = 0
tinfo.uname = 'root'
tinfo.uid = 0
tinfo.gid = 0
tinfo.uname = 'root'