cmake: start to add the Qt components. No real functionality yet.

This commit is contained in:
suter_a 2018-05-22 15:25:22 +02:00
parent 7a0609dc84
commit 0bc2ef7612
7 changed files with 42 additions and 12 deletions

View File

@ -91,10 +91,12 @@ if (qt_based_tools)
# first try Qt5
# Find the QtCore library
find_package(Qt5Core)
# Find the QtWidgets library
find_package(Qt5Widgets)
# Find the QtXml library
find_package(Qt5Xml)
if (Qt5Core_FOUND)
# Find the QtWidgets library
find_package(Qt5Widgets CONFIG REQUIRED)
# Find the QtXml library
find_package(Qt5Xml CONFIG REQUIRED)
endif (Qt5Core_FOUND)
# if Qt5 is not found, try Qt4
if (NOT Qt5Core_FOUND)

4
cmake/musrfit-info.h.in Normal file
View File

@ -0,0 +1,4 @@
#--- This file is generated by cmake ------------------------------------------
#define MUSRFIT_PREFIX "@CMAKE_INSTALL_PREFIX@"
#define MUSRFIT_DOC_DIR "@CMAKE_INSTALL_PREFIX@/share/doc/musrfit"

View File

@ -1,14 +1,13 @@
#--- add further sub-directories ----------------------------------------------
add_subdirectory(classes)
add_subdirectory(external)
#[==[
if (Qt5Core_FOUND OR Qt4_FOUND)
if (Qt5Core_FOUND)
add_subdirectory(musredit_qt5)
elseif (Qt4_FOUND)
add_subdirectory(musredit)
endif (Qt5Core_FOUND OR Qt4_FOUND)
if (QT_FOUND)
elseif (QT_FOUND)
add_subdirectory(musrgui)
endif (QT_FOUND)
#]==]
endif (Qt5Core_FOUND)
#--- define the musrfit libs --------------------------------------------------
set(MUSRFIT_LIBS ${MUSRFIT_LIBS} mud)

View File

@ -0,0 +1,3 @@
#--- musredit for Qt > 4.6 and < 5.0 ------------------------------------------
message("debug> will eventually deal with Qt > 4.6 < 5.0 musredit")

View File

@ -0,0 +1,13 @@
#--- musredit for Qt > 5.0 ----------------------------------------------------
message("debug> will eventually deal with Qt > 5.0 musredit, musrStep, musrWiz, ...")
#--- create musrfit-info.h ----------------------------------------------------
configure_file(
${CMAKE_SOURCE_DIR}/cmake/musrfit-info.h.in
${CMAKE_CURRENT_BINARY_DIR}/musrfit-info.h
)
#add_subdirectory(musredit)
#add_subdirectory(musrStep)
#add_subdirectory(musrWiz)

View File

@ -0,0 +1,5 @@
#--- musrgui for Qt 3.x -------------------------------------------------------
message("musrgui is currently not supported anymore! Please check if not at least")
message("Qt >= 4.6 is available.")

View File

@ -1,10 +1,14 @@
#---------------------------------------------------------------------
# README
# Andreas Suter, 2010/10/06
# Andreas Suter, 2018/05/22
#---------------------------------------------------------------------
musrgui requires >= Qt 3.3.x and < Qt 4. If you have Qt 4.6.y or newer,
use musredit instead.
use musredit instead. If you have Qt 5.x, use musredit_qt5 instead.
musrgui by now should be considered as not only outdated, but it will
be hard to find a platform on which it is still compiling. So, if there
is no urgent need: don't use it!
#---------------------------------------------------------------------
# this is the end ...