[Lldb-commits] [lldb] r157405 - in /lldb/trunk/scripts/Python: build-swig-Python.sh finish-swig-Python-LLDB.sh

Filipe Cabecinhas filcab at gmail.com
Fri May 25 06:17:16 PDT 2012


Hi Johnny.  

I would say that these lines are a bug waiting to happen:

> if [ $LLDB_DISABLE_PYTHON = "1" ] ; then
> - # SDKROOT was not empty, which currently means iOS cross build where python is disabled
> + # LLDB_DISABLE_PYTHON is set, which currently means iOS cross build where python is disabled

> +# Make sure LLDB_DISABLE_PYTHON is not set, since if it is this is an iOS build where python
> # is disabled
> -if [ "x$SDKROOT" = "x" ] ; then
> +if [ ! $LLDB_DISABLE_PYTHON = "1" ] ; then



Wouldn't you prefer to use a variable IOS_BUILD or something that would semantically mean “this is an iOS build”? When that variable would be set, we could set LLDB_DISABLE_PYTHON too.



Regards,

  Filipe


On Thursday, May 24, 2012 at 7:14 PM, Johnny Chen wrote:

> Author: johnny
> Date: Thu May 24 13:14:18 2012
> New Revision: 157405
>  
> URL: http://llvm.org/viewvc/llvm-project?rev=157405&view=rev
> Log:
> Fix missing Resources/Python directory for macosx build.
>  
> Modified:
> lldb/trunk/scripts/Python/build-swig-Python.sh (http://build-swig-Python.sh)
> lldb/trunk/scripts/Python/finish-swig-Python-LLDB.sh (http://finish-swig-Python-LLDB.sh)
>  
> Modified: lldb/trunk/scripts/Python/build-swig-Python.sh (http://build-swig-Python.sh)
> URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/scripts/Python/build-swig-Python.sh?rev=157405&r1=157404&r2=157405&view=diff
> ==============================================================================
> --- lldb/trunk/scripts/Python/build-swig-Python.sh (http://build-swig-Python.sh) (original)
> +++ lldb/trunk/scripts/Python/build-swig-Python.sh (http://build-swig-Python.sh) Thu May 24 13:14:18 2012
> @@ -25,7 +25,7 @@
> swig_python_typemaps=${SRC_ROOT}/scripts/Python/python-typemaps.swig
>  
> if [ $LLDB_DISABLE_PYTHON = "1" ] ; then
> - # SDKROOT was not empty, which currently means iOS cross build where python is disabled
> + # LLDB_DISABLE_PYTHON is set, which currently means iOS cross build where python is disabled
> rm -rf ${swig_output_file}
> touch ${swig_output_file}
>  
>  
> Modified: lldb/trunk/scripts/Python/finish-swig-Python-LLDB.sh (http://finish-swig-Python-LLDB.sh)
> URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/scripts/Python/finish-swig-Python-LLDB.sh?rev=157405&r1=157404&r2=157405&view=diff
> ==============================================================================
> --- lldb/trunk/scripts/Python/finish-swig-Python-LLDB.sh (http://finish-swig-Python-LLDB.sh) (original)
> +++ lldb/trunk/scripts/Python/finish-swig-Python-LLDB.sh (http://finish-swig-Python-LLDB.sh) Thu May 24 13:14:18 2012
> @@ -33,9 +33,9 @@
> PYTHON_INSTALL_DIR=$4
> debug_flag=$5
>  
> -# Make sure SDKROOT is not set, since if it is this is an iOS build where python
> +# Make sure LLDB_DISABLE_PYTHON is not set, since if it is this is an iOS build where python
> # is disabled
> -if [ "x$SDKROOT" = "x" ] ; then
> +if [ ! $LLDB_DISABLE_PYTHON = "1" ] ; then
>  
> if [ -n "$debug_flag" -a "$debug_flag" == "-debug" ]
> then
>  
>  
> _______________________________________________
> lldb-commits mailing list
> lldb-commits at cs.uiuc.edu (mailto:lldb-commits at cs.uiuc.edu)
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits







More information about the lldb-commits mailing list