diff options
author | Martin Braun <martin.braun@ettus.com> | 2016-11-30 09:49:51 -0800 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2016-11-30 11:56:05 -0800 |
commit | f583c77fc2dfb1308520164eb1c6260b0b0d8d79 (patch) | |
tree | 21145bf22f1ade69b005f713647a3021b8459728 /host/cmake/Modules/UHDVersion.cmake | |
parent | 58668be81d1ec23dc7ce9312bf288ac35206d49e (diff) | |
download | uhd-f583c77fc2dfb1308520164eb1c6260b0b0d8d79.tar.gz uhd-f583c77fc2dfb1308520164eb1c6260b0b0d8d79.tar.bz2 uhd-f583c77fc2dfb1308520164eb1c6260b0b0d8d79.zip |
cmake: Fixed version num depadding
Diffstat (limited to 'host/cmake/Modules/UHDVersion.cmake')
-rw-r--r-- | host/cmake/Modules/UHDVersion.cmake | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/host/cmake/Modules/UHDVersion.cmake b/host/cmake/Modules/UHDVersion.cmake index 26dbfbb06..7c18f9312 100644 --- a/host/cmake/Modules/UHDVersion.cmake +++ b/host/cmake/Modules/UHDVersion.cmake @@ -79,7 +79,7 @@ ENDIF(GIT_FOUND) FUNCTION(DEPAD_NUM input_num output_num) EXECUTE_PROCESS( WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} - COMMAND ${PYTHON_EXECUTABLE} -c "print(int('${input_num}'))" + COMMAND ${PYTHON_EXECUTABLE} -c "print(\"${input_num}\".lstrip(\"0\") or 0)" OUTPUT_VARIABLE depadded_num OUTPUT_STRIP_TRAILING_WHITESPACE ) SET(${output_num} ${depadded_num} PARENT_SCOPE) |