--- qsampler/trunk/src/src.pro 2012/12/29 00:21:11 2387 +++ qsampler/trunk/src/src.pro 2013/07/01 10:16:35 2457 @@ -1,10 +1,9 @@ # qsampler.pro # -TARGET = qsampler +NAME = qsampler +TARGET = $${NAME} TEMPLATE = app -DEPENDPATH += . -INCLUDEPATH += . include(src.pri) @@ -69,6 +68,7 @@ translations/qsampler_cs.ts \ translations/qsampler_ru.ts + unix { # variables @@ -80,33 +80,46 @@ PREFIX = /usr/local } - BINDIR = $$PREFIX/bin - DATADIR = $$PREFIX/share + BINDIR = $${PREFIX}/bin + DATADIR = $${PREFIX}/share LOCALEDIR = $(localedir) - DEFINES += DATADIR=\"$$DATADIR\" + DEFINES += DATADIR=\"$${DATADIR}\" !isEmpty(LOCALEDIR) { - DEFINES += LOCALEDIR=\"$$LOCALEDIR\" + DEFINES += LOCALEDIR=\"$${LOCALEDIR}\" } # make install - INSTALLS += target desktop icon + INSTALLS += target desktop icon \ + icon_scalable mimeinfo mimetypes mimetypes_scalable + + target.path = $${BINDIR} + + desktop.path = $${DATADIR}/applications + desktop.files += $${NAME}.desktop + + icon.path = $${DATADIR}/icons/hicolor/32x32/apps + icon.files += images/$${NAME}.png - target.path = $$BINDIR + icon_scalable.path = $${DATADIR}/icons/hicolor/scalable/apps + icon_scalable.files += images/$${NAME}.svgz - desktop.path = $$DATADIR/applications - desktop.files += $${TARGET}.desktop + mimeinfo.path = $${DATADIR}/mime/packages + mimeinfo.files += mimetypes/$${NAME}.xml - icon.path = $$DATADIR/icons/hicolor/32x32/apps - icon.files += images/$${TARGET}.png + mimetypes.path = $${DATADIR}/icons/hicolor/32x32/mimetypes + mimetypes.files += mimetypes/application-x-$${NAME}-session.png + + mimetypes_scalable.path = $${DATADIR}/icons/hicolor/scalable/mimetypes + mimetypes_scalable.files += mimetypes/application-x-$${NAME}-session.svgz } win32 { CONFIG(debug, debug|release): CONFIG += console INSTALLS += target - target.path = $$PREFIX/bin + target.path = $${PREFIX}/bin } macx { @@ -115,5 +128,8 @@ CONFIG += $$(QMAKE_ARCHS) } -# QT5 Support -QT += widgets + +# QT5 support +!lessThan(QT_MAJOR_VERSION, 5) { + QT += widgets +}