diff options
author | Clinton Stimpson <clinton@elemtech.com> | 2009-02-09 21:42:19 (GMT) |
---|---|---|
committer | Clinton Stimpson <clinton@elemtech.com> | 2009-02-09 21:42:19 (GMT) |
commit | dda19cd36f94343e711210c6aefee8406bcce22e (patch) | |
tree | 2e1ea3ec598016e6b691239915efb0f0b0a2863d /Modules/FindQt4.cmake | |
parent | bd92bec66ce6e167437182b6c554142852f7388c (diff) | |
download | CMake-dda19cd36f94343e711210c6aefee8406bcce22e.zip CMake-dda19cd36f94343e711210c6aefee8406bcce22e.tar.gz CMake-dda19cd36f94343e711210c6aefee8406bcce22e.tar.bz2 |
ENH: Support .hpp with automoc.
Diffstat (limited to 'Modules/FindQt4.cmake')
-rw-r--r-- | Modules/FindQt4.cmake | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake index ee4d8bb..8d02824 100644 --- a/Modules/FindQt4.cmake +++ b/Modules/FindQt4.cmake @@ -1167,7 +1167,11 @@ IF (QT4_QMAKE_FOUND) FOREACH (_current_MOC_INC ${_match}) STRING(REGEX MATCH "[^ <\"]+\\.moc" _current_MOC "${_current_MOC_INC}") GET_FILENAME_COMPONENT(_basename ${_current_MOC} NAME_WE) - SET(_header ${_abs_PATH}/${_basename}.h) + IF(EXISTS ${_abs_PATH}/${_basename}.hpp) + SET(_header ${_abs_PATH}/${_basename}.hpp) + ELSE(EXISTS ${_abs_PATH}/${_basename}.hpp) + SET(_header ${_abs_PATH}/${_basename}.h) + ENDIF(EXISTS ${_abs_PATH}/${_basename}.hpp) SET(_moc ${CMAKE_CURRENT_BINARY_DIR}/${_current_MOC}) QT4_CREATE_MOC_COMMAND(${_header} ${_moc} "${_moc_INCS}" "") MACRO_ADD_FILE_DEPENDENCIES(${_abs_FILE} ${_moc}) |