<div dir="ltr">Hello folks,<br><br>I've wrote a test program for testing cmake in Qt4. Iam using cmake-2.6 Debian-sid.<br><br>In the first time cmake crashs with some errors. <br><br>RegularExpression::compile(): Nested *?+.<br>
RegularExpression::compile(): Error in compile.<br>CMake Error at /usr/share/cmake-2.6/Modules/FindQt4.cmake:1003 (IF):<br> if had incorrect arguments: CMAKE_CURRENT_BINARY_DIR MATCHES<br> "${_checkinfile}" (Regular expression "/home/jan/workspace/c++/dummy/src/l"<br>
cannot compile).<br>Call Stack (most recent call first):<br> /usr/share/cmake-2.6/Modules/FindQt4.cmake:1076 (QT4_MAKE_OUTPUT_FILE)<br> CMakeLists.txt:47 (QT4_WRAP_CPP)<br><br><br>RegularExpression::compile(): Nested *?+.<br>
RegularExpression::compile(): Error in compile.<br>CMake Error at /usr/share/cmake-2.6/Modules/FindQt4.cmake:1003 (IF):<br> if had incorrect arguments: CMAKE_CURRENT_BINARY_DIR MATCHES<br> "${_checkinfile}" (Regular expression "/home/jan/workspace/c++/dummy/src/m"<br>
cannot compile).<br>Call Stack (most recent call first):<br> /usr/share/cmake-2.6/Modules/FindQt4.cmake:1076 (QT4_MAKE_OUTPUT_FILE)<br> CMakeLists.txt:47 (QT4_WRAP_CPP)<br><br><br>CMake Error: Attempt to add a custom rule to output "/home/jan/workspace/c++/dummy/build/ui_mainwindow.h.rule" which already has a custom rule.<br>
-- Configuring done<br><br>I don't know what I can do. I'vre read some tutorials and howtos, but no way. <br><br>Here is my CMakelists.txt.<br><br>###snip###<br>PROJECT( dummy )<br><br>cmake_minimum_required(VERSION 2.6)<br>
<br>FIND_PACKAGE( Qt4 REQUIRED )<br>IF(QT_FOUND)<br> INCLUDE(${QT_USE_FILE})<br> IF(QT_QTSQL_FOUND)<br> INCLUDE_DIRECTORIES(${QT_QTSQL_INCLUDE_DIR})<br> ELSE(QT_QTSQL_FOUND)<br> MESSAGE(FATAL ERROR "Qt SQL libraries missing.")<br>
ENDIF(QT_QTSQL_FOUND)<br> ELSE(QT_FOUND)<br> MESSAGE(FATAL ERROR "Qt4 not found.")<br>ENDIF(QT_FOUND)<br><br><br>SET( DUMMY_SRCS<br> ./src/main.cpp<br> ./src/logindialog/logindialog.cpp<br> ./src/mainwindow/mainwindow.cpp<br>
)<br><br>SET( DUMMY_MOC_HDRS<br> ./src/logindialog/logindialog.h<br> ./src/mainwindow/mainwindow.h<br>)<br><br>SET( DUMMY_UIS<br> ./ui/logindialog.ui<br> ./ui/mainwindow.ui<br>)<br><br>SET( DUMMY_RCS<br> ./images/dummy.qrc<br>
)<br><br>ADD_DEFINITIONS( -Wall )<br><br>SET( QT_USE_QTSQL TRUE )<br><br>QT4_ADD_RESOURCES( DUMMY_RC_SRCS ${DUMMY_RCS} )<br><br>QT4_WRAP_UI( DUMMY_UIS_HDRS ${DUMMY_UIS} )<br><br>IF(QT_WRAP_CPP)<br> QT4_WRAP_CPP( DUMMY_MOC_SRCS ${DUMMY_MOC_HDRS} )<br>
ENDIF(QT_WRAP_CPP)<br><br>INCLUDE_DIRECTORIES( ${CCMAKE_BINARY_DIR} )<br><br>ADD_EXECUTABLE( dummy ${DUMMY_SRCS} ${DUMMY_MOC_SRCS} ${DUMMY_RC_SRCS} ${DUMMY_UI_HDRS} )<br><br>TARGET_LINK_LIBRARIES( dummy ${QT_LIBRARIES} ${QT_QTSQL_LIBRARIES} )<br>
###snap###<br><br>I hope someone can help me. <br><br>so long<br>jd<br></div>