diff --git a/CocosDenshion/proj.qt5/cocosdenshion.pro b/CocosDenshion/proj.qt5/cocosdenshion.pro index d0b91990cb..0895763525 100644 --- a/CocosDenshion/proj.qt5/cocosdenshion.pro +++ b/CocosDenshion/proj.qt5/cocosdenshion.pro @@ -10,3 +10,6 @@ INCLUDEPATH += ../include TARGET = $${LIB_OUTPUT_DIR}/cocosdenshion +INSTALLS += target +target.path = $${LIB_INSTALL_DIR} + diff --git a/cocos2dx/proj.qt5/cocos2dx.pro b/cocos2dx/proj.qt5/cocos2dx.pro index 3e90835133..1633deb994 100644 --- a/cocos2dx/proj.qt5/cocos2dx.pro +++ b/cocos2dx/proj.qt5/cocos2dx.pro @@ -157,3 +157,6 @@ INCLUDEPATH += ../../extensions/Components TARGET = $${LIB_OUTPUT_DIR}/cocos2d +INSTALLS += target +target.path = $${LIB_INSTALL_DIR} + diff --git a/cocos2dx/proj.qt5/common.pri b/cocos2dx/proj.qt5/common.pri index 8b772a9816..c298e7189e 100644 --- a/cocos2dx/proj.qt5/common.pri +++ b/cocos2dx/proj.qt5/common.pri @@ -17,6 +17,11 @@ CONFIG(debug, debug|release) { OBJECTS_DIR = obj/$${BUILD_TYPE} LIB_OUTPUT_DIR = $${PWD}/../../lib/$${OS_TYPE}/$${BUILD_TYPE} +# Installation location of binaries +LIB_INSTALL_DIR = /usr/lib +BIN_INSTALL_DIR = /usr/bin +DESKTOP_INSTALL_DIR = /usr/share/applications + INCLUDEPATH += $${PWD}/.. INCLUDEPATH += $${PWD}/../include INCLUDEPATH += $${PWD}/../platform diff --git a/samples/Cpp/TestCpp/proj.qt5/TestCpp.pro b/samples/Cpp/TestCpp/proj.qt5/TestCpp.pro index cbfbe1ffae..444c745512 100644 --- a/samples/Cpp/TestCpp/proj.qt5/TestCpp.pro +++ b/samples/Cpp/TestCpp/proj.qt5/TestCpp.pro @@ -1,7 +1,7 @@ include(../../../../cocos2dx/proj.qt5/common.pri) -TARGET = TestCpp +TARGET = cocos2dx_TestCpp INCLUDEPATH += .. INCLUDEPATH += ../Classes @@ -111,3 +111,14 @@ LIBS += $${LINK_AGAINST_COCOS2DX} LIBS += $${LINK_AGAINST_COCOSDENSHION} LIBS += $${LINK_AGAINST_COCOSEXTENSION} +INSTALLS += target +target.path = /opt/$${TARGET} + +INSTALLS += desktop +desktop.files = $${TARGET}.desktop +desktop.path = $${DESKTOP_INSTALL_DIR} + +INSTALLS += resources +resources.files = icon.png ../Resources +resources.path = /opt/$${TARGET} + diff --git a/samples/Cpp/TestCpp/proj.qt5/cocos2dx_TestCpp.desktop b/samples/Cpp/TestCpp/proj.qt5/cocos2dx_TestCpp.desktop new file mode 100644 index 0000000000..8447988c7f --- /dev/null +++ b/samples/Cpp/TestCpp/proj.qt5/cocos2dx_TestCpp.desktop @@ -0,0 +1,5 @@ +[Desktop Entry] +Type=Application +Name=Cocos2D-X +Icon=/opt/cocos2dx_TestCpp/icon.png +Exec=/opt/cocos2dx_TestCpp/cocos2dx_TestCpp