From 2eea4f7ac38f9c36a923d1ad3108aa1cd48f9749 Mon Sep 17 00:00:00 2001 From: Manuel Nickschas Date: Tue, 9 Oct 2007 22:05:34 +0000 Subject: [PATCH] qmake-based build system should work now! Please test. If I don't get complaints, the cmake files will be removed soonish. See build/quassel.pro for short instructions, or just run 'qmake && make' in the build dir. NOTE: Files must now be declared in the various *.pri files found in the module directories! --- Quassel.kdevelop.filelist | 4 ++++ build/modules/client.pro | 1 - build/modules/common.pro | 1 - build/modules/core.pro | 1 - build/modules/module.pri | 9 ++++++--- build/quassel.pro | 35 +++++++++++++++++++++++++++++++---- build/targets/core.pri | 4 ++++ build/targets/core.pro | 2 -- build/targets/monolithic.pri | 4 ++++ build/targets/monolithic.pro | 2 -- build/targets/qtgui.pri | 7 +++++++ build/targets/qtgui.pro | 2 ++ build/targets/target.pri | 3 ++- quassel.pro | 20 +++++++++++++++++--- 14 files changed, 77 insertions(+), 18 deletions(-) create mode 100644 build/targets/qtgui.pri create mode 100644 build/targets/qtgui.pro diff --git a/Quassel.kdevelop.filelist b/Quassel.kdevelop.filelist index 72570fff..d4e2802d 100644 --- a/Quassel.kdevelop.filelist +++ b/Quassel.kdevelop.filelist @@ -134,3 +134,7 @@ qtopia-build qtopia-build/Makefile src/qtopia/topicbar.cpp src/qtopia/topicbar.h +src/qtopia/chatline.cpp +src/qtopia/chatline.h +src/qtopia/chatwidget.cpp +src/qtopia/chatwidget.h diff --git a/build/modules/client.pro b/build/modules/client.pro index 0cfe577b..0ae61082 100644 --- a/build/modules/client.pro +++ b/build/modules/client.pro @@ -1,3 +1,2 @@ MODULE = client include(module.pri) - diff --git a/build/modules/common.pro b/build/modules/common.pro index 62421978..e2dcb4ec 100644 --- a/build/modules/common.pro +++ b/build/modules/common.pro @@ -1,3 +1,2 @@ MODULE = common include(module.pri) - diff --git a/build/modules/core.pro b/build/modules/core.pro index 64986f6f..4e30dc44 100644 --- a/build/modules/core.pro +++ b/build/modules/core.pro @@ -1,3 +1,2 @@ MODULE = core include(module.pri) - diff --git a/build/modules/module.pri b/build/modules/module.pri index 9de04b06..6be89a87 100644 --- a/build/modules/module.pri +++ b/build/modules/module.pri @@ -1,3 +1,6 @@ +# module.pri +# This file is included by module project files. + TEMPLATE = lib CONFIG += staticlib @@ -18,9 +21,9 @@ MODPATH = $$SRCPATH/$$MODULE # Path to the module files # Define build directories -OBJECTS_DIR = $${MODNAME}.tmp -MOC_DIR = $${MODNAME}.tmp -UI_DIR = $${MODNAME}.tmp +OBJECTS_DIR = .$$MODNAME +MOC_DIR = .$$MODNAME +UI_DIR = .$$MODNAME # Load module settings (files etc.) diff --git a/build/quassel.pro b/build/quassel.pro index fd36ddac..7ce23875 100644 --- a/build/quassel.pro +++ b/build/quassel.pro @@ -1,6 +1,29 @@ +# This project file can be used to set up a build environment for quassel. +# To build the default configuration (i.e. qtgui, core and monolithic client), +# simply run +# +# > qmake && make +# +# in this directory. In order to select the binaries to build, you may set +# the BUILD variable as follows: +# +# > qmake BUILD= && make +# +# where is a quoted string that may contain any of 'qtgui', 'core', 'mono' or 'all'. +# +# NOTE: To change the build configuration, you have to run 'make distclean' first! + + +# Set project-wide config options +CONFIG += qt debug warn_on + +TEMPLATE = subdirs + +# Check build configuration isEmpty(BUILD) { - BUILD = all + BUILD = all # build everything by default } + contains(BUILD, all) { BUILD += qtgui core mono } @@ -17,14 +40,18 @@ contains(BUILD, core) { BUILD_TARGETS *= core } -TEMPLATE = subdirs +contains(BUILD, qtgui) { + include(targets/qtgui.pri) + BUILD_MODS *= $${MODULES} + BUILD_TARGETS *= qtgui +} +# Now, we first build all needed modules... for(mod, BUILD_MODS) { SUBDIRS += modules/$${mod}.pro } +# ... followed by the binaries. for(target, BUILD_TARGETS) { SUBDIRS += targets/$${target}.pro } - -CONFIG += qt warn_on diff --git a/build/targets/core.pri b/build/targets/core.pri index 502a7d6f..e9cbc546 100644 --- a/build/targets/core.pri +++ b/build/targets/core.pri @@ -1,4 +1,8 @@ # Modules for quasselcore + +TARGET = quasselcore MODULES = core common contrib/qxt +DEFINES = BUILD_CORE + QT -= gui QT += network sql diff --git a/build/targets/core.pro b/build/targets/core.pro index bbd10934..69d78409 100644 --- a/build/targets/core.pro +++ b/build/targets/core.pro @@ -1,4 +1,2 @@ -TARGET = quasselcore -DEFINES += BUILD_CORE include(core.pri) include(target.pri) diff --git a/build/targets/monolithic.pri b/build/targets/monolithic.pri index 4e8ebd7e..5ba3269f 100644 --- a/build/targets/monolithic.pri +++ b/build/targets/monolithic.pri @@ -1,3 +1,7 @@ # Modules for monolithic client + +TARGET = quassel MODULES = core qtgui client common contrib/qxt +DEFINES = BUILD_MONO + QT += network sql diff --git a/build/targets/monolithic.pro b/build/targets/monolithic.pro index d8a767ee..f1afbe7e 100644 --- a/build/targets/monolithic.pro +++ b/build/targets/monolithic.pro @@ -1,4 +1,2 @@ -TARGET = quassel -DEFINES += BUILD_MONO include(monolithic.pri) include(target.pri) diff --git a/build/targets/qtgui.pri b/build/targets/qtgui.pri new file mode 100644 index 00000000..30930656 --- /dev/null +++ b/build/targets/qtgui.pri @@ -0,0 +1,7 @@ +# Modules for quasselclient + +TARGET = quasselclient +MODULES = qtgui client common contrib/qxt +DEFINES = BUILD_QTGUI + +QT += network diff --git a/build/targets/qtgui.pro b/build/targets/qtgui.pro new file mode 100644 index 00000000..f96c5a42 --- /dev/null +++ b/build/targets/qtgui.pro @@ -0,0 +1,2 @@ +include(qtgui.pri) +include(target.pri) diff --git a/build/targets/target.pri b/build/targets/target.pri index 29a8f6c3..8f4646fc 100644 --- a/build/targets/target.pri +++ b/build/targets/target.pri @@ -1,6 +1,7 @@ TEMPLATE = app + SRCPATH = ../../src -OBJECTS_DIR = $${TARGET}.tmp +OBJECTS_DIR = .$$TARGET for(mod, MODULES) { INCLUDEPATH *= $$SRCPATH/$$mod diff --git a/quassel.pro b/quassel.pro index 3c2b2646..0fe1b35a 100644 --- a/quassel.pro +++ b/quassel.pro @@ -1,3 +1,17 @@ -SUBDIRS += build/quassel.pro -TEMPLATE = subdirs -CONFIG += warn_on qt thread +# This project file can be used to set up a build environment for quassel. +# To build the default configuration (i.e. qtgui, core and monolithic client), +# simply run +# +# > qmake && make +# +# in this directory. In order to select the binaries to build, you may set +# the BUILD variable as follows: +# +# > qmake BUILD= && make +# +# where is a quoted string that may contain any of 'qtgui', 'core', 'mono' or 'all'. +# +# NOTE: To change the build configuration, you have to run 'make distclean' first! + +TEMPLATE = subdirs +SUBDIRS += build/quassel.pro -- 2.20.1