--- qsampler/trunk/src/src.pro 2012/12/29 00:21:11 2387 +++ qsampler/trunk/src/src.pro 2017/12/01 14:47:13 3383 @@ -1,10 +1,9 @@ # qsampler.pro # -TARGET = qsampler +NAME = qsampler +TARGET = $${NAME} TEMPLATE = app -DEPENDPATH += . -INCLUDEPATH += . include(src.pri) @@ -65,9 +64,12 @@ RESOURCES += \ qsampler.qrc + TRANSLATIONS += \ - translations/qsampler_cs.ts \ - translations/qsampler_ru.ts + translations/qsampler_cs.ts \ + translations/qsampler_fr.ts \ + translations/qsampler_ru.ts + unix { @@ -80,33 +82,49 @@ PREFIX = /usr/local } - BINDIR = $$PREFIX/bin - DATADIR = $$PREFIX/share - LOCALEDIR = $(localedir) - - DEFINES += DATADIR=\"$$DATADIR\" + isEmpty(BINDIR) { + BINDIR = $${PREFIX}/bin + } - !isEmpty(LOCALEDIR) { - DEFINES += LOCALEDIR=\"$$LOCALEDIR\" + isEmpty(DATADIR) { + DATADIR = $${PREFIX}/share } + #DEFINES += DATADIR=\"$${DATADIR}\" + # make install - INSTALLS += target desktop icon + INSTALLS += target desktop icon appdata \ + icon_scalable mimeinfo mimetypes mimetypes_scalable + + target.path = $${BINDIR} - target.path = $$BINDIR + desktop.path = $${DATADIR}/applications + desktop.files += $${NAME}.desktop - desktop.path = $$DATADIR/applications - desktop.files += $${TARGET}.desktop + icon.path = $${DATADIR}/icons/hicolor/32x32/apps + icon.files += images/$${NAME}.png - icon.path = $$DATADIR/icons/hicolor/32x32/apps - icon.files += images/$${TARGET}.png + icon_scalable.path = $${DATADIR}/icons/hicolor/scalable/apps + icon_scalable.files += images/$${NAME}.svg + + appdata.path = $${DATADIR}/metainfo + appdata.files += appdata/$${NAME}.appdata.xml + + mimeinfo.path = $${DATADIR}/mime/packages + mimeinfo.files += mimetypes/$${NAME}.xml + + 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.svg } win32 { CONFIG(debug, debug|release): CONFIG += console INSTALLS += target - target.path = $$PREFIX/bin + target.path = $${PREFIX}/bin } macx { @@ -115,5 +133,8 @@ CONFIG += $$(QMAKE_ARCHS) } -# QT5 Support -QT += widgets + +# QT5 support +!lessThan(QT_MAJOR_VERSION, 5) { + QT += widgets +}