Fix main CMakeLists.txt

This commit is contained in:
Vadim Kuznetsov 2022-02-14 23:15:40 +01:00
parent b2e016d01f
commit 62fc2a7c87
3 changed files with 5 additions and 17 deletions

View File

@ -23,19 +23,7 @@ ENDIF()
message(STATUS "${PROJECT_NAME} ${CMAKE_INSTALL_PREFIX}
${qucs-suite_BINARY_DIR}" )
FIND_PACKAGE( Qt4 REQUIRED )
SET( QT_USE_QT TRUE )
#SET( QT_USE_QTXML TRUE )
#SET( QT_USE_QTSVG TRUE )
SET( QT_USE_QTCORE TRUE )
SET( QT_USE_QTGUI TRUE )
SET( QT_USE_QTSCRIPT TRUE )
SET( QT_DEBUG TRUE)
INCLUDE( ${QT_USE_FILE} )
FIND_PACKAGE( Qt5 COMPONENTS Core Gui Widgets LinguistTools Script REQUIRED )
ADD_DEFINITIONS(${QT_DEFINITIONS})

View File

@ -66,10 +66,10 @@ INCLUDE_DIRECTORIES(
${Qt5Xml_INCLUDE_DIRS}
${Qt5Script_INCLUDE_DIRS}
${Qt5PrintSupport_INCLUDE_DIRS}
${Qt5Test_INCLUDE_DIRS} )
)
# bug, the find package does not seem to set the QT_LIBRARIES, do it manually
SET(QT_LIBRARIES ${Qt5Core_LIBRARIES} ${Qt5Widgets_LIBRARIES} ${Qt5Svg_LIBRARIES} ${Qt5Script_LIBRARIES} ${Qt5PrintSupport_LIBRARIES} ${Qt5Test_LIBRARIES} )
SET(QT_LIBRARIES ${Qt5Core_LIBRARIES} ${Qt5Widgets_LIBRARIES} ${Qt5Svg_LIBRARIES} ${Qt5Script_LIBRARIES} ${Qt5PrintSupport_LIBRARIES} )

View File

@ -15,9 +15,9 @@ file (GLOB TRANSLATIONS_FILES qucs_*.ts)
option (UPDATE_TRANSLATIONS "Update source translation translations/*.ts" "OFF")
IF (UPDATE_TRANSLATIONS)
QT4_CREATE_TRANSLATION ( QM_FILES ${FILES_TO_TRANSLATE} ${TRANSLATIONS_FILES})
QT5_CREATE_TRANSLATION ( QM_FILES ${FILES_TO_TRANSLATE} ${TRANSLATIONS_FILES})
ELSE (UPDATE_TRANSLATIONS)
QT4_ADD_TRANSLATION ( QM_FILES ${TRANSLATIONS_FILES})
QT5_ADD_TRANSLATION ( QM_FILES ${TRANSLATIONS_FILES})
ENDIF (UPDATE_TRANSLATIONS)
ADD_CUSTOM_TARGET (translations ALL DEPENDS ${QM_FILES})