generated from administrator/template_project
clean
This commit is contained in:
+11
-36
@@ -1,37 +1,12 @@
|
|||||||
project(your_app)
|
cmake_minimum_required(VERSION 3.10)
|
||||||
cmake_minimum_required(VERSION 2.6)
|
|
||||||
|
project(test_server)
|
||||||
|
set(CMAKE_CXX_STANDARD 11)
|
||||||
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
||||||
|
|
||||||
find_package(PIP REQUIRED)
|
find_package(PIP REQUIRED)
|
||||||
find_package(QAD REQUIRED)
|
file(GLOB HDRS "*.h")
|
||||||
qad_find_qt(Qt5 Core Gui Widgets)
|
file(GLOB CPPS "*.cpp")
|
||||||
set(TARGET_SUFFIX_Qt5 "")
|
add_executable(${PROJECT_NAME} ${CPPS} ${HDRS})
|
||||||
set(CMAKE_INSTALL_PREFIX ${CMAKE_CURRENT_SOURCE_DIR}/..)
|
target_link_libraries(${PROJECT_NAME} PIP PIP::Console PIP::HTTPServer PIP::IOUtils PIP::ClientServer)
|
||||||
set_version(${PROJECT_NAME}
|
|
||||||
MAJOR 0
|
|
||||||
MINOR 0
|
|
||||||
REVISION 1
|
|
||||||
BUILD ${BUILD_NUMBER})
|
|
||||||
set_deploy_property(${PROJECT_NAME}
|
|
||||||
LABEL "${PROJECT_NAME}"
|
|
||||||
FULLNAME "App name"
|
|
||||||
COMPANY "Company"
|
|
||||||
INFO "Description")
|
|
||||||
if(WIN32)
|
|
||||||
set_deploy_property(${PROJECT_NAME} ICON "icons/logo.ico")
|
|
||||||
else()
|
|
||||||
set_deploy_property(${PROJECT_NAME} ICON "icons/logo.png")
|
|
||||||
endif()
|
|
||||||
set_lang(${PROJECT_NAME} en ru)
|
|
||||||
make_rc(${PROJECT_NAME} out_RC)
|
|
||||||
#pip_code_model(CCM "structs.h" OPTIONS "-ESs")
|
|
||||||
qad_sources(SRC)
|
|
||||||
qad_wrap(${SRC} HDRS out_HDR CPPS out_CPP QMS out_QM)
|
|
||||||
qad_add_executable(${PROJECT_NAME} out_CPP ${out_RC}) # ${CCM}
|
|
||||||
qad_target_link_libraries(${PROJECT_NAME} PIP QAD::Application)
|
|
||||||
qad_install(TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
|
|
||||||
qad_install(LANG out_QM DESTINATION ${CMAKE_INSTALL_PREFIX}/bin/lang)
|
|
||||||
qad_install_lang(${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_PREFIX}/bin/lang)
|
|
||||||
deploy_target(${PROJECT_NAME}
|
|
||||||
DEPLOY_DIR ${CMAKE_INSTALL_PREFIX}/bin
|
|
||||||
DESTINATION ${CMAKE_INSTALL_PREFIX}/release
|
|
||||||
RESOURCES lang/
|
|
||||||
OPTIONS --qt-plugins *=::imageformats=* --qt-plugins-dir plugins)
|
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 14 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB |
+8
-15
@@ -1,19 +1,12 @@
|
|||||||
//#include "mainwindow.h"
|
#include <pifile.h>
|
||||||
|
#include <pikbdlistener.h>
|
||||||
#include <QApplication>
|
|
||||||
#include <QIcon>
|
|
||||||
#include <QTranslator>
|
|
||||||
#include <qad_locations.h>
|
|
||||||
#include <qad_types.h>
|
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char * argv[]) {
|
int main(int argc, char * argv[]) {
|
||||||
QApplication a(argc, argv);
|
PIKbdListener ls;
|
||||||
a.setWindowIcon(QIcon(":/icons/logo.png"));
|
ls.enableExitCapture(PIKbdListener::F10);
|
||||||
QAD_SETUP_APPLICATION
|
ls.start();
|
||||||
enableHighDPI();
|
piCout << "started on" << httpaddr;
|
||||||
QAD::loadTranslations();
|
WAIT_FOR_EXIT
|
||||||
//MainWindow w;
|
ls.stopAndWait();
|
||||||
//w.show();
|
|
||||||
return a.exec();
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user