xref: /glogg/glogg.pro (revision b5a5d5fa3f4d72b6f1109d0e758da611083fcac0)
1# -------------------------------------------------
2# glogg
3# -------------------------------------------------
4TARGET = glogg
5TEMPLATE = app
6
7win32:Debug:CONFIG += console
8
9# Input
10SOURCES += main.cpp \
11    mainwindow.cpp \
12    crawlerwidget.cpp \
13    abstractlogdata.cpp \
14    logdata.cpp \
15    logfiltereddata.cpp \
16    abstractlogview.cpp \
17    logmainview.cpp \
18    filteredview.cpp \
19    optionsdialog.cpp \
20    configuration.cpp \
21    filtersdialog.cpp \
22    filterset.cpp \
23    savedsearches.cpp
24
25HEADERS += version.h \
26    mainwindow.h \
27    crawlerwidget.h \
28    logmainview.h \
29    log.h \
30    filteredview.h \
31    abstractlogdata.h \
32    logdata.h \
33    logfiltereddata.h \
34    abstractlogview.h \
35    optionsdialog.h \
36    configuration.h \
37    filtersdialog.h \
38    filterset.h \
39    savedsearches.h
40
41greaterThan(QT_VERSION, "4.4.0") {
42    FORMS += filtersdialog.ui
43}
44else {
45    message(Using old FiltersDialog)
46    FORMS += filtersdialog_old.ui
47}
48
49# For Windows icon
50RC_FILE = glogg.rc
51RESOURCES = glogg.qrc
52
53# Install (for unix)
54target.path = $$PREFIX/bin
55INSTALLS = target
56
57# Build directories
58debug:OBJECTS_DIR = $${OUT_PWD}/.obj/debug-shared
59release:OBJECTS_DIR = $${OUT_PWD}/.obj/release-shared
60debug:MOC_DIR = $${OUT_PWD}/.moc/debug-shared
61release:MOC_DIR = $${OUT_PWD}/.moc/release-shared
62
63Release:DEFINES += FILELOG_MAX_LEVEL=\"logERROR\"
64Debug:DEFINES += FILELOG_MAX_LEVEL=\"logDEBUG\"
65
66# Official builds can be generated with `qmake VERSION="1.2.3"'
67isEmpty(VERSION) {
68    QMAKE_CXXFLAGS += -DGLOGG_DATE=\\\"`date +'\"%F\"'`\\\"
69    QMAKE_CXXFLAGS += -DGLOGG_VERSION=\\\"`git describe`\\\"
70    QMAKE_CXXFLAGS += -DGLOGG_COMMIT=\\\"`git rev-parse --short HEAD`\\\"
71}
72else {
73    QMAKE_CXXFLAGS += -DGLOGG_VERSION=\\\"$$VERSION\\\"
74}
75