diff options
author | Filipe Cabecinhas <me@filcab.net> | 2012-09-14 17:09:15 +0000 |
---|---|---|
committer | Filipe Cabecinhas <me@filcab.net> | 2012-09-14 17:09:15 +0000 |
commit | 3e9e081d35a1c4bfc163ca94b93b46567eb04ef7 (patch) | |
tree | 6a0009bd375c3a56c857b97c4c86f60c8a68a995 /lldb/scripts/Python/finish-swig-Python-LLDB.sh | |
parent | d685840a5e55ecdd30473b8c8ca1eb023464e1f0 (diff) | |
download | bcm5719-llvm-3e9e081d35a1c4bfc163ca94b93b46567eb04ef7.tar.gz bcm5719-llvm-3e9e081d35a1c4bfc163ca94b93b46567eb04ef7.zip |
Fixed some problems with SWIG bindings.
This may (but shouldn't) break Linux (but I tested and it still worked on FreeBSD).
The same shell scripts are now used on Xcode and Makefiles, for generating
the SWIG bindings.
Some compatibility fixes were applied, too (python path, bash-isms, etc).
llvm-svn: 163912
Diffstat (limited to 'lldb/scripts/Python/finish-swig-Python-LLDB.sh')
-rwxr-xr-x | lldb/scripts/Python/finish-swig-Python-LLDB.sh | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/lldb/scripts/Python/finish-swig-Python-LLDB.sh b/lldb/scripts/Python/finish-swig-Python-LLDB.sh index 2e24091a2db..c6c394c28a8 100755 --- a/lldb/scripts/Python/finish-swig-Python-LLDB.sh +++ b/lldb/scripts/Python/finish-swig-Python-LLDB.sh @@ -1,4 +1,4 @@ -#! /bin/sh +#!/bin/sh # finish-swig-Python.sh # @@ -37,7 +37,7 @@ debug_flag=$5 # Note, at present iOS doesn't have Python, so if you're building for iOS be sure to # set LLDB_DISABLE_PYTHON to 1. -if [ ! $LLDB_DISABLE_PYTHON = "1" ] ; then +if [ ! "$LLDB_DISABLE_PYTHON" = "1" ] ; then if [ -n "$debug_flag" -a "$debug_flag" == "-debug" ] then @@ -47,7 +47,7 @@ else fi OS_NAME=`uname -s` -PYTHON_VERSION=`/usr/bin/python --version 2>&1 | sed -e 's,Python ,,' -e 's,[.][0-9],,2' -e 's,[a-z][a-z][0-9],,'` +PYTHON_VERSION=`/usr/bin/env python --version 2>&1 | sed -e 's,Python ,,' -e 's,[.][0-9],,2' -e 's,[a-z][a-z][0-9],,'` if [ $Debug == 1 ] @@ -134,9 +134,6 @@ then then cd "${framework_python_dir}" ln -s "../../../LLDB" _lldb.so - else - cd "${TARGET_DIR}" - ln -s "../LLDB" _lldb.so fi else if [ $Debug == 1 ] @@ -146,7 +143,7 @@ else fi -function create_python_package { +create_python_package () { package_dir="${framework_python_dir}$1" package_files="$2" package_name=`echo $1 | tr '/' '.'` |