Fix #1066363 - directory name matches tarball name
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@7250 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
c922efdfcd
commit
bd43f20540
1 changed files with 11 additions and 6 deletions
|
|
@ -1,19 +1,24 @@
|
||||||
#!/usr/local/bin/python
|
#!/usr/local/bin/python
|
||||||
|
|
||||||
# This script builds a SWIG-1.3 distribution.
|
# This script builds a swig-1.3 distribution.
|
||||||
# Usage : mkdist.py directory, where directory should be SWIG-1.3.x
|
# Usage : mkdist.py directory, where directory should be swig-1.3.x
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
import string
|
import string
|
||||||
|
import os
|
||||||
|
|
||||||
try:
|
try:
|
||||||
dirname = sys.argv[1]
|
dirname = sys.argv[1]
|
||||||
except:
|
except:
|
||||||
print "Usage: mkdist.py directory, where directory should be SWIG-1.3.x"
|
print "Usage: mkdist.py directory, where directory should be swig-1.3.x"
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
|
|
||||||
|
# Check name matches normal unix conventions
|
||||||
|
if string.lower(dirname) != dirname:
|
||||||
|
print "directory name ("+dirname+") should be in lowercase"
|
||||||
|
sys.exit(0)
|
||||||
|
|
||||||
# If directory exists, remove it
|
# If directory exists, remove it
|
||||||
import os
|
|
||||||
print "Removing ", dirname
|
print "Removing ", dirname
|
||||||
os.system("rm -rf "+dirname)
|
os.system("rm -rf "+dirname)
|
||||||
|
|
||||||
|
|
@ -46,6 +51,6 @@ print "Building documentation"
|
||||||
os.system("cd "+dirname+"/Doc/Manual; make; rm *.bak")
|
os.system("cd "+dirname+"/Doc/Manual; make; rm *.bak")
|
||||||
|
|
||||||
# Build the tar-ball
|
# Build the tar-ball
|
||||||
os.system("tar -cf "+string.lower(dirname)+".tar "+dirname)
|
os.system("tar -cf "+dirname+".tar "+dirname)
|
||||||
os.system("gzip "+string.lower(dirname)+".tar")
|
os.system("gzip "+dirname+".tar")
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue