FS#10365 - Optional debug output for albumart.c
[kugel-rb.git] / rbutil / rbutilqt / rbutilqt.pro
blob3edcbdc11befd5edb193984ed4457b7ca3a166f1
1 unix:!mac {
2 CCACHE = $$system(which ccache)
3 !isEmpty(CCACHE) {
4 message("using ccache")
5 QMAKE_CXX = ccache g++
6 QMAKE_CC = ccache gcc
10 OBJECTS_DIR = build/o
11 UI_DIR = build/ui
12 MOC_DIR = build/moc
13 RCC_DIR = build/rcc
15 # check version of Qt installation
16 VER = $$find(QT_VERSION, ^4\.[3-9]+.*)
17 isEmpty(VER) {
18 !isEmpty(QT_VERSION) error("Qt found:" $$[QT_VERSION])
19 error("Qt >= 4.3 required!")
21 message("Qt version used:" $$VER)
23 # add a custom rule for pre-building librbspeex
24 !mac {
25 rbspeex.commands = @$(MAKE) -C ../../tools/rbspeex librbspeex.a
27 mac {
28 rbspeex.commands = @$(MAKE) -C ../../tools/rbspeex librbspeex-universal
30 QMAKE_EXTRA_TARGETS += rbspeex
31 PRE_TARGETDEPS += rbspeex
33 # rule for creating ctags file
34 tags.commands = ctags -R --c++-kinds=+p --fields=+iaS --extra=+q $(SOURCES)
35 tags.depends = $(SOURCES)
36 QMAKE_EXTRA_TARGETS += tags
38 # add a custom rule for making the translations
39 lrelease.commands = $$[QT_INSTALL_BINS]/lrelease -silent rbutilqt.pro
40 QMAKE_EXTRA_TARGETS += lrelease
41 !dbg {
42 PRE_TARGETDEPS += lrelease
46 SOURCES += rbutilqt.cpp \
47 main.cpp \
48 install.cpp \
49 base/httpget.cpp \
50 configure.cpp \
51 zip/zip.cpp \
52 zip/unzip.cpp \
53 base/zipinstaller.cpp \
54 progressloggergui.cpp \
55 installtalkwindow.cpp \
56 talkfile.cpp \
57 base/autodetection.cpp \
58 ../ipodpatcher/ipodpatcher.c \
59 ../sansapatcher/sansapatcher.c \
60 browsedirtree.cpp \
61 themesinstallwindow.cpp \
62 base/uninstall.cpp \
63 uninstallwindow.cpp \
64 base/utils.cpp \
65 preview.cpp \
66 base/encoders.cpp \
67 encttscfggui.cpp \
68 base/encttssettings.cpp \
69 base/tts.cpp \
70 ../../tools/wavtrim.c \
71 ../../tools/voicefont.c \
72 voicefile.cpp \
73 createvoicewindow.cpp \
74 base/rbsettings.cpp \
75 base/rbunzip.cpp \
76 base/rbzip.cpp \
77 base/detect.cpp \
78 sysinfo.cpp \
79 base/bootloaderinstallbase.cpp \
80 base/bootloaderinstallmi4.cpp \
81 base/bootloaderinstallhex.cpp \
82 base/bootloaderinstallipod.cpp \
83 base/bootloaderinstallsansa.cpp \
84 base/bootloaderinstallfile.cpp \
85 ../../tools/mkboot.c \
86 ../../tools/iriver.c
88 HEADERS += rbutilqt.h \
89 install.h \
90 base/httpget.h \
91 configure.h \
92 zip/zip.h \
93 zip/unzip.h \
94 zip/zipentry_p.h \
95 zip/unzip_p.h \
96 zip/zip_p.h \
97 version.h \
98 base/zipinstaller.h \
99 installtalkwindow.h \
100 talkfile.h \
101 base/autodetection.h \
102 progressloggerinterface.h \
103 progressloggergui.h \
104 ../ipodpatcher/ipodpatcher.h \
105 ../ipodpatcher/ipodio.h \
106 ../ipodpatcher/parttypes.h \
107 ../sansapatcher/sansapatcher.h \
108 ../sansapatcher/sansaio.h \
109 irivertools/h100sums.h \
110 irivertools/h120sums.h \
111 irivertools/h300sums.h \
112 browsedirtree.h \
113 themesinstallwindow.h \
114 base/uninstall.h \
115 uninstallwindow.h \
116 base/utils.h \
117 preview.h \
118 base/encoders.h \
119 encttscfggui.h \
120 base/encttssettings.h \
121 base/tts.h \
122 ../../tools/wavtrim.h \
123 ../../tools/voicefont.h \
124 voicefile.h \
125 createvoicewindow.h \
126 base/rbsettings.h \
127 base/rbunzip.h \
128 base/rbzip.h \
129 sysinfo.h \
130 base/detect.h \
131 base/bootloaderinstallbase.h \
132 base/bootloaderinstallmi4.h \
133 base/bootloaderinstallhex.h \
134 base/bootloaderinstallipod.h \
135 base/bootloaderinstallsansa.h \
136 base/bootloaderinstallfile.h \
137 ../../tools/mkboot.h \
138 ../../tools/iriver.h
140 # Needed by QT on Win
141 INCLUDEPATH = . irivertools zip zlib ../ipodpatcher ../sansapatcher ../../tools/rbspeex ../../tools
142 INCLUDEPATH += base
144 LIBS += -L../../tools/rbspeex -lrbspeex
146 TEMPLATE = app
147 dbg {
148 CONFIG += debug thread qt warn_on
149 DEFINES -= QT_NO_DEBUG_OUTPUT
150 message("debug")
152 !dbg {
153 CONFIG += release thread qt
154 DEFINES += QT_NO_DEBUG_OUTPUT
155 message("release")
158 TARGET = rbutilqt
160 FORMS += rbutilqtfrm.ui \
161 aboutbox.ui \
162 installfrm.ui \
163 progressloggerfrm.ui \
164 configurefrm.ui \
165 browsedirtreefrm.ui \
166 installtalkfrm.ui \
167 themesinstallfrm.ui \
168 uninstallfrm.ui \
169 previewfrm.ui \
170 createvoicefrm.ui \
171 sysinfofrm.ui
173 RESOURCES += rbutilqt.qrc
174 win32 {
175 RESOURCES += rbutilqt-win.qrc
177 !dbg {
178 RESOURCES += rbutilqt-lang.qrc
181 TRANSLATIONS += lang/rbutil_de.ts \
182 lang/rbutil_fi.ts \
183 lang/rbutil_fr.ts \
184 lang/rbutil_gr.ts \
185 lang/rbutil_he.ts \
186 lang/rbutil_ja.ts \
187 lang/rbutil_nl.ts \
188 lang/rbutil_pt.ts \
189 lang/rbutil_tr.ts \
190 lang/rbutil_zh_CN.ts \
191 lang/rbutil_zh_TW.ts \
194 QT += network
195 DEFINES += RBUTIL _LARGEFILE64_SOURCE
197 win32 {
198 SOURCES += ../ipodpatcher/ipodio-win32.c
199 SOURCES += ../sansapatcher/sansaio-win32.c
200 RC_FILE = rbutilqt.rc
201 LIBS += -lsetupapi -lnetapi32
204 unix {
205 SOURCES += ../ipodpatcher/ipodio-posix.c
206 SOURCES += ../sansapatcher/sansaio-posix.c
208 unix:!static {
209 LIBS += -lusb
211 unix:static {
212 # force statically linking of libusb. Libraries that are appended
213 # later will get linked dynamically again.
214 LIBS += -Wl,-Bstatic -lusb -Wl,-Bdynamic
217 macx {
218 QMAKE_MAC_SDK=/Developer/SDKs/MacOSX10.4u.sdk
219 QMAKE_LFLAGS_PPC=-mmacosx-version-min=10.4 -arch ppc
220 QMAKE_LFLAGS_X86=-mmacosx-version-min=10.4 -arch i386
221 CONFIG+=x86 ppc
222 LIBS += -L/usr/local/lib -framework IOKit
223 INCLUDEPATH += /usr/local/include
224 QMAKE_INFO_PLIST = Info.plist
225 RC_FILE = icons/rbutilqt.icns
227 # rule for creating a dmg file
228 dmg.commands = hdiutil create -ov -srcfolder rbutilqt.app/ rbutil.dmg
229 QMAKE_EXTRA_TARGETS += dmg
232 static {
233 QTPLUGIN += qtaccessiblewidgets
234 LIBS += -L$$(QT_BUILD_TREE)/plugins/accessible -lqtaccessiblewidgets
235 LIBS += -L.
236 DEFINES += STATIC
237 message("using static plugin")
240 unix {
241 target.path = /usr/local/bin
242 INSTALLS += target