source: tspsg/tspsg.pro @ 162d5c5f94

0.1.3.145-beta1-symbian0.1.4.170-beta2-bb10appveyorimgbotreadme
Last change on this file since 162d5c5f94 was 162d5c5f94, checked in by Oleksii Serdiuk, 15 years ago
  • Fixed some wrong defines that prevented successful compilation under *nix.
  • Renamed i18n to l10n to follow common standards.
  • Translation and documentation paths are now synchronized between .pro and source.
  • Moved some versioning information to .pro file.
  • Updated translations.
  • Property mode set to 100644
File size: 3.3 KB
Line 
1######################################################################
2#
3#  TSPSG: TSP Solver and Generator
4#  Copyright (C) 2007-2010 Lёppa <contacts[at]oleksii[dot]name>
5#
6#  $Id$
7#  $URL$
8#
9#  This file is part of TSPSG.
10#
11######################################################################
12
13QT += svg
14
15TEMPLATE = app
16TARGET = tspsg
17DEPENDPATH += .
18INCLUDEPATH += .
19
20# Versioning
21BUILD_VERSION_MAJOR = 0
22BUILD_VERSION_MINOR = 1
23BUILD_RELEASE = 2
24
25# This one is only defined on releases
26#DEFINES += TSPSG_RELEASE_BUILD
27
28REVISION = $$system(svnversion)
29REVISION = $$replace(REVISION,"M","")
30VERSION = $$sprintf("%1.%2.%3",$$BUILD_VERSION_MAJOR,$$BUILD_VERSION_MINOR,$$BUILD_RELEASE)
31
32DEFINES += BUILD_VERSION_MAJOR=$$BUILD_VERSION_MAJOR \
33        BUILD_VERSION_MINOR=$$BUILD_VERSION_MINOR \
34        BUILD_RELEASE=$$BUILD_RELEASE \
35        BUILD_NUMBER=$$REVISION
36
37# A hack to determine whether we have static or dynamic Qt build
38unix:!symbian {
39        PRL = $$[QT_INSTALL_LIBS] libQtCore.prl
40} else:unix {
41        PRL = $$[QT_INSTALL_LIBS] QtCore.prl
42}
43include($$join(PRL, "/"))
44contains(QMAKE_PRL_CONFIG, static) {
45# We "embed" SVG and JPEG support on static build
46        QTPLUGIN += qjpeg qsvg
47        DEFINES += STATIC_BUILD
48}
49
50CONFIG(release, debug|release) {
51        OBJECTS_DIR = release
52        DESTDIR = release
53} else {
54        OBJECTS_DIR = debug
55        DESTDIR = debug
56        DEFINES += DEBUG
57}
58
59# Saving all intermediate files to tmp directory.
60MOC_DIR = ./tmp
61RCC_DIR = ./tmp
62UI_DIR = ./tmp
63
64# Include file(s)
65include(tspsg.pri)
66
67# Installation and deployment
68# Common rules
69#share.files =
70l10n.files = l10n/*.qm
71docs.files = COPYING README
72INSTALLS += target l10n share docs
73
74# For *nix:
75#   - executable goes to /usr/bin
76#   - COPYING and README go to /usr/share/tspsg
77#   - translations go to /usr/share/tspsg/l10n
78#   - docs (none, yet) go to /usr/share/doc/tspsg
79unix:!symbian {
80        PREFIX = /usr
81        CONFIG(release, debug|release) {
82                DEFINES += PATH_L10N=\\\"$$PREFIX/share/tspsg/l10n\\\"
83                DEFINES += PATH_DOCS=\\\"$$PREFIX/share/tspsg/docs\\\"
84        }
85
86        target.path = $$PREFIX/bin
87        share.path = $$PREFIX/share/tspsg
88        l10n.path = $$PREFIX/share/tspsg/l10n
89        docs.path = $$PREFIX/share/doc/tspsg-$$VERSION
90        apps.path = $$PREFIX/share/applications/
91        apps.files = resources/tspsg.desktop
92        icon.path = $$PREFIX/share/pixmaps
93        icon.files = resources/tspsg.png
94        INSTALLS += apps icon
95}
96
97# TODO: MacOSX
98
99# For win32: everything goes to "C:\Program Files\tspsg" and subfolders.
100win32 {
101        PREFIX = "C:\Program Files"
102}
103
104# For wince: we are deploying to \Storage Card\Program Files\tspsg.
105wince {
106        PREFIX = "\Storage Card\Program Files"
107        DEPLOYMENT += target share l10n docs
108}
109
110# win32 and wince common
111win* {
112        target.path = "$$PREFIX\tspsg"
113        share.path = "$$PREFIX\tspsg"
114        l10n.path = "$$PREFIX\tspsg\l10n"
115        docs.path = "$$PREFIX\tspsg"
116
117        RC_FILE = resources/tspsg.rc
118}
119
120# Symbian
121symbian {
122        l10n.path = l10n
123        docs.pkg_prerules = \
124                "\"README\" - \"\", FILETEXT, TEXTCONTINUE" \
125                "\"COPYING\" - \"\", FILETEXT, TEXTEXIT"
126        DEPLOYMENT += share l10n docs
127
128        ICON = resources/tspsg.svg
129
130        appinfo = \
131                "$$LITERAL_HASH{\"TSPSG\"},(0xEb9dce0e),0,1,2"
132        vendorinfo = \
133                "%{\"l-homes.org\"}" \
134                ":\"l-homes.org\""
135        default_deployment.pkg_prerules = appinfo vendorinfo
136        DEPLOYMENT.installer_header = "$${LITERAL_HASH}{\"TSPSG Installer\"},(0xA000D7CE),1,0,0"
137}
Note: See TracBrowser for help on using the repository browser.