forked from fpoussin/QStlink2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
QStlink2.pro
93 lines (76 loc) · 2.44 KB
/
QStlink2.pro
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#-------------------------------------------------
#
# Project created by QtCreator 2011-11-22T10:09:14
#
#-------------------------------------------------
#
# This file is part of QSTLink2.
#
# QSTLink2 is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# QSTLink2 is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with QSTLink2. If not, see <http://www.gnu.org/licenses/>.
QT += core gui xml
contains(QT_MAJOR_VERSION, 5) { QT += widgets }
#win32:CONFIG += console
win32:CONFIG += winusb
TEMPLATE = app
TARGET = qstlink2
VERSION = 1.3.0
message(Building version $$VERSION for Qt $$QT_VERSION)
VERSTR = '\\"$${VERSION}\\"' # place quotes around the version string
DEFINES += __QSTL_VER__=\"$${VERSTR}\" # create a VER macro containing the version string
INCLUDEPATH += $$PWD/inc
FORMS += ui/mainwindow.ui \
ui/dialog.ui
SOURCES += src/main.cpp\
src/mainwindow.cpp \
src/stlinkv2.cpp \
src/devices.cpp \
src/dialog.cpp \
src/transferthread.cpp \
src/loader.cpp
HEADERS += inc/mainwindow.h \
inc/stlinkv2.h \
inc/devices.h \
inc/dialog.h \
inc/transferthread.h \
inc/compat.h \
inc/loader.h
include(QtUsb/src/QtUsb.pri)
win32 {
TARGET = qstlink2_$${VERSION}
CONFIG(console) {
message(Building with debug console.)
TARGET = qstlink2_console_$${VERSION}
}
}
RESOURCES += res/ressources.qrc loaders/loaders.qrc
# Icon for windows
win32:RC_FILE = res/qstlink2.rc
# OSX
macx:ICON = res/images/icon.icns
target.path = /usr/bin
INSTALLS += target
conf.path = /etc/udev/rules.d
conf.files = res/49-stlinkv2.rules
INSTALLS += conf
misc.path = /usr/share/qstlink2
misc.files = res/devices.xml res/help.html
INSTALLS += misc
unix:!macx {
icon.path = /usr/share/pixmaps
icon.files = res/images/qstlink2.png
INSTALLS += icon
launcher.path = /usr/share/applications
launcher.files = res/qstlink2.desktop
INSTALLS += launcher
}