~online-accounts/libaccounts-qt/13.04

1 by Alberto Mardegan
Initial commit
1
#-----------------------------------------------------------------------------
2
# Common configuration for all projects.
3
#-----------------------------------------------------------------------------
4
75 by Jussi Laako
Fix build on x86-64
5
QT             -= gui
1 by Alberto Mardegan
Initial commit
6
CONFIG         += link_pkgconfig
7
MOC_DIR         = .moc
8
OBJECTS_DIR     = .obj
9
RCC_DIR         = resources
10
UI_DIR          = ui
11
UI_HEADERS_DIR  = ui/include
12
UI_SOURCES_DIR  = ui/src
13
14
TOP_SRC_DIR     = $$PWD
112 by Ken VanDine
More out of tree fixes and use QMAKE_SUBSTITUTE instead of sed
15
TOP_BUILD_DIR   = $${TOP_SRC_DIR}/$${BUILD_DIR}
1 by Alberto Mardegan
Initial commit
16
QMAKE_LIBDIR   += $${TOP_BUILD_DIR}/Accounts
17
INCLUDEPATH    += $${TOP_SRC_DIR}
18
19
# we don't like warnings...
20
#QMAKE_CXXFLAGS *= -Werror
21
103 by Alberto Mardegan
Support building with Qt5
22
greaterThan(QT_MAJOR_VERSION, 4) {
23
    # Qt5: use C++11. This is used to avoid the source incompatibility
24
    # with the QSKIP macro, as described in:
25
    # http://www.kdab.com/porting-from-qt-4-to-qt-5/
26
    QMAKE_CXXFLAGS += -std=c++11
27
}
28
75 by Jussi Laako
Fix build on x86-64
29
#-----------------------------------------------------------------------------
30
# setup the installation prefix
31
#-----------------------------------------------------------------------------
32
INSTALL_PREFIX = /usr  # default installation prefix
33
34
# default prefix can be overriden by defining PREFIX when running qmake
35
isEmpty( PREFIX ) {
36
    message("====")
37
    message("==== NOTE: To override the installation path run: `qmake PREFIX=/custom/path'")
38
    message("==== (current installation path is `$${INSTALL_PREFIX}')")
39
} else {
40
    INSTALL_PREFIX = $${PREFIX}
41
    message("====")
42
    message("==== install prefix set to `$${INSTALL_PREFIX}'")
43
}
44
45
ARCH = $$system(uname -m)
46
contains( ARCH, x86_64 ) {
47
    INSTALL_LIBDIR = $${INSTALL_PREFIX}/lib64
48
} else {
49
    INSTALL_LIBDIR = $${INSTALL_PREFIX}/lib
50
}
51
52
# default library directory can be overriden by defining LIBDIR when
53
# running qmake
54
isEmpty( LIBDIR ) {
55
    message("====")
56
    message("==== NOTE: To override the library installation path run: `qmake LIBDIR=/custom/path'")
57
    message("==== (current installation path is `$${INSTALL_LIBDIR}')")
58
} else {
59
    INSTALL_LIBDIR = $${LIBDIR}
60
    message("====")
61
    message("==== library install path set to `$${INSTALL_LIBDIR}'")
62
}
1 by Alberto Mardegan
Initial commit
63
99 by Víctor R. Ruiz
Coverage support (qmake CONFIG+=coverage)
64
include( coverage.pri )
65
1 by Alberto Mardegan
Initial commit
66
# End of File
67