-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmeson-player.qbs
174 lines (154 loc) · 5.71 KB
/
meson-player.qbs
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
/****************************************************************************}
{ meson-player.qbs - main project file }
{ }
{ This file is a part of the project }
{ Meson Player - Music Player with no GUI }
{ }
{ Copyright (c) 2012 Alkatraz Studio }
{ }
{ author: Alexey Parfenov a.k.a. ZXED }
{ author's e-mail: zxed@alkatrazstudio.net }
{ }
{ Meson Player 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. }
{ }
{ Meson Player 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 may read the GNU General Public License at: }
{ https://www.gnu.org/copyleft/gpl.html }
{ }
{ project started: July 22, 2012 }
{****************************************************************************/
import qbs.TextFile
Project {
minimumQbsVersion: '1.13.0'
property bool ctrlProfile: false
qbsSearchPaths: [
'./common',
'./meson-sound-engine'
]
QtGuiApplication {
name: 'mesonplayer'
version: Version.autoVersion
Depends {
name: 'Qt'
submodules: ['core', 'gui', 'widgets', 'network']
}
Depends {name: 'Version'}
Depends {name: 'Common'}
Depends {name: 'CoreApp'}
Depends {name: 'ErrorManager'}
Depends {name: 'QIODeviceHelper'}
Depends {name: 'NotificationPopup'}
Depends {name: 'SimpleCrypt'}
Depends {name: 'MesonSoundEngine'}
Depends {
condition: Common.isLinux
name: 'xcb'
}
Depends {
condition: Common.isLinux
name: 'xcb-keysyms'
}
CoreApp.singleInstanceKey: name
CoreApp.dummyWindow: true
Common.appTitle: 'Meson Player'
qbs.installPrefix: ''
consoleApplication: ctrlProfile
targetName: name + (ctrlProfile ? "ctrl" : "")
MesonSoundEngine.sourceUrl: true
MesonSoundEngine.lastfm: true
MesonSoundEngine.mpris: true
MesonSoundEngine.mixer: true
Group {
name: 'App'
files: {
var files = [
'main.cpp',
'app.h',
'app.cpp',
'lastfmpassform.h',
'lastfmpassform.cpp',
'movetotrash.h',
'movetotrash.cpp',
'data.qrc'
]
if(Common.isLinux)
{
files.push('eventqueue.h')
files.push('eventqueue.cpp')
}
return files
}
}
cpp.defines: {
var defs = []
if(lfmDecryptKeyProbe.lfmDecryptKey)
defs.push('LFM_DECRYPT_KEY=0x' + lfmDecryptKeyProbe.lfmDecryptKey)
return defs
}
cpp.dynamicLibraries: {
var libs = []
if(Common.isWindows)
libs.push('uuid')
return libs
}
Properties {
condition: Common.isOSX
cpp.frameworks: outer.concat([
'Carbon'
])
}
Group {
name: 'Assets'
condition: !project.ctrlProfile
qbs.install: Common.realInstall
qbs.installSourceBase: ''
files: [
'icons/*.png',
'icons/*.ico'
]
}
Group {
name: 'Manual'
condition: !project.ctrlProfile
qbs.install: Common.realInstall
qbs.installDir: 'manual'
files: [
'manual/dist/*.html',
'manual/dist/*.css',
'manual/dist/*.svg',
'manual/dist/*.png'
]
}
Group {
name: 'Plugins'
condition: !project.ctrlProfile
qbs.install: Common.realInstall
qbs.installSourceBase: ''
files: [
'plugins/*.' + Common.libExt
]
}
Probe {
id: lfmDecryptKeyProbe
property string lfmDecryptKey
configure: {
try{
var f = TextFile(path+'/services/lastfm/key')
lfmDecryptKey = f.readLine()
found = true
}catch(e){
console.warn(e)
lfmDecryptKey = ''
found = false
}
}
}
}
}