diff options
-rwxr-xr-x | scripts/macosx-sanity-check.py | 6 | ||||
-rwxr-xr-x | scripts/publish-macosx.sh | 4 |
2 files changed, 10 insertions, 0 deletions
diff --git a/scripts/macosx-sanity-check.py b/scripts/macosx-sanity-check.py index a085bda..c9fcb5d 100755 --- a/scripts/macosx-sanity-check.py +++ b/scripts/macosx-sanity-check.py @@ -4,6 +4,8 @@ # This is be used to verify that all the dependant libraries of a Mac OS X executable # are present and that they are backwards compatible with at least 10.5. # Run with an executable as parameter +# Will return 0 if the executable an all libraries are OK +# Returns != 0 and prints some textural description on error # # Author: Marius Kintel <marius@kintel.net> # @@ -82,6 +84,7 @@ def validate_lib(lib): return True if __name__ == '__main__': + error = False if len(sys.argv) != 2: usage() executable = sys.argv[1] if DEBUG: print "Processing " + executable @@ -113,3 +116,6 @@ if __name__ == '__main__': # print " " + str(processed[dep]) if not validate_lib(dep): print "..required by " + str(processed[dep]) + error = True + if error: sys.exit(1) + else: sys.exit(0) diff --git a/scripts/publish-macosx.sh b/scripts/publish-macosx.sh index 51d890e..684a601 100755 --- a/scripts/publish-macosx.sh +++ b/scripts/publish-macosx.sh @@ -9,6 +9,10 @@ export MACOSX_DEPLOY_DIR=$PWD/../libraries/deploy if [[ $? != 0 ]]; then exit 1 fi +`dirname $0`/macosx-sanity-check.py OpenSCAD.app/Contents/MacOS/OpenSCAD +if [[ $? != 0 ]]; then + exit 1 +fi cp OpenSCAD-$VERSION.dmg ~/Documents/Dropbox/Public ln -sf OpenSCAD-$VERSION.dmg ~/Documents/Dropbox/Public/OpenSCAD-latest.dmg |