applied python 3 compat patch from #3222

This commit is contained in:
Brian Gerkey 2010-12-31 01:40:39 +00:00
parent 663162dd6c
commit c202d0fc49
1 changed files with 2 additions and 2 deletions

View File

@ -369,7 +369,7 @@ endmacro(_rosbuild_add_library)
macro(_rosbuild_get_clock var)
execute_process(
COMMAND python -c "import time; print time.time()"
COMMAND python -c "import time, sys; sys.stdout.write(str(time.time()));"
OUTPUT_VARIABLE ${var}
ERROR_VARIABLE _time_error
RESULT_VARIABLE _time_failed
@ -403,7 +403,7 @@ macro(_rosbuild_compare_manifests var _t _c _m)
# Call Python to compare the provided time to the latest mtime on all
# the files
execute_process(
COMMAND python -c "import os; print 1 if set(${_pylist}) != set(${_cached_pylist}) or ${_t} < max(os.stat(f).st_mtime for f in ${_pylist}) else 0;"
COMMAND python -c "import os, sys; sys.stdout.write('1' if set(${_pylist}) != set(${_cached_pylist}) or ${_t} < max(os.stat(f).st_mtime for f in ${_pylist}) else '0');"
OUTPUT_VARIABLE ${var}
ERROR_VARIABLE _mtime_error
RESULT_VARIABLE _mtime_failed