diff options
author | Alexander Neundorf <neundorf@kde.org> | 2007-08-16 02:18:48 +0000 |
---|---|---|
committer | Alexander Neundorf <neundorf@kde.org> | 2007-08-16 02:18:48 +0000 |
commit | 2f2f14289d4a63d53140fdbd336890f51d332a78 (patch) | |
tree | c38a53796cb78fe0f200dfab061bf505167d0356 /modules/FindGettext.cmake | |
parent | 00b3f6e99df7075d56e07edc8a90c4794744f2ec (diff) | |
download | extra-cmake-modules-2f2f14289d4a63d53140fdbd336890f51d332a78.tar.gz extra-cmake-modules-2f2f14289d4a63d53140fdbd336890f51d332a78.tar.bz2 |
also work if used with too few arguments
Alex
svn path=/trunk/KDE/kdelibs/; revision=700613
Diffstat (limited to 'modules/FindGettext.cmake')
-rw-r--r-- | modules/FindGettext.cmake | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/modules/FindGettext.cmake b/modules/FindGettext.cmake index b461fe51..121c59a5 100644 --- a/modules/FindGettext.cmake +++ b/modules/FindGettext.cmake @@ -139,17 +139,21 @@ MACRO(GETTEXT_PROCESS_POT_FILE _potFile) SET(_addToAll) SET(_installDest) - LIST(GET _args 0 _tmp) - IF("${_tmp}" STREQUAL "ALL") - SET(_addToAll ALL) - LIST(REMOVE_AT _args 0) - ENDIF("${_tmp}" STREQUAL "ALL") - - LIST(GET _args 0 _tmp) - IF("${_tmp}" STREQUAL "INSTALL_DESTINATION") - LIST(GET _args 1 _installDest ) - LIST(REMOVE_AT _args 0 1) - ENDIF("${_tmp}" STREQUAL "INSTALL_DESTINATION") + IF(_args) + LIST(GET _args 0 _tmp) + IF("${_tmp}" STREQUAL "ALL") + SET(_addToAll ALL) + LIST(REMOVE_AT _args 0) + ENDIF("${_tmp}" STREQUAL "ALL") + ENDIF(_args) + + IF(_args) + LIST(GET _args 0 _tmp) + IF("${_tmp}" STREQUAL "INSTALL_DESTINATION") + LIST(GET _args 1 _installDest ) + LIST(REMOVE_AT _args 0 1) + ENDIF("${_tmp}" STREQUAL "INSTALL_DESTINATION") + ENDIF(_args) GET_FILENAME_COMPONENT(_potBasename ${_potFile} NAME_WE) GET_FILENAME_COMPONENT(_absPotFile ${_potFile} ABSOLUTE) |