diff options
-rw-r--r-- | CMakeLists.txt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c24a4a8..e823062 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -47,7 +47,8 @@ FIND_PACKAGE(SWIG REQUIRED) FIND_PACKAGE(Zypp REQUIRED) # determine zypp version -EXECUTE_PROCESS(COMMAND "/usr/bin/readlink" ${ZYPP_LIBRARY} OUTPUT_VARIABLE ZYPP_SOFILE) +FIND_PROGRAM(READ_LINK readlink) +EXECUTE_PROCESS(COMMAND "${READ_LINK}" ${ZYPP_LIBRARY} OUTPUT_VARIABLE ZYPP_SOFILE) # match number at end, strip trailing \n by using a sub-match STRING(REGEX MATCH "([0-9]+)\n$" ZYPP_VERSION "${ZYPP_SOFILE}") |