aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/KDE4Macros.cmake12
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/KDE4Macros.cmake b/modules/KDE4Macros.cmake
index fb4b684d..1e09283d 100644
--- a/modules/KDE4Macros.cmake
+++ b/modules/KDE4Macros.cmake
@@ -101,14 +101,14 @@ MACRO(KDE4_ADD_KCFG_FILES _sources)
foreach (_current_FILE ${ARGN})
GET_FILENAME_COMPONENT(_tmp_FILE ${_current_FILE} ABSOLUTE)
-
+ GET_FILENAME_COMPONENT(_abs_PATH ${_tmp_FILE} PATH)
GET_FILENAME_COMPONENT(_basename ${_tmp_FILE} NAME_WE)
FILE(READ ${_tmp_FILE} _contents)
STRING(REGEX REPLACE "^(.*\n)?File=([^\n]+kcfg).*\n.*$" "\\2" _kcfg_FILE "${_contents}")
- set(_src_FILE ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.cpp)
- set(_header_FILE ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.h)
- set(_moc_FILE ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.moc)
+ set(_src_FILE ${_abs_PATH}/${_basename}.cpp)
+ set(_header_FILE ${_abs_PATH}/${_basename}.h)
+ set(_moc_FILE ${_abs_PATH}/${_basename}.moc)
# the command for creating the source file from the kcfg file
ADD_CUSTOM_COMMAND(OUTPUT ${_src_FILE}
@@ -141,9 +141,9 @@ MACRO(KDE4_ADD_UI_FILES _sources )
foreach (_current_FILE ${ARGN})
GET_FILENAME_COMPONENT(_tmp_FILE ${_current_FILE} ABSOLUTE)
-
+ GET_FILENAME_COMPONENT(_abs_PATH ${_tmp_FILE} PATH)
GET_FILENAME_COMPONENT(_basename ${_tmp_FILE} NAME_WE)
- set(_header ${CMAKE_CURRENT_BINARY_DIR}/${_basename}.h)
+ set(_header ${_abs_PATH}/${_basename}.h)
# we need to run uic and replace some things in the generated file
# this is done by executing the cmake script kde4uic.cmake