Compare commits
1 Commits
release
...
concurrent
| Author | SHA1 | Date | |
|---|---|---|---|
| a29302e2e6 |
168
CMakeLists.txt
@@ -9,84 +9,18 @@ project(libs)
|
|||||||
set(PIP_CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/pip/cmake")
|
set(PIP_CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/pip/cmake")
|
||||||
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}" "${PIP_CMAKE_MODULE_PATH}" "${CMAKE_CURRENT_SOURCE_DIR}/qad/cmake")
|
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}" "${PIP_CMAKE_MODULE_PATH}" "${CMAKE_CURRENT_SOURCE_DIR}/qad/cmake")
|
||||||
set(LIBPROJECT 1)
|
set(LIBPROJECT 1)
|
||||||
set(_qt_libs )
|
|
||||||
set(_qt_apps )
|
|
||||||
set(_qt_plugs)
|
|
||||||
include(GenerateExportHeader)
|
|
||||||
include(SDKMacros)
|
include(SDKMacros)
|
||||||
include(QADMacros)
|
|
||||||
include(DeployMacros)
|
include(DeployMacros)
|
||||||
|
set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
||||||
if(NOT DEFINED BUILD_NUMBER)
|
if(NOT DEFINED BUILD_NUMBER)
|
||||||
set(BUILD_NUMBER 9999)
|
set(BUILD_NUMBER 9999)
|
||||||
endif()
|
endif()
|
||||||
if("x${BUILD_NUMBER}" STREQUAL "x")
|
if("x${BUILD_NUMBER}" STREQUAL "x")
|
||||||
set(BUILD_NUMBER 0)
|
set(BUILD_NUMBER 0)
|
||||||
endif()
|
endif()
|
||||||
|
set(_COMPANY SHS)
|
||||||
|
set(_DOMAIN org.SHS)
|
||||||
if(STATIC_LIB)
|
|
||||||
set(QAD_LIB_TYPE STATIC)
|
|
||||||
add_definitions(-DQAD_STATIC_DEFINE)
|
|
||||||
set(QAD_LIB_TYPE_MSG "Static")
|
|
||||||
else()
|
|
||||||
set(QAD_LIB_TYPE SHARED)
|
|
||||||
set(QAD_LIB_TYPE_MSG "Shared")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(_QAD_MAJOR 1)
|
|
||||||
set(_QAD_MINOR 9)
|
|
||||||
set(_QAD_REVISION 0)
|
|
||||||
set(_QAD_SUFFIX )
|
|
||||||
set(_QAD_COMPANY SHS)
|
|
||||||
set(_QAD_DOMAIN org.SHS)
|
|
||||||
set(QAD_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/qad/qad_version.h")
|
|
||||||
set_version(QAD
|
|
||||||
MAJOR "${_QAD_MAJOR}"
|
|
||||||
MINOR "${_QAD_MINOR}"
|
|
||||||
REVISION "${_QAD_REVISION}"
|
|
||||||
BUILD "${BUILD_NUMBER}"
|
|
||||||
SUFFIX "${_QAD_SUFFIX}"
|
|
||||||
OUTPUT "${QAD_VERSION_FILE}")
|
|
||||||
set_deploy_property(QAD ${QAD_LIB_TYPE}
|
|
||||||
FULLNAME "${_QAD_DOMAIN}.*"
|
|
||||||
COMPANY "${_QAD_COMPANY}")
|
|
||||||
|
|
||||||
|
|
||||||
if(STATIC_LIB)
|
|
||||||
set(PIQt_LIB_TYPE STATIC)
|
|
||||||
add_definitions(-DPIQt_STATIC_DEFINE)
|
|
||||||
set(PIQt_LIB_TYPE_MSG "Static")
|
|
||||||
else()
|
|
||||||
set(PIQt_LIB_TYPE SHARED)
|
|
||||||
set(PIQt_LIB_TYPE_MSG "Shared")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(_PIQt_MAJOR 1)
|
|
||||||
set(_PIQt_MINOR 0)
|
|
||||||
set(_PIQt_REVISION 0)
|
|
||||||
set(_PIQt_SUFFIX )
|
|
||||||
set(_PIQt_COMPANY SHS)
|
|
||||||
set(_PIQt_DOMAIN org.SHS)
|
|
||||||
if(NOT DEFINED BUILD_NUMBER)
|
|
||||||
set(BUILD_NUMBER 9999)
|
|
||||||
endif()
|
|
||||||
set(PIQt_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/piqt/piqt_version.h")
|
|
||||||
set_version(PIQt
|
|
||||||
MAJOR "${_PIQt_MAJOR}"
|
|
||||||
MINOR "${_PIQt_MINOR}"
|
|
||||||
REVISION "${_PIQt_REVISION}"
|
|
||||||
BUILD "${BUILD_NUMBER}"
|
|
||||||
SUFFIX "${_PIQt_SUFFIX}"
|
|
||||||
OUTPUT "${PIQt_VERSION_FILE}")
|
|
||||||
set_deploy_property(PIQt ${_PIQt_LIB_TYPE}
|
|
||||||
FULLNAME "${_PIQt_DOMAIN}.*"
|
|
||||||
COMPANY "${_PIQt_COMPANY}")
|
|
||||||
|
|
||||||
|
|
||||||
include_directories(${CMAKE_CURRENT_BINARY_DIR}/pip)
|
include_directories(${CMAKE_CURRENT_BINARY_DIR}/pip)
|
||||||
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/qad)
|
|
||||||
include_directories(${CMAKE_CURRENT_BINARY_DIR}/piqt)
|
|
||||||
if(MINGW)
|
if(MINGW)
|
||||||
find_package(MinGW REQUIRED)
|
find_package(MinGW REQUIRED)
|
||||||
else()
|
else()
|
||||||
@@ -111,22 +45,21 @@ if (DEFINED ANDROID_PLATFORM)
|
|||||||
#message("${ANDROID_NDK}/sysroot/usr/include")
|
#message("${ANDROID_NDK}/sysroot/usr/include")
|
||||||
endif()
|
endif()
|
||||||
set(INSTALL_PREFIX "")
|
set(INSTALL_PREFIX "")
|
||||||
set(_plugins_default_ ON)
|
set(_plugins_default_ 1)
|
||||||
if(CMAKE_CROSSCOMPILING)
|
if(CMAKE_CROSSCOMPILING)
|
||||||
if (DEFINED ANDROID_PLATFORM)
|
if (DEFINED ANDROID_PLATFORM)
|
||||||
set(_plugins_default_ OFF)
|
set(_plugins_default_ 0)
|
||||||
set(INSTALL_PREFIX "${CMAKE_FIND_ROOT_PATH}/")
|
set(INSTALL_PREFIX "${CMAKE_FIND_ROOT_PATH}/")
|
||||||
else()
|
else()
|
||||||
set(INSTALL_PREFIX "${CMAKE_STAGING_PREFIX}")
|
set(INSTALL_PREFIX "${CMAKE_STAGING_PREFIX}")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
option(CROSSTOOLS "Crosstools minimal build" OFF)
|
option(CROSSTOOLS "Crosstools minimal build" 0)
|
||||||
option(LIB "System install" ON)
|
option(LIB "System install" 1)
|
||||||
option(QGLVIEW "Build QGLview library and utils" OFF)
|
option(QGLVIEW "Build QGLview library and utils" 0)
|
||||||
option(QGLENGINE "Build QGLENGINE library and utils" OFF)
|
option(QGLENGINE "Build QGLENGINE library and utils" 0)
|
||||||
option(UTILS "Build various utils" ${_plugins_default_})
|
option(UTILS "Build various utils" ${_plugins_default_})
|
||||||
option(DESIGNER_PLUGINS "Build qt designer plugins" ${_plugins_default_})
|
option(DESIGNER_PLUGINS "Build qt designer plugins" ${_plugins_default_})
|
||||||
option(STATIC_LIB OFF)
|
|
||||||
if (CROSSTOOLS)
|
if (CROSSTOOLS)
|
||||||
set(LIB 1)
|
set(LIB 1)
|
||||||
set(QGLVIEW 0)
|
set(QGLVIEW 0)
|
||||||
@@ -144,6 +77,7 @@ endif()
|
|||||||
set(CMAKE_CXX_STANDARD 11)
|
set(CMAKE_CXX_STANDARD 11)
|
||||||
|
|
||||||
set(PIP_LIBRARY pip)
|
set(PIP_LIBRARY pip)
|
||||||
|
set(PIP_FOLDERS "." "core" "containers" "thread" "system" "io_devices" "io_utils" "console" "math" "code" "geo" "resources" "opencl" "crypt" "introspection" "concurrent" "cloud")
|
||||||
set(PIP_INCLUDES)
|
set(PIP_INCLUDES)
|
||||||
|
|
||||||
if(LIB)
|
if(LIB)
|
||||||
@@ -167,6 +101,9 @@ else()
|
|||||||
message(STATUS "Install ${PROJECT_NAME} to local \"bin\", \"lib\" and \"include\"")
|
message(STATUS "Install ${PROJECT_NAME} to local \"bin\", \"lib\" and \"include\"")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
foreach(F ${PIP_FOLDERS})
|
||||||
|
list(APPEND PIP_INCLUDES "${CMAKE_CURRENT_SOURCE_DIR}/pip/lib/main/${F}")
|
||||||
|
endforeach(F)
|
||||||
#message(${PIP_INCLUDES})
|
#message(${PIP_INCLUDES})
|
||||||
if(CMAKE_CROSSCOMPILING OR (DEFINED ANDROID_PLATFORM))
|
if(CMAKE_CROSSCOMPILING OR (DEFINED ANDROID_PLATFORM))
|
||||||
set(PIP_CMG "pip_cmg")
|
set(PIP_CMG "pip_cmg")
|
||||||
@@ -182,7 +119,6 @@ if(WIN32)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(QAD_DIR ${CMAKE_CURRENT_SOURCE_DIR}/qad)
|
set(QAD_DIR ${CMAKE_CURRENT_SOURCE_DIR}/qad)
|
||||||
set(ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR})
|
|
||||||
|
|
||||||
if (CROSSTOOLS)
|
if (CROSSTOOLS)
|
||||||
|
|
||||||
@@ -207,27 +143,20 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
#if(UTILS)
|
if(UTILS)
|
||||||
# message(STATUS "Building with utils")
|
message(STATUS "Building with utils")
|
||||||
#else()
|
else()
|
||||||
# message(STATUS "Building only libraries")
|
message(STATUS "Building only libraries")
|
||||||
#endif()
|
endif()
|
||||||
|
|
||||||
add_subdirectory(pip)
|
add_subdirectory(pip)
|
||||||
foreach(F ${PIP_MAIN_FOLDERS})
|
|
||||||
list(APPEND PIP_INCLUDES "${F}")
|
|
||||||
endforeach(F)
|
|
||||||
add_subdirectory(cd_utils)
|
|
||||||
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/cd_utils" "${CMAKE_CURRENT_BINARY_DIR}/cd_utils")
|
|
||||||
set(_DIRS)
|
set(_DIRS)
|
||||||
if (SomeQtFound)
|
if (SomeQtFound)
|
||||||
#message(STATUS "Building Qt-derived targets for ${QtVersions}")
|
message(STATUS "Building Qt-derived targets for ${QtVersions}")
|
||||||
add_subdirectory(qad)
|
add_subdirectory(qad)
|
||||||
include_directories(${qad_includes})
|
set(_DIRS piqt piqt_utils qcd_utils)
|
||||||
add_subdirectory(piqt)
|
|
||||||
include_directories(${piqt_includes})
|
|
||||||
set(_DIRS)
|
|
||||||
if (Qt5)
|
if (Qt5)
|
||||||
|
list(APPEND _DIRS)
|
||||||
if (QGLVIEW)
|
if (QGLVIEW)
|
||||||
list(APPEND _DIRS qglview)
|
list(APPEND _DIRS qglview)
|
||||||
endif()
|
endif()
|
||||||
@@ -237,62 +166,21 @@ else()
|
|||||||
endif()
|
endif()
|
||||||
foreach(_D ${_DIRS})
|
foreach(_D ${_DIRS})
|
||||||
list(APPEND QT_MULTILIB_LIST ${_D})
|
list(APPEND QT_MULTILIB_LIST ${_D})
|
||||||
add_subdirectory(${_D})
|
|
||||||
endforeach(_D)
|
endforeach(_D)
|
||||||
|
include_directories(piqt)
|
||||||
macro(align_list _list _out)
|
|
||||||
set(_max_len 0)
|
|
||||||
foreach(_m ${_list})
|
|
||||||
string(LENGTH "${_m}" _clen)
|
|
||||||
if (_clen GREATER _max_len)
|
|
||||||
set(_max_len ${_clen})
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
set(${_out})
|
|
||||||
foreach(_m ${_list})
|
|
||||||
set(_am "${_m}")
|
|
||||||
while(TRUE)
|
|
||||||
string(LENGTH "${_am}" _clen)
|
|
||||||
if (_clen GREATER_EQUAL ${_max_len})
|
|
||||||
break()
|
|
||||||
endif()
|
|
||||||
string(APPEND _am " ")
|
|
||||||
endwhile()
|
|
||||||
list(APPEND ${_out} "${_am}")
|
|
||||||
endforeach()
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
macro(print_list _list _name)
|
|
||||||
if (NOT "x${_list}" STREQUAL "x")
|
|
||||||
message("")
|
|
||||||
message(" ${_name}:")
|
|
||||||
#align_list("${_list}" _alist)
|
|
||||||
foreach(_m ${_list})
|
|
||||||
message(" * ${_m}")
|
|
||||||
endforeach()
|
|
||||||
endif()
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
message("----------QAD-----------")
|
|
||||||
message(" Build for ${QtVersions}")
|
|
||||||
message(" QAD Version: ${QAD_VERSION}")
|
|
||||||
message(" QAD Linkage: ${QAD_LIB_TYPE_MSG}")
|
|
||||||
message(" PIQt Version: ${PIQt_VERSION}")
|
|
||||||
message(" PIQt Linkage: ${PIQt_LIB_TYPE_MSG}")
|
|
||||||
print_list("${_qt_libs}" "Libraries")
|
|
||||||
print_list("${_qt_apps}" "Applications")
|
|
||||||
print_list("${_qt_plugs}" "Plugins")
|
|
||||||
message("-----------------------")
|
|
||||||
message("")
|
|
||||||
|
|
||||||
else()
|
else()
|
||||||
message(STATUS "None of Qt found, skip Qt-derived targets")
|
message(STATUS "None of Qt found, skip Qt-derived targets")
|
||||||
endif()
|
endif()
|
||||||
|
include_directories(cd_utils)
|
||||||
|
list(INSERT _DIRS 0 cd_utils)
|
||||||
|
foreach(_D ${_DIRS})
|
||||||
|
add_subdirectory(${_D})
|
||||||
|
endforeach(_D)
|
||||||
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
foreach(PIP_LT ${PIP_MODULES})
|
foreach(PIP_LT ${PIP_LIBS_TARGETS})
|
||||||
if (SomeQtFound)
|
if (SomeQtFound)
|
||||||
qt_install(FILES "${CMAKE_CURRENT_BINARY_DIR}/pip/lib${PIP_LT}.dll" DESTINATION QtBin)
|
qt_install(FILES "${CMAKE_CURRENT_BINARY_DIR}/pip/lib${PIP_LT}.dll" DESTINATION QtBin)
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
@@ -1,107 +1,35 @@
|
|||||||
|
|
||||||
macro(sdk_install _DIR IS_APP _TARGET _H_FILES _QM_FILES)
|
macro(sdk_install _DIR _TARGET _H_FILES _QM_FILES)
|
||||||
#message("QM=${_QM_FILES}")
|
#message("QM=${_QM_FILES}")
|
||||||
if((NOT ${IS_APP}) AND (NOT "${_H_FILES}" STREQUAL ""))
|
|
||||||
if(LIB)
|
if(LIB)
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
|
if(NOT "x${_H_FILES}" STREQUAL "x")
|
||||||
install(FILES ${_H_FILES} DESTINATION ${MINGW_INCLUDE}/${_DIR})
|
install(FILES ${_H_FILES} DESTINATION ${MINGW_INCLUDE}/${_DIR})
|
||||||
else()
|
|
||||||
install(FILES ${_H_FILES} DESTINATION ${CMAKE_INSTALL_PREFIX}/include/${_DIR})
|
|
||||||
endif()
|
endif()
|
||||||
else()
|
|
||||||
install(FILES ${_H_FILES} DESTINATION include/${_DIR})
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
if (NOT "${_TARGET}" STREQUAL "")
|
|
||||||
if(LIB)
|
|
||||||
if(WIN32)
|
|
||||||
if (${IS_APP})
|
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION ${MINGW_BIN})
|
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION QtBin)
|
|
||||||
else()
|
|
||||||
qt_install(TARGETS ${_TARGET} ARCHIVE DESTINATION ${MINGW_LIB})
|
qt_install(TARGETS ${_TARGET} ARCHIVE DESTINATION ${MINGW_LIB})
|
||||||
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION ${MINGW_BIN})
|
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION ${MINGW_BIN})
|
||||||
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION QtBin)
|
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION QtBin)
|
||||||
|
else()
|
||||||
|
if (NOT "x${_H_FILES}" STREQUAL "x")
|
||||||
|
install(FILES ${_H_FILES} DESTINATION ${CMAKE_INSTALL_PREFIX}/include/${_DIR})
|
||||||
endif()
|
endif()
|
||||||
else()
|
|
||||||
if (${IS_APP})
|
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)
|
|
||||||
else()
|
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION ${CMAKE_INSTALL_PREFIX}/lib)
|
qt_install(TARGETS ${_TARGET} DESTINATION ${CMAKE_INSTALL_PREFIX}/lib)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
if(NOT "x${_QM_FILES}" STREQUAL "x")
|
if(NOT "x${_QM_FILES}" STREQUAL "x")
|
||||||
qt_install(LANG ${_QM_FILES} DESTINATION QtLang)
|
qt_install(LANG ${_QM_FILES} DESTINATION QtLang)
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
if(${IS_APP})
|
if(NOT "x${_H_FILES}" STREQUAL "x")
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION bin)
|
install(FILES ${_H_FILES} DESTINATION include/${_DIR})
|
||||||
else()
|
endif()
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION bin)
|
qt_install(TARGETS ${_TARGET} RUNTIME DESTINATION bin)
|
||||||
qt_install(TARGETS ${_TARGET} ARCHIVE DESTINATION lib)
|
qt_install(TARGETS ${_TARGET} ARCHIVE DESTINATION lib)
|
||||||
else()
|
else()
|
||||||
qt_install(TARGETS ${_TARGET} DESTINATION lib)
|
qt_install(TARGETS ${_TARGET} DESTINATION lib)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
if(NOT "x${_QM_FILES}" STREQUAL "x")
|
if(NOT "x${_QM_FILES}" STREQUAL "x")
|
||||||
qt_install(LANG ${_QM_FILES} DESTINATION lang)
|
qt_install(LANG ${_QM_FILES} DESTINATION lang)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
|
|
||||||
macro(copy_to_parent _inc_var)
|
|
||||||
set(QT_MULTILIB_LIST ${QT_MULTILIB_LIST} PARENT_SCOPE)
|
|
||||||
set(_qt_libs ${_qt_libs} PARENT_SCOPE)
|
|
||||||
set(_qt_apps ${_qt_apps} PARENT_SCOPE)
|
|
||||||
set(_qt_plugs ${_qt_plugs} PARENT_SCOPE)
|
|
||||||
if (NOT "x${_inc_var}" STREQUAL "x")
|
|
||||||
set(${_inc_var} ${${_inc_var}} PARENT_SCOPE)
|
|
||||||
endif()
|
|
||||||
if (LIB)
|
|
||||||
set(_ALL_TARGETS ${_ALL_TARGETS} PARENT_SCOPE)
|
|
||||||
endif()
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
|
|
||||||
macro(add_directories_with_include multilib_prefix)
|
|
||||||
set(DIRS)
|
|
||||||
file(GLOB _dl "[^.]*")
|
|
||||||
foreach(_d ${_dl})
|
|
||||||
if(IS_DIRECTORY ${_d})
|
|
||||||
list(APPEND DIRS ${_d})
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
set(inc_var ${multilib_prefix}includes)
|
|
||||||
set(${inc_var})
|
|
||||||
foreach(_d ${DIRS})
|
|
||||||
get_filename_component(_dname "${_d}" NAME)
|
|
||||||
list(APPEND QT_MULTILIB_LIST ${multilib_prefix}${_dname})
|
|
||||||
list(APPEND ${inc_var} "${_d}")
|
|
||||||
list(APPEND ${inc_var} "${CMAKE_CURRENT_BINARY_DIR}/${_dname}")
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
include_directories(${${inc_var}})
|
|
||||||
foreach(_d ${DIRS})
|
|
||||||
add_subdirectory(${_d})
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
copy_to_parent(${inc_var})
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
|
|
||||||
macro(add_directories multilib_prefix)
|
|
||||||
include_directories(${${multilib_prefix}includes})
|
|
||||||
file(GLOB _dl "[^.]*")
|
|
||||||
foreach(_d ${_dl})
|
|
||||||
if(IS_DIRECTORY ${_d})
|
|
||||||
add_subdirectory(${_d})
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
copy_to_parent(${multilib_prefix}includes)
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
|
|||||||
6
android.toolchain.cmake.add
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||||
|
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY FIRST)
|
||||||
|
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE FIRST)
|
||||||
|
set(CMAKE_PREFIX_PATH /soft/android/${ANDROID_ABI})
|
||||||
|
list(APPEND CMAKE_FIND_ROOT_PATH ${CMAKE_PREFIX_PATH}/lib)
|
||||||
|
include_directories(${CMAKE_PREFIX_PATH}/include)
|
||||||
@@ -1,18 +1,67 @@
|
|||||||
cmake_minimum_required(VERSION 3.0)
|
cmake_minimum_required(VERSION 3.0)
|
||||||
project(cd_utils)
|
project(cd_utils)
|
||||||
find_package(MinGW REQUIRED)
|
if (NOT LIBPROJECT)
|
||||||
|
find_package(PIP REQUIRED)
|
||||||
|
option(LIB "System install" 1)
|
||||||
|
option(DEBUG "Build with -g3" 0)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -Wall")
|
||||||
|
if (DEBUG)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g3")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
if (MINGW)
|
||||||
|
find_package(MinGW REQUIRED)
|
||||||
|
endif()
|
||||||
include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR} ${PIP_INCLUDES})
|
include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR} ${PIP_INCLUDES})
|
||||||
|
#file(GLOB HDRS_UTILS "*.h")
|
||||||
|
#file(GLOB CPPS_UTILS "*.cpp")
|
||||||
file(GLOB CPPS_UTILS "cdutils_*.cpp")
|
file(GLOB CPPS_UTILS "cdutils_*.cpp")
|
||||||
file(GLOB HDRS_UTILS "cdutils_*.h")
|
file(GLOB HDRS_UTILS "cdutils_*.h")
|
||||||
add_library(${PROJECT_NAME} SHARED ${CPPS_UTILS} ${HDRS_UTILS})
|
if (DEFINED ENV{QNX_HOST})
|
||||||
|
add_library(${PROJECT_NAME} STATIC ${CPPS_UTILS} ${HDRS_UTILS})
|
||||||
|
else()
|
||||||
|
add_library(${PROJECT_NAME} SHARED ${CPPS_UTILS} ${HDRS_UTILS})
|
||||||
|
endif()
|
||||||
target_link_libraries(${PROJECT_NAME} ${PIP_LIBRARY})
|
target_link_libraries(${PROJECT_NAME} ${PIP_LIBRARY})
|
||||||
generate_export_header(${PROJECT_NAME})
|
|
||||||
list(APPEND HDRS_UTILS "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}_export.h")
|
# # Apple crosscompiling rpath patch
|
||||||
|
# if (APPLE AND CMAKE_CROSSCOMPILING AND CMAKE_MACOSX_RPATH)
|
||||||
|
# foreach(_RP ${CMAKE_INSTALL_RPATH})
|
||||||
|
# add_custom_command(TARGET ${PROJECT_NAME} POST_BUILD
|
||||||
|
# COMMAND "${CMAKE_INSTALL_NAME_TOOL}"
|
||||||
|
# "-add_rpath" "${_RP}"
|
||||||
|
# "$<TARGET_FILE_DIR:${PROJECT_NAME}>/$<TARGET_FILE_NAME:${PROJECT_NAME}>"
|
||||||
|
# COMMENT "Add to ${PROJECT_NAME} rpath \"${_RP}\"")
|
||||||
|
# endforeach()
|
||||||
|
# endif()
|
||||||
|
|
||||||
add_executable(cdutilstest "cdutilstest.cpp" "cdtest.h")
|
add_executable(cdutilstest "cdutilstest.cpp" "cdtest.h")
|
||||||
target_link_libraries(cdutilstest ${PIP_LIBRARY} ${PROJECT_NAME})
|
target_link_libraries(cdutilstest ${PIP_LIBRARY} ${PROJECT_NAME})
|
||||||
message(STATUS "Building ${PROJECT_NAME}")
|
message(STATUS "Building ${PROJECT_NAME}")
|
||||||
|
|
||||||
|
if(NOT LIBPROJECT)
|
||||||
|
if(LIB)
|
||||||
|
if(WIN32)
|
||||||
|
if(MINGW)
|
||||||
|
set(CMAKE_INSTALL_PREFIX ${MINGW_DIR})
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
if (DEFINED ANDROID_PLATFORM)
|
||||||
|
set(CMAKE_INSTALL_PREFIX ${ANDROID_SYSTEM_LIBRARY_PATH}/usr)
|
||||||
|
else()
|
||||||
|
if(CMAKE_CROSSCOMPILING)
|
||||||
|
set(CMAKE_INSTALL_PREFIX ${CMAKE_STAGING_PREFIX})
|
||||||
|
else()
|
||||||
|
set(CMAKE_INSTALL_PREFIX ${INSTALL_PREFIX}/usr/local)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to system \"${CMAKE_INSTALL_PREFIX}\"")
|
||||||
|
else()
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to local \"bin\", \"lib\" and \"include\"")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
if(LIB)
|
if(LIB)
|
||||||
list(APPEND _ALL_TARGETS ${PROJECT_NAME})
|
list(APPEND _ALL_TARGETS ${PROJECT_NAME})
|
||||||
set(_ALL_TARGETS ${_ALL_TARGETS} PARENT_SCOPE)
|
set(_ALL_TARGETS ${_ALL_TARGETS} PARENT_SCOPE)
|
||||||
|
|||||||
@@ -21,13 +21,12 @@
|
|||||||
#define CDUTILS_C_H
|
#define CDUTILS_C_H
|
||||||
|
|
||||||
#include "cdutils_interface.h"
|
#include "cdutils_interface.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT CInterface: public Interface
|
class CInterface: public Interface
|
||||||
{
|
{
|
||||||
PIOBJECT_SUBCLASS(CInterface, Interface)
|
PIOBJECT_SUBCLASS(CInterface, Interface)
|
||||||
public:
|
public:
|
||||||
@@ -41,6 +40,6 @@ public:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
extern CD_UTILS_EXPORT CDUtils::CInterface C;
|
extern CDUtils::CInterface C;
|
||||||
|
|
||||||
#endif // CDUTILS_C_H
|
#endif // CDUTILS_C_H
|
||||||
|
|||||||
@@ -24,7 +24,6 @@
|
|||||||
#include "cdutils_protocol.h"
|
#include "cdutils_protocol.h"
|
||||||
#include "piconnection.h"
|
#include "piconnection.h"
|
||||||
#include "pidatatransfer.h"
|
#include "pidatatransfer.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
@@ -32,7 +31,7 @@ namespace CDUtils {
|
|||||||
class CDCore;
|
class CDCore;
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT __Core_Initializer__ {
|
class __Core_Initializer__ {
|
||||||
public:
|
public:
|
||||||
__Core_Initializer__();
|
__Core_Initializer__();
|
||||||
~__Core_Initializer__();
|
~__Core_Initializer__();
|
||||||
@@ -41,7 +40,7 @@ public:
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT CDCore: public PIObject
|
class CDCore: public PIObject
|
||||||
{
|
{
|
||||||
PIOBJECT(CDUtils::CDCore)
|
PIOBJECT(CDUtils::CDCore)
|
||||||
friend class __Core_Initializer__;
|
friend class __Core_Initializer__;
|
||||||
|
|||||||
@@ -22,7 +22,6 @@
|
|||||||
|
|
||||||
#include "cdutils_types.h"
|
#include "cdutils_types.h"
|
||||||
#include "piobject.h"
|
#include "piobject.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
@@ -30,7 +29,7 @@ namespace CDUtils {
|
|||||||
class CDCore;
|
class CDCore;
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT Interface: public PIObject
|
class Interface: public PIObject
|
||||||
{
|
{
|
||||||
PIOBJECT(CDUtils::Interface)
|
PIOBJECT(CDUtils::Interface)
|
||||||
public:
|
public:
|
||||||
|
|||||||
@@ -21,13 +21,12 @@
|
|||||||
#define CDUTILS_K_H
|
#define CDUTILS_K_H
|
||||||
|
|
||||||
#include "cdutils_interface.h"
|
#include "cdutils_interface.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT KInterface: public Interface
|
class KInterface: public Interface
|
||||||
{
|
{
|
||||||
PIOBJECT_SUBCLASS(KInterface, Interface)
|
PIOBJECT_SUBCLASS(KInterface, Interface)
|
||||||
public:
|
public:
|
||||||
@@ -42,6 +41,6 @@ public:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
extern CD_UTILS_EXPORT CDUtils::KInterface K;
|
extern CDUtils::KInterface K;
|
||||||
|
|
||||||
#endif // CDUTILS_K_H
|
#endif // CDUTILS_K_H
|
||||||
|
|||||||
@@ -21,13 +21,12 @@
|
|||||||
#define CDUTILS_M_H
|
#define CDUTILS_M_H
|
||||||
|
|
||||||
#include "cdutils_interface.h"
|
#include "cdutils_interface.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT MInterface: public Interface
|
class MInterface: public Interface
|
||||||
{
|
{
|
||||||
PIOBJECT_SUBCLASS(MInterface, Interface)
|
PIOBJECT_SUBCLASS(MInterface, Interface)
|
||||||
public:
|
public:
|
||||||
@@ -51,6 +50,6 @@ private:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
extern CD_UTILS_EXPORT CDUtils::MInterface M;
|
extern CDUtils::MInterface M;
|
||||||
|
|
||||||
#endif // CDUTILS_M_H
|
#endif // CDUTILS_M_H
|
||||||
|
|||||||
@@ -20,7 +20,6 @@
|
|||||||
#ifndef CDUTILS_PARSER_H
|
#ifndef CDUTILS_PARSER_H
|
||||||
#define CDUTILS_PARSER_H
|
#define CDUTILS_PARSER_H
|
||||||
|
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
class PIIODevice;
|
class PIIODevice;
|
||||||
|
|
||||||
@@ -30,7 +29,7 @@ class CDSection;
|
|||||||
|
|
||||||
namespace CDParser {
|
namespace CDParser {
|
||||||
|
|
||||||
CD_UTILS_EXPORT CDSection parse(PIIODevice * d, int cdsection_type);
|
CDSection parse(PIIODevice * d, int cdsection_type);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -20,8 +20,7 @@
|
|||||||
#ifndef CDUTILS_PROTOCOL_H
|
#ifndef CDUTILS_PROTOCOL_H
|
||||||
#define CDUTILS_PROTOCOL_H
|
#define CDUTILS_PROTOCOL_H
|
||||||
|
|
||||||
#include "pistring.h"
|
#include "pibytearray.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
|
|
||||||
@@ -49,12 +48,12 @@ namespace CDUtils {
|
|||||||
|
|
||||||
# pragma pack(push,1)
|
# pragma pack(push,1)
|
||||||
|
|
||||||
struct CD_UTILS_EXPORT PacketHeader {
|
struct PacketHeader {
|
||||||
int type; // CDPacketType
|
int type; // CDPacketType
|
||||||
int session_id;
|
int session_id;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct CD_UTILS_EXPORT PacketKDirectChange {
|
struct PacketKDirectChange {
|
||||||
PIDeque<int> path;
|
PIDeque<int> path;
|
||||||
PIString value;
|
PIString value;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -356,9 +356,9 @@ int CDSection::sectionsCount() const {
|
|||||||
|
|
||||||
PIStringList CDSection::index_names() const {
|
PIStringList CDSection::index_names() const {
|
||||||
PIStringList ret;
|
PIStringList ret;
|
||||||
auto i = cd.makeIterator();
|
PIMap<int, CDType>::const_iterator i;
|
||||||
while (i.next())
|
for (i = cd.begin(); i != cd.end(); ++i)
|
||||||
ret << i.value().name();
|
ret << i->second.name();
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -387,14 +387,15 @@ CDType & CDSection::getByName(const PIString & name_) {
|
|||||||
int dv = 0;
|
int dv = 0;
|
||||||
if (isd) dv = np[i].toInt();
|
if (isd) dv = np[i].toInt();
|
||||||
ns = 0;
|
ns = 0;
|
||||||
auto it = cs->s.makeIterator();
|
PIMap<int, CDSection>::iterator it;
|
||||||
while (it.next()) {
|
//piCout << np[i] << isd << dv;
|
||||||
|
for (it = cs->s.begin(); it != cs->s.end(); ++it) {
|
||||||
bool f = false;
|
bool f = false;
|
||||||
if (isd) f = (dv == it.key());
|
if (isd) f = (dv == it.key());
|
||||||
else f = (np[i] == it.value().alias);
|
else f = (np[i] == it.value().alias);
|
||||||
//piCout << "s..." << it.key() << it.value().alias << f;
|
//piCout << "s..." << it.key() << it.value().alias << f;
|
||||||
if (f) {
|
if (f) {
|
||||||
ns = &(it.valueRef());
|
ns = &(it.value());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -402,13 +403,13 @@ CDType & CDSection::getByName(const PIString & name_) {
|
|||||||
if (!ns) return null;
|
if (!ns) return null;
|
||||||
cs = ns;
|
cs = ns;
|
||||||
}
|
}
|
||||||
|
PIMap<int, CDType>::iterator it;
|
||||||
if (np.back().isEmpty()) return null;
|
if (np.back().isEmpty()) return null;
|
||||||
bool isd = np.back()[0].isDigit() || (np.back()[0] == '-');
|
bool isd = np.back()[0].isDigit() || (np.back()[0] == '-');
|
||||||
int dv = 0;
|
int dv = 0;
|
||||||
if (isd) dv = np.back().toInt();
|
if (isd) dv = np.back().toInt();
|
||||||
//piCout << np.back() << isd << dv;
|
//piCout << np.back() << isd << dv;
|
||||||
auto it = cs->cd.makeIterator();
|
for (it = cs->cd.begin(); it != cs->cd.end(); ++it) {
|
||||||
while (it.next()) {
|
|
||||||
bool f = false;
|
bool f = false;
|
||||||
if (isd) f = (dv == it.key());
|
if (isd) f = (dv == it.key());
|
||||||
else f = (np.back() == it.value().name());
|
else f = (np.back() == it.value().name());
|
||||||
@@ -445,9 +446,9 @@ void CDSection::write(PIIODevice * d, const PIString & prefix) {
|
|||||||
d->write(l.toUTF8());
|
d->write(l.toUTF8());
|
||||||
l = "alias = " + alias + " \n";
|
l = "alias = " + alias + " \n";
|
||||||
d->write(l.toUTF8());
|
d->write(l.toUTF8());
|
||||||
auto i = cd.makeIterator();
|
PIMap<int, CDType>::iterator i;
|
||||||
while (i.next()) {
|
for (i = cd.begin(); i != cd.end(); ++i) {
|
||||||
const CDType & ck(i.value());
|
CDType & ck(i.value());
|
||||||
if (ck.cd_type() != cd_type_) continue;
|
if (ck.cd_type() != cd_type_) continue;
|
||||||
switch (cd_type_) {
|
switch (cd_type_) {
|
||||||
case CDType::cdNull: break;
|
case CDType::cdNull: break;
|
||||||
@@ -486,9 +487,9 @@ void CDSection::write(PIIODevice * d, const PIString & prefix) {
|
|||||||
if (!s.isEmpty()) {
|
if (!s.isEmpty()) {
|
||||||
if (prefix.isEmpty()) l = "s";
|
if (prefix.isEmpty()) l = "s";
|
||||||
else l = prefix + ".s";
|
else l = prefix + ".s";
|
||||||
auto j = s.makeIterator();
|
PIMap<int, CDSection>::iterator j;
|
||||||
while (j.next()) {
|
for (j = s.begin(); j != s.end(); ++j) {
|
||||||
j.valueRef().write(d, l + "." + PIString::fromNumber(j.key()));
|
j.value().write(d, l + "." + PIString::fromNumber(j.key()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (prefix.isEmpty()) {
|
if (prefix.isEmpty()) {
|
||||||
|
|||||||
@@ -23,7 +23,6 @@
|
|||||||
#include "pistring.h"
|
#include "pistring.h"
|
||||||
#include "pimap.h"
|
#include "pimap.h"
|
||||||
#include "pivariant.h"
|
#include "pivariant.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
class PIIODevice;
|
class PIIODevice;
|
||||||
class PIEvaluator;
|
class PIEvaluator;
|
||||||
@@ -48,7 +47,7 @@ enum MessageType {
|
|||||||
|
|
||||||
typedef PIFlags<UpdateMode> UpdateModeFlags;
|
typedef PIFlags<UpdateMode> UpdateModeFlags;
|
||||||
|
|
||||||
class CD_UTILS_EXPORT CDType {
|
class CDType {
|
||||||
friend class CDSection;
|
friend class CDSection;
|
||||||
friend class CDCore;
|
friend class CDCore;
|
||||||
friend class Interface;
|
friend class Interface;
|
||||||
@@ -113,7 +112,7 @@ protected:
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT CDSection {
|
class CDSection {
|
||||||
friend class CDCore;
|
friend class CDCore;
|
||||||
friend class Interface;
|
friend class Interface;
|
||||||
friend class XInterface;
|
friend class XInterface;
|
||||||
|
|||||||
@@ -21,13 +21,12 @@
|
|||||||
#define CDUTILS_X_H
|
#define CDUTILS_X_H
|
||||||
|
|
||||||
#include "cdutils_interface.h"
|
#include "cdutils_interface.h"
|
||||||
#include "cd_utils_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
namespace CDUtils {
|
namespace CDUtils {
|
||||||
|
|
||||||
|
|
||||||
class CD_UTILS_EXPORT XInterface: public Interface
|
class XInterface: public Interface
|
||||||
{
|
{
|
||||||
PIOBJECT_SUBCLASS(XInterface, Interface)
|
PIOBJECT_SUBCLASS(XInterface, Interface)
|
||||||
public:
|
public:
|
||||||
@@ -52,6 +51,6 @@ public:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
extern CD_UTILS_EXPORT CDUtils::XInterface X;
|
extern CDUtils::XInterface X;
|
||||||
|
|
||||||
#endif // CDUTILS_X_H
|
#endif // CDUTILS_X_H
|
||||||
|
|||||||
0
cmake_android.sh
Normal file → Executable file
@@ -3,14 +3,9 @@ FROM ${DOCKER_PREFIX}android
|
|||||||
|
|
||||||
ARG LIBS_BUILD_NUMBER=9999
|
ARG LIBS_BUILD_NUMBER=9999
|
||||||
ARG JOBS_COUNT=4
|
ARG JOBS_COUNT=4
|
||||||
ENV PATH=/opt/cmake/bin:$PATH
|
|
||||||
ENV ANDROID_HOME=/usr/lib/android-sdk
|
|
||||||
ENV ANDROID_NDK_HOME=${ANDROID_HOME}/ndk-bundle
|
|
||||||
ENV ANDROID_TOOLCHAIN=${ANDROID_NDK_HOME}/build/cmake/android.toolchain.cmake
|
|
||||||
ENV NDK_PLATFORM="android-21"
|
|
||||||
|
|
||||||
WORKDIR /soft
|
WORKDIR /soft
|
||||||
RUN git clone -b release --single-branch --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
RUN git clone -b release --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
||||||
|
|
||||||
WORKDIR /soft/libs_build_host
|
WORKDIR /soft/libs_build_host
|
||||||
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
||||||
|
|||||||
@@ -3,10 +3,9 @@ FROM ${DOCKER_PREFIX}debian
|
|||||||
|
|
||||||
ARG LIBS_BUILD_NUMBER=9999
|
ARG LIBS_BUILD_NUMBER=9999
|
||||||
ARG JOBS_COUNT=4
|
ARG JOBS_COUNT=4
|
||||||
ENV PATH=/opt/cmake/bin:$PATH
|
|
||||||
|
|
||||||
WORKDIR /soft
|
WORKDIR /soft
|
||||||
RUN git clone -b release --single-branch --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
RUN git clone -b release --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
||||||
|
|
||||||
WORKDIR /soft/libs_build_debian
|
WORKDIR /soft/libs_build_debian
|
||||||
RUN cmake -DICU=0 -DLIB=1 -DQGLENGINE=1 -DQGLVIEW=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
RUN cmake -DICU=0 -DLIB=1 -DQGLENGINE=1 -DQGLVIEW=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
||||||
|
|||||||
@@ -3,10 +3,9 @@ FROM ${DOCKER_PREFIX}osx
|
|||||||
|
|
||||||
ARG LIBS_BUILD_NUMBER=9999
|
ARG LIBS_BUILD_NUMBER=9999
|
||||||
ARG JOBS_COUNT=4
|
ARG JOBS_COUNT=4
|
||||||
ENV PATH=/soft/osxcross/target/bin:/opt/cmake/bin:$PATH
|
|
||||||
|
|
||||||
WORKDIR /soft
|
WORKDIR /soft
|
||||||
RUN git clone -b release --single-branch --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
RUN git clone -b release --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
||||||
|
|
||||||
WORKDIR /soft/libs_build_host
|
WORKDIR /soft/libs_build_host
|
||||||
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
||||||
|
|||||||
@@ -3,10 +3,9 @@ FROM ${DOCKER_PREFIX}pi
|
|||||||
|
|
||||||
ARG LIBS_BUILD_NUMBER=9999
|
ARG LIBS_BUILD_NUMBER=9999
|
||||||
ARG JOBS_COUNT=4
|
ARG JOBS_COUNT=4
|
||||||
ENV PATH=/opt/cmake/bin:$PATH
|
|
||||||
|
|
||||||
WORKDIR /soft
|
WORKDIR /soft
|
||||||
RUN git clone -b release --single-branch --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
RUN git clone -b release --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
||||||
|
|
||||||
WORKDIR /soft/libs_build_host
|
WORKDIR /soft/libs_build_host
|
||||||
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
||||||
|
|||||||
@@ -3,10 +3,9 @@ FROM ${DOCKER_PREFIX}windows
|
|||||||
|
|
||||||
ARG LIBS_BUILD_NUMBER=9999
|
ARG LIBS_BUILD_NUMBER=9999
|
||||||
ARG JOBS_COUNT=4
|
ARG JOBS_COUNT=4
|
||||||
ENV PATH=/opt/cmake/bin:$PATH
|
|
||||||
|
|
||||||
WORKDIR /soft
|
WORKDIR /soft
|
||||||
RUN git clone -b release --single-branch --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
RUN git clone -b release --depth 1 --recursive https://git.shs.tools/SHS/libs.git
|
||||||
|
|
||||||
WORKDIR /soft/libs_build_host
|
WORKDIR /soft/libs_build_host
|
||||||
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
RUN cmake -DICU=0 -DCROSSTOOLS=1 -DBUILD_NUMBER=${LIBS_BUILD_NUMBER} ../libs \
|
||||||
|
|||||||
0
make_libs.sh
Normal file → Executable file
2
pip
@@ -1,21 +1,49 @@
|
|||||||
cmake_minimum_required(VERSION 3.0)
|
cmake_minimum_required(VERSION 3.0)
|
||||||
cmake_policy(SET CMP0017 NEW) # need include() with .cmake
|
project(piqt)
|
||||||
|
if(NOT LIBPROJECT)
|
||||||
macro(piqt_library NAME _MODULES _LIBS)
|
find_package(PIP REQUIRED)
|
||||||
_qt_project(${NAME} FALSE "PIQt" "${_MODULES}" "pip;${_LIBS}" ${ARGN})
|
option(LIB "System install" 0)
|
||||||
_qt_install(${NAME} FALSE "pip" "out_HDR" "out_QM")
|
option(DEBUG "Build with -g3" 0)
|
||||||
endmacro()
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -Wall")
|
||||||
|
if(DEBUG)
|
||||||
macro(piqt_application NAME _MODULES _LIBS)
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g3")
|
||||||
_qt_project(${NAME} TRUE "PIQt" "${_MODULES}" "pip;${_LIBS}" ${ARGN})
|
endif()
|
||||||
_qt_install(${NAME} TRUE "pip" "" "out_QM")
|
endif()
|
||||||
endmacro()
|
find_package(QAD REQUIRED)
|
||||||
|
list(APPEND QT_MULTILIB_LIST ${PROJECT_NAME})
|
||||||
|
set(QT_MULTILIB_LIST ${QT_MULTILIB_LIST} PARENT_SCOPE)
|
||||||
include_directories(${PIP_INCLUDES})
|
include_directories(${PIP_INCLUDES} ${QAD_INCLUDES})
|
||||||
add_subdirectory(libs)
|
file(GLOB SRC "*.h" "*.cpp" "*.ui" "*.qrc" "lang/*.ts")
|
||||||
if (UTILS)
|
find_qt(${QtVersions} Core Gui Positioning)
|
||||||
add_subdirectory(utils)
|
qt_wrap(${SRC} HDRS out_HDR CPPS out_CPP QMS out_QM)
|
||||||
|
qt_add_library(${PROJECT_NAME} SHARED out_CPP)
|
||||||
|
qt_target_link_libraries(${PROJECT_NAME} pip qad_utils qad_widgets)
|
||||||
|
message(STATUS "Building ${PROJECT_NAME}")
|
||||||
|
if(LIBPROJECT)
|
||||||
|
sdk_install("pip" "${PROJECT_NAME}" "${out_HDR}" "${out_QM}")
|
||||||
|
else()
|
||||||
|
if(LIB)
|
||||||
|
if(WIN32)
|
||||||
|
install(FILES ${out_HDR} DESTINATION ${MINGW_INCLUDE}/pip)
|
||||||
|
if(NOT "x${out_QM}" STREQUAL "x")
|
||||||
|
qt_install(FILES ${out_QM} DESTINATION QtLang)
|
||||||
|
endif()
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} ARCHIVE DESTINATION ${MINGW_LIB})
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION ${MINGW_BIN})
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION QtBin)
|
||||||
|
else()
|
||||||
|
install(FILES ${out_HDR} DESTINATION ${CMAKE_INSTALL_PREFIX}/include/pip)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_PREFIX}/lib)
|
||||||
|
endif()
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to system \"${CMAKE_INSTALL_PREFIX}\"")
|
||||||
|
else()
|
||||||
|
if(WIN32)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION bin)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} ARCHIVE DESTINATION lib)
|
||||||
|
else()
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION lib)
|
||||||
|
endif()
|
||||||
|
install(FILES ${out_HDR} DESTINATION include/pip)
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to local \"bin\", \"lib\" and \"include\"")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
copy_to_parent(piqt_includes)
|
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
add_directories_with_include("piqt_")
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
piqt_library(piqt "Gui;Positioning" "qad_utils;qad_widgets")
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
piqt_library(qcd_utils "Gui" "pip;qad_utils;qad_widgets;qad_graphic;cd_utils;piqt")
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
include(PIPMacros)
|
|
||||||
pip_code_model(CCM "${ROOT_DIR}/pip/libs/main/io_devices/piiodevice.h" "${ROOT_DIR}/pip/libs/main/io_utils/pipacketextractor.h" OPTIONS "-DPIP_EXPORT" "-Es")
|
|
||||||
piqt_library(piqt_utils "Gui" "qad_utils;qad_widgets;qad_blockview;piqt" ${CCM})
|
|
||||||
|
|
||||||
foreach(_v ${_QT_VERSIONS_})
|
|
||||||
if (LOCAL_FOUND${_v})
|
|
||||||
add_dependencies(piqt_utils${_v} pip_cmg)
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
@@ -106,7 +106,7 @@ const QAD::IODevice PI2QADIODevice(const PIVariantTypes::IODevice & v) {
|
|||||||
|
|
||||||
|
|
||||||
const QAD::File PI2QADFile(const PIVariantTypes::File & v) {
|
const QAD::File PI2QADFile(const PIVariantTypes::File & v) {
|
||||||
return QAD::File(PI2QString(v.file), PI2QString(v.filter), v.is_abs, v.is_save);
|
return QAD::File(PI2QString(v.file), PI2QString(v.filter), v.is_abs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -116,7 +116,7 @@ const QAD::Dir PI2QADDir(const PIVariantTypes::Dir & v) {
|
|||||||
|
|
||||||
|
|
||||||
const PIVariantTypes::File QAD2PIFile(const QAD::File & v) {
|
const PIVariantTypes::File QAD2PIFile(const QAD::File & v) {
|
||||||
return PIVariantTypes::File(Q2PIString(v.file), Q2PIString(v.filter), v.is_abs, v.is_save);
|
return PIVariantTypes::File(Q2PIString(v.file), Q2PIString(v.filter), v.is_abs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -29,14 +29,13 @@
|
|||||||
#if QT_VERSION >= 0x050200
|
#if QT_VERSION >= 0x050200
|
||||||
# include "pigeoposition.h"
|
# include "pigeoposition.h"
|
||||||
#endif
|
#endif
|
||||||
#include "piqt_export.h"
|
|
||||||
|
|
||||||
|
|
||||||
class QGeoCoordinate;
|
class QGeoCoordinate;
|
||||||
|
|
||||||
|
|
||||||
PIQT_EXPORT const QVariant PI2QVariant(const PIVariant & v);
|
const QVariant PI2QVariant(const PIVariant & v);
|
||||||
PIQT_EXPORT const PIVariant Q2PIVariant(const QVariant & v);
|
const PIVariant Q2PIVariant(const QVariant & v);
|
||||||
|
|
||||||
//inline const QString PI2QString(const PIString & v) {return QString::fromLocal8Bit(v.data());}
|
//inline const QString PI2QString(const PIString & v) {return QString::fromLocal8Bit(v.data());}
|
||||||
inline const QString PI2QString(const PIString & v) {return QString::fromUtf8(v.dataUTF8());}
|
inline const QString PI2QString(const PIString & v) {return QString::fromUtf8(v.dataUTF8());}
|
||||||
@@ -125,20 +124,20 @@ inline PropertyStorage PI2QPropertyStorage(const PIPropertyStorage & props) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
PIQT_EXPORT const QAD::Enum PI2QADEnum(const PIVariantTypes::Enum & el);
|
const QAD::Enum PI2QADEnum(const PIVariantTypes::Enum & el);
|
||||||
PIQT_EXPORT const QAD::File PI2QADFile(const PIVariantTypes::File & v);
|
const QAD::File PI2QADFile(const PIVariantTypes::File & v);
|
||||||
PIQT_EXPORT const QAD::Dir PI2QADDir(const PIVariantTypes::Dir & v);
|
const QAD::Dir PI2QADDir(const PIVariantTypes::Dir & v);
|
||||||
PIQT_EXPORT const QAD::IODevice PI2QADIODevice(const PIVariantTypes::IODevice & v);
|
const QAD::IODevice PI2QADIODevice(const PIVariantTypes::IODevice & v);
|
||||||
PIQT_EXPORT const PIVariantTypes::Enum QAD2PIEnum(const QAD::Enum & el);
|
const PIVariantTypes::Enum QAD2PIEnum(const QAD::Enum & el);
|
||||||
PIQT_EXPORT const PIVariantTypes::File QAD2PIFile(const QAD::File & v);
|
const PIVariantTypes::File QAD2PIFile(const QAD::File & v);
|
||||||
PIQT_EXPORT const PIVariantTypes::Dir QAD2PIDir(const QAD::Dir & v);
|
const PIVariantTypes::Dir QAD2PIDir(const QAD::Dir & v);
|
||||||
PIQT_EXPORT const PIVariantTypes::IODevice QAD2PIIODevice(const QAD::IODevice & v);
|
const PIVariantTypes::IODevice QAD2PIIODevice(const QAD::IODevice & v);
|
||||||
|
|
||||||
//inline const PIVariant QString2PIVariant(const QString & v) {return PIVariant::readFromString(QString2PIString(v));}
|
//inline const PIVariant QString2PIVariant(const QString & v) {return PIVariant::readFromString(QString2PIString(v));}
|
||||||
|
|
||||||
#if QT_VERSION >= 0x050200
|
#if QT_VERSION >= 0x050200
|
||||||
PIQT_EXPORT const QGeoCoordinate PI2QGeoPosition(const PIGeoPosition & v);
|
const QGeoCoordinate PI2QGeoPosition(const PIGeoPosition & v);
|
||||||
PIQT_EXPORT const PIGeoPosition Q2PIGeoPosition(const QGeoCoordinate & v);
|
const PIGeoPosition Q2PIGeoPosition(const QGeoCoordinate & v);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
template <typename From>
|
template <typename From>
|
||||||
@@ -1 +0,0 @@
|
|||||||
add_directories("piqt_")
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
project(cd_pult)
|
|
||||||
if(APPLE)
|
|
||||||
set(APP_ICON "")
|
|
||||||
elseif(WIN32)
|
|
||||||
set(APP_ICON "")
|
|
||||||
else()
|
|
||||||
set(APP_ICON "")
|
|
||||||
endif()
|
|
||||||
set(APP_INFO "CD Pult")
|
|
||||||
piqt_application(${PROJECT_NAME} "Gui;Widgets" "qad_utils;qad_widgets;qad_graphic;qad_application;qcd_utils;piqt_utils")
|
|
||||||
if (Qt5_FOUND)
|
|
||||||
import_version(${PROJ_NAME}5 ${PROJECT_NAME})
|
|
||||||
deploy_target(${PROJECT_NAME}5 DEPLOY_DIR ${CMAKE_CURRENT_BINARY_DIR} DESTINATION ${ROOT_DIR}/release)
|
|
||||||
endif()
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
<RCC>
|
|
||||||
<qresource prefix="/">
|
|
||||||
<file>../../../qad/icons/dialog-information.png</file>
|
|
||||||
<file>../../../qad/icons/dialog-cancel.png</file>
|
|
||||||
<file>../../../qad/icons/dialog-ok-apply.png</file>
|
|
||||||
<file>../../../qad/icons/document-revert.png</file>
|
|
||||||
<file>../../../qad/icons/view-refresh.png</file>
|
|
||||||
<file>../../../qad/icons/format-stroke-color.png</file>
|
|
||||||
<file>icons/db-export.png</file>
|
|
||||||
<file>icons/db-import.png</file>
|
|
||||||
<file>icons/timer.png</file>
|
|
||||||
<file>icons/flame.png</file>
|
|
||||||
<file>icons/Apps-accessories-calculator-icon.png</file>
|
|
||||||
<file>icons/accessories-text-editor.png</file>
|
|
||||||
</qresource>
|
|
||||||
</RCC>
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
project(piconnedit)
|
|
||||||
if(APPLE)
|
|
||||||
set(APP_ICON "")
|
|
||||||
elseif(WIN32)
|
|
||||||
set(APP_ICON "")
|
|
||||||
else()
|
|
||||||
set(APP_ICON "")
|
|
||||||
endif()
|
|
||||||
set(APP_INFO "PIConnection GUI editor")
|
|
||||||
piqt_application(${PROJECT_NAME} "Gui;Widgets" "qad_utils;qad_widgets;qad_blockview;piqt_utils")
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
project(pidumper)
|
|
||||||
if(APPLE)
|
|
||||||
set(APP_ICON "")
|
|
||||||
elseif(WIN32)
|
|
||||||
set(APP_ICON "")
|
|
||||||
else()
|
|
||||||
set(APP_ICON "")
|
|
||||||
endif()
|
|
||||||
set(APP_INFO "PIConnection GUI editor")
|
|
||||||
piqt_application(${PROJECT_NAME} "Gui;Widgets" "qad_utils;qad_widgets;piqt_utils")
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
project(piintrospector)
|
|
||||||
if(APPLE)
|
|
||||||
set(APP_ICON "")
|
|
||||||
elseif(WIN32)
|
|
||||||
set(APP_ICON "")
|
|
||||||
else()
|
|
||||||
set(APP_ICON "")
|
|
||||||
endif()
|
|
||||||
set(APP_INFO "PIConnection GUI editor")
|
|
||||||
include(PIPMacros)
|
|
||||||
set(PII_ROOT "${ROOT_DIR}/pip/libs/main/introspection")
|
|
||||||
pip_code_model(CCM "${PII_ROOT}/piintrospection_server_p.h" "${PII_ROOT}/piintrospection_threads_p.h" OPTIONS "-DPIP_EXPORT" "-Es")
|
|
||||||
piqt_application(${PROJECT_NAME} "Gui;Widgets" "qad_utils;qad_widgets;qad_application;piqt_utils" ${CCM})
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
project(qpicalc)
|
|
||||||
if(APPLE)
|
|
||||||
set(APP_ICON "")
|
|
||||||
elseif(WIN32)
|
|
||||||
set(APP_ICON "icons/qpicalculator.ico")
|
|
||||||
else()
|
|
||||||
set(APP_ICON "icons/qpicalculator.png")
|
|
||||||
endif()
|
|
||||||
set(APP_INFO "Small calculator ang grapher")
|
|
||||||
qad_application(${PROJECT_NAME} "Gui;Widgets" "qad_utils;qad_widgets;qad_graphic;pip;piqt")
|
|
||||||
if (Qt5_FOUND)
|
|
||||||
import_version(${PROJ_NAME}5 ${PROJECT_NAME})
|
|
||||||
deploy_target(${PROJECT_NAME}5 DEPLOY_DIR ${CMAKE_CURRENT_BINARY_DIR} DESTINATION ${ROOT_DIR}/release)
|
|
||||||
endif()
|
|
||||||
|
Before Width: | Height: | Size: 158 KiB |
|
Before Width: | Height: | Size: 23 KiB |
@@ -1,5 +0,0 @@
|
|||||||
<RCC>
|
|
||||||
<qresource prefix="/">
|
|
||||||
<file>icons/qpicalculator.png</file>
|
|
||||||
</qresource>
|
|
||||||
</RCC>
|
|
||||||
73
piqt_utils/CMakeLists.txt
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
cmake_minimum_required(VERSION 3.0)
|
||||||
|
project(piqt_utils)
|
||||||
|
set(PIQT_UTILS_UTILS 1)
|
||||||
|
if(LIBPROJECT)
|
||||||
|
include(PIPMacros)
|
||||||
|
include(SDKMacros)
|
||||||
|
set(PIQT_UTILS_UTILS ${UTILS})
|
||||||
|
else()
|
||||||
|
find_package(PIP REQUIRED)
|
||||||
|
option(LIB "System install" 0)
|
||||||
|
option(DEBUG "Build with -g3" 0)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -Wall")
|
||||||
|
if(DEBUG)
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g3")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
set(LIBTYPE SHARED)
|
||||||
|
if(DEFINED ENV{QNX_HOST})
|
||||||
|
set(LIBTYPE STATIC)
|
||||||
|
endif()
|
||||||
|
find_package(QAD REQUIRED)
|
||||||
|
list(APPEND QT_MULTILIB_LIST ${PROJECT_NAME})
|
||||||
|
set(QT_MULTILIB_LIST ${QT_MULTILIB_LIST} PARENT_SCOPE)
|
||||||
|
include_directories(${PIP_INCLUDES} ${QAD_INCLUDES})
|
||||||
|
file(GLOB SRC "*.h" "*.cpp" "*.ui" "*.qrc" "lang/*.ts")
|
||||||
|
pip_code_model(CCM "../pip/lib/main/io_devices/piiodevice.h" "../pip/lib/main/io_utils/pipacketextractor.h" OPTIONS "-DPIP_EXPORT" "-Es")
|
||||||
|
find_qt(${QtVersions} Core Gui)
|
||||||
|
qt_wrap(${SRC} HDRS out_HDR CPPS out_CPP QMS out_QM)
|
||||||
|
qt_add_library(${PROJECT_NAME} ${LIBTYPE} out_CPP CCM)
|
||||||
|
qt_target_link_libraries(${PROJECT_NAME} pip qad_utils qad_widgets qad_blockview piqt)
|
||||||
|
message(STATUS "Building ${PROJECT_NAME}")
|
||||||
|
|
||||||
|
if (LIBPROJECT)
|
||||||
|
foreach(_v ${_QT_VERSIONS_})
|
||||||
|
if (LOCAL_FOUND${_v})
|
||||||
|
add_dependencies(piqt_utils${_v} pip_cmg)
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT DEFINED ENV{QNX_HOST})
|
||||||
|
if (PIQT_UTILS_UTILS)
|
||||||
|
add_subdirectory(piconnedit)
|
||||||
|
add_subdirectory(pidumper)
|
||||||
|
add_subdirectory(piintrospector)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(LIBPROJECT)
|
||||||
|
sdk_install("pip" "${PROJECT_NAME}" "${out_HDR}" "${out_QM}")
|
||||||
|
else()
|
||||||
|
if(LIB)
|
||||||
|
if(WIN32)
|
||||||
|
install(FILES ${out_HDR} DESTINATION ${MINGW_INCLUDE}/pip)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} ARCHIVE DESTINATION ${MINGW_LIB})
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION ${MINGW_BIN})
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION QtBin)
|
||||||
|
else()
|
||||||
|
install(FILES ${out_HDR} DESTINATION ${CMAKE_INSTALL_PREFIX}/include/pip)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION ${CMAKE_INSTALL_PREFIX}/lib)
|
||||||
|
endif()
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to system \"${CMAKE_INSTALL_PREFIX}\"")
|
||||||
|
else()
|
||||||
|
if(WIN32)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION bin)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} ARCHIVE DESTINATION lib)
|
||||||
|
else()
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION lib)
|
||||||
|
endif()
|
||||||
|
install(FILES ${out_HDR} DESTINATION include/pip)
|
||||||
|
message(STATUS "Install ${PROJECT_NAME} to local \"bin\", \"lib\" and \"include\"")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
165
piqt_utils/LICENSE.txt
Normal file
@@ -0,0 +1,165 @@
|
|||||||
|
GNU LESSER GENERAL PUBLIC LICENSE
|
||||||
|
Version 3, 29 June 2007
|
||||||
|
|
||||||
|
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
|
||||||
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
|
||||||
|
This version of the GNU Lesser General Public License incorporates
|
||||||
|
the terms and conditions of version 3 of the GNU General Public
|
||||||
|
License, supplemented by the additional permissions listed below.
|
||||||
|
|
||||||
|
0. Additional Definitions.
|
||||||
|
|
||||||
|
As used herein, "this License" refers to version 3 of the GNU Lesser
|
||||||
|
General Public License, and the "GNU GPL" refers to version 3 of the GNU
|
||||||
|
General Public License.
|
||||||
|
|
||||||
|
"The Library" refers to a covered work governed by this License,
|
||||||
|
other than an Application or a Combined Work as defined below.
|
||||||
|
|
||||||
|
An "Application" is any work that makes use of an interface provided
|
||||||
|
by the Library, but which is not otherwise based on the Library.
|
||||||
|
Defining a subclass of a class defined by the Library is deemed a mode
|
||||||
|
of using an interface provided by the Library.
|
||||||
|
|
||||||
|
A "Combined Work" is a work produced by combining or linking an
|
||||||
|
Application with the Library. The particular version of the Library
|
||||||
|
with which the Combined Work was made is also called the "Linked
|
||||||
|
Version".
|
||||||
|
|
||||||
|
The "Minimal Corresponding Source" for a Combined Work means the
|
||||||
|
Corresponding Source for the Combined Work, excluding any source code
|
||||||
|
for portions of the Combined Work that, considered in isolation, are
|
||||||
|
based on the Application, and not on the Linked Version.
|
||||||
|
|
||||||
|
The "Corresponding Application Code" for a Combined Work means the
|
||||||
|
object code and/or source code for the Application, including any data
|
||||||
|
and utility programs needed for reproducing the Combined Work from the
|
||||||
|
Application, but excluding the System Libraries of the Combined Work.
|
||||||
|
|
||||||
|
1. Exception to Section 3 of the GNU GPL.
|
||||||
|
|
||||||
|
You may convey a covered work under sections 3 and 4 of this License
|
||||||
|
without being bound by section 3 of the GNU GPL.
|
||||||
|
|
||||||
|
2. Conveying Modified Versions.
|
||||||
|
|
||||||
|
If you modify a copy of the Library, and, in your modifications, a
|
||||||
|
facility refers to a function or data to be supplied by an Application
|
||||||
|
that uses the facility (other than as an argument passed when the
|
||||||
|
facility is invoked), then you may convey a copy of the modified
|
||||||
|
version:
|
||||||
|
|
||||||
|
a) under this License, provided that you make a good faith effort to
|
||||||
|
ensure that, in the event an Application does not supply the
|
||||||
|
function or data, the facility still operates, and performs
|
||||||
|
whatever part of its purpose remains meaningful, or
|
||||||
|
|
||||||
|
b) under the GNU GPL, with none of the additional permissions of
|
||||||
|
this License applicable to that copy.
|
||||||
|
|
||||||
|
3. Object Code Incorporating Material from Library Header Files.
|
||||||
|
|
||||||
|
The object code form of an Application may incorporate material from
|
||||||
|
a header file that is part of the Library. You may convey such object
|
||||||
|
code under terms of your choice, provided that, if the incorporated
|
||||||
|
material is not limited to numerical parameters, data structure
|
||||||
|
layouts and accessors, or small macros, inline functions and templates
|
||||||
|
(ten or fewer lines in length), you do both of the following:
|
||||||
|
|
||||||
|
a) Give prominent notice with each copy of the object code that the
|
||||||
|
Library is used in it and that the Library and its use are
|
||||||
|
covered by this License.
|
||||||
|
|
||||||
|
b) Accompany the object code with a copy of the GNU GPL and this license
|
||||||
|
document.
|
||||||
|
|
||||||
|
4. Combined Works.
|
||||||
|
|
||||||
|
You may convey a Combined Work under terms of your choice that,
|
||||||
|
taken together, effectively do not restrict modification of the
|
||||||
|
portions of the Library contained in the Combined Work and reverse
|
||||||
|
engineering for debugging such modifications, if you also do each of
|
||||||
|
the following:
|
||||||
|
|
||||||
|
a) Give prominent notice with each copy of the Combined Work that
|
||||||
|
the Library is used in it and that the Library and its use are
|
||||||
|
covered by this License.
|
||||||
|
|
||||||
|
b) Accompany the Combined Work with a copy of the GNU GPL and this license
|
||||||
|
document.
|
||||||
|
|
||||||
|
c) For a Combined Work that displays copyright notices during
|
||||||
|
execution, include the copyright notice for the Library among
|
||||||
|
these notices, as well as a reference directing the user to the
|
||||||
|
copies of the GNU GPL and this license document.
|
||||||
|
|
||||||
|
d) Do one of the following:
|
||||||
|
|
||||||
|
0) Convey the Minimal Corresponding Source under the terms of this
|
||||||
|
License, and the Corresponding Application Code in a form
|
||||||
|
suitable for, and under terms that permit, the user to
|
||||||
|
recombine or relink the Application with a modified version of
|
||||||
|
the Linked Version to produce a modified Combined Work, in the
|
||||||
|
manner specified by section 6 of the GNU GPL for conveying
|
||||||
|
Corresponding Source.
|
||||||
|
|
||||||
|
1) Use a suitable shared library mechanism for linking with the
|
||||||
|
Library. A suitable mechanism is one that (a) uses at run time
|
||||||
|
a copy of the Library already present on the user's computer
|
||||||
|
system, and (b) will operate properly with a modified version
|
||||||
|
of the Library that is interface-compatible with the Linked
|
||||||
|
Version.
|
||||||
|
|
||||||
|
e) Provide Installation Information, but only if you would otherwise
|
||||||
|
be required to provide such information under section 6 of the
|
||||||
|
GNU GPL, and only to the extent that such information is
|
||||||
|
necessary to install and execute a modified version of the
|
||||||
|
Combined Work produced by recombining or relinking the
|
||||||
|
Application with a modified version of the Linked Version. (If
|
||||||
|
you use option 4d0, the Installation Information must accompany
|
||||||
|
the Minimal Corresponding Source and Corresponding Application
|
||||||
|
Code. If you use option 4d1, you must provide the Installation
|
||||||
|
Information in the manner specified by section 6 of the GNU GPL
|
||||||
|
for conveying Corresponding Source.)
|
||||||
|
|
||||||
|
5. Combined Libraries.
|
||||||
|
|
||||||
|
You may place library facilities that are a work based on the
|
||||||
|
Library side by side in a single library together with other library
|
||||||
|
facilities that are not Applications and are not covered by this
|
||||||
|
License, and convey such a combined library under terms of your
|
||||||
|
choice, if you do both of the following:
|
||||||
|
|
||||||
|
a) Accompany the combined library with a copy of the same work based
|
||||||
|
on the Library, uncombined with any other library facilities,
|
||||||
|
conveyed under the terms of this License.
|
||||||
|
|
||||||
|
b) Give prominent notice with the combined library that part of it
|
||||||
|
is a work based on the Library, and explaining where to find the
|
||||||
|
accompanying uncombined form of the same work.
|
||||||
|
|
||||||
|
6. Revised Versions of the GNU Lesser General Public License.
|
||||||
|
|
||||||
|
The Free Software Foundation may publish revised and/or new versions
|
||||||
|
of the GNU Lesser General Public License from time to time. Such new
|
||||||
|
versions will be similar in spirit to the present version, but may
|
||||||
|
differ in detail to address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the
|
||||||
|
Library as you received it specifies that a certain numbered version
|
||||||
|
of the GNU Lesser General Public License "or any later version"
|
||||||
|
applies to it, you have the option of following the terms and
|
||||||
|
conditions either of that published version or of any later version
|
||||||
|
published by the Free Software Foundation. If the Library as you
|
||||||
|
received it does not specify a version number of the GNU Lesser
|
||||||
|
General Public License, you may choose any version of the GNU Lesser
|
||||||
|
General Public License ever published by the Free Software Foundation.
|
||||||
|
|
||||||
|
If the Library as you received it specifies that a proxy can decide
|
||||||
|
whether future versions of the GNU Lesser General Public License shall
|
||||||
|
apply, that proxy's public statement of acceptance of any version is
|
||||||
|
permanent authorization for you to choose that version for the
|
||||||
|
Library.
|
||||||
23
piqt_utils/piconnedit/CMakeLists.txt
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
project(piconnedit)
|
||||||
|
file(GLOB SRC "*.h" "*.cpp" "*.ui" "*.qrc" "lang/*.ts")
|
||||||
|
find_qt(${QtVersions} Core Gui)
|
||||||
|
qt_wrap(${SRC} HDRS out_HDR CPPS out_CPP QMS out_QM)
|
||||||
|
qt_add_executable(${PROJECT_NAME} WIN32 out_CPP)
|
||||||
|
qt_target_link_libraries(${PROJECT_NAME} pip qad_utils qad_widgets piqt_utils)
|
||||||
|
qt_target_include_directories(${PROJECT_NAME} PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/../")
|
||||||
|
message(STATUS "Building ${PROJECT_NAME}")
|
||||||
|
if(LIB)
|
||||||
|
if(WIN32)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION ${MINGW_BIN})
|
||||||
|
else()
|
||||||
|
if (DEFINED ANDROID_PLATFORM)
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION ${ANDROID_SYSTEM_LIBRARY_PATH}/usr/bin)
|
||||||
|
else()
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION /usr/local/bin)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
#message(STATUS "Install ${PROJECT_NAME} to system \"${CMAKE_INSTALL_PREFIX}\"")
|
||||||
|
else()
|
||||||
|
qt_install(TARGETS ${PROJECT_NAME} DESTINATION bin)
|
||||||
|
#message(STATUS "Install ${PROJECT_NAME} to local \"bin\"")
|
||||||
|
endif()
|
||||||
|
Before Width: | Height: | Size: 9.4 KiB After Width: | Height: | Size: 9.4 KiB |
BIN
piqt_utils/piconnedit/icons/DALI-designer.png
Normal file
|
After Width: | Height: | Size: 7.7 KiB |
BIN
piqt_utils/piconnedit/icons/alpha.png
Normal file
|
After Width: | Height: | Size: 158 B |
BIN
piqt_utils/piconnedit/icons/application-exit.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
piqt_utils/piconnedit/icons/applications-engineering.png
Normal file
|
After Width: | Height: | Size: 1.0 KiB |
BIN
piqt_utils/piconnedit/icons/archive-extract.png
Normal file
|
After Width: | Height: | Size: 626 B |
BIN
piqt_utils/piconnedit/icons/archive-insert-directory.png
Normal file
|
After Width: | Height: | Size: 588 B |
BIN
piqt_utils/piconnedit/icons/archive-insert.png
Normal file
|
After Width: | Height: | Size: 433 B |
BIN
piqt_utils/piconnedit/icons/arrow-down.png
Normal file
|
After Width: | Height: | Size: 525 B |
BIN
piqt_utils/piconnedit/icons/arrow-up.png
Normal file
|
After Width: | Height: | Size: 484 B |
BIN
piqt_utils/piconnedit/icons/axis_x.png
Normal file
|
After Width: | Height: | Size: 235 B |
BIN
piqt_utils/piconnedit/icons/axis_y.png
Normal file
|
After Width: | Height: | Size: 259 B |
BIN
piqt_utils/piconnedit/icons/case-sensitive.png
Normal file
|
After Width: | Height: | Size: 326 B |
BIN
piqt_utils/piconnedit/icons/checkbox-unchecked.png
Normal file
|
After Width: | Height: | Size: 419 B |
BIN
piqt_utils/piconnedit/icons/checkbox.png
Normal file
|
After Width: | Height: | Size: 654 B |
BIN
piqt_utils/piconnedit/icons/clients.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
piqt_utils/piconnedit/icons/close.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
piqt_utils/piconnedit/icons/code-error.png
Normal file
|
After Width: | Height: | Size: 722 B |
BIN
piqt_utils/piconnedit/icons/code-function.png
Normal file
|
After Width: | Height: | Size: 449 B |
BIN
piqt_utils/piconnedit/icons/code-keyword.png
Normal file
|
After Width: | Height: | Size: 342 B |
BIN
piqt_utils/piconnedit/icons/code-parents.png
Normal file
|
After Width: | Height: | Size: 641 B |
BIN
piqt_utils/piconnedit/icons/code-property.png
Normal file
|
After Width: | Height: | Size: 540 B |
BIN
piqt_utils/piconnedit/icons/code-signal.png
Normal file
|
After Width: | Height: | Size: 726 B |
BIN
piqt_utils/piconnedit/icons/code-struct.png
Normal file
|
After Width: | Height: | Size: 676 B |
BIN
piqt_utils/piconnedit/icons/code-union.png
Normal file
|
After Width: | Height: | Size: 731 B |
BIN
piqt_utils/piconnedit/icons/code-variable.png
Normal file
|
After Width: | Height: | Size: 328 B |
BIN
piqt_utils/piconnedit/icons/code-word.png
Normal file
|
After Width: | Height: | Size: 543 B |
BIN
piqt_utils/piconnedit/icons/configure-.png
Normal file
|
After Width: | Height: | Size: 1.3 KiB |
BIN
piqt_utils/piconnedit/icons/configure.png
Normal file
|
After Width: | Height: | Size: 717 B |
BIN
piqt_utils/piconnedit/icons/database.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
BIN
piqt_utils/piconnedit/icons/debug-run.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
piqt_utils/piconnedit/icons/designer-qt4.png
Normal file
|
After Width: | Height: | Size: 1.3 KiB |
BIN
piqt_utils/piconnedit/icons/dialog-close.png
Normal file
|
After Width: | Height: | Size: 813 B |
BIN
piqt_utils/piconnedit/icons/dialog-ok-apply.png
Normal file
|
After Width: | Height: | Size: 1.9 KiB |
BIN
piqt_utils/piconnedit/icons/dialog-warning.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
piqt_utils/piconnedit/icons/disabled.png
Normal file
|
After Width: | Height: | Size: 5.6 KiB |
BIN
piqt_utils/piconnedit/icons/distribute-horizontal-margin.png
Normal file
|
After Width: | Height: | Size: 539 B |
BIN
piqt_utils/piconnedit/icons/document-edit.png
Normal file
|
After Width: | Height: | Size: 726 B |
BIN
piqt_utils/piconnedit/icons/document-new.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
piqt_utils/piconnedit/icons/document-open.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
BIN
piqt_utils/piconnedit/icons/document-print.png
Normal file
|
After Width: | Height: | Size: 880 B |
BIN
piqt_utils/piconnedit/icons/document-save-.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
piqt_utils/piconnedit/icons/document-save-all.png
Normal file
|
After Width: | Height: | Size: 921 B |
BIN
piqt_utils/piconnedit/icons/document-save-as.png
Normal file
|
After Width: | Height: | Size: 2.1 KiB |
BIN
piqt_utils/piconnedit/icons/document-save.png
Normal file
|
After Width: | Height: | Size: 563 B |
BIN
piqt_utils/piconnedit/icons/edit-clear-.png
Normal file
|
After Width: | Height: | Size: 3.8 KiB |
BIN
piqt_utils/piconnedit/icons/edit-clear-locationbar-rtl.png
Normal file
|
After Width: | Height: | Size: 644 B |
BIN
piqt_utils/piconnedit/icons/edit-clear.png
Normal file
|
After Width: | Height: | Size: 2.0 KiB |
BIN
piqt_utils/piconnedit/icons/edit-copy.png
Normal file
|
After Width: | Height: | Size: 828 B |
BIN
piqt_utils/piconnedit/icons/edit-cut.png
Normal file
|
After Width: | Height: | Size: 892 B |
BIN
piqt_utils/piconnedit/icons/edit-delete.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
BIN
piqt_utils/piconnedit/icons/edit-find-.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
BIN
piqt_utils/piconnedit/icons/edit-find.png
Normal file
|
After Width: | Height: | Size: 634 B |
BIN
piqt_utils/piconnedit/icons/edit-guides.png
Normal file
|
After Width: | Height: | Size: 544 B |
BIN
piqt_utils/piconnedit/icons/edit-paste.png
Normal file
|
After Width: | Height: | Size: 1.4 KiB |
BIN
piqt_utils/piconnedit/icons/edit-redo.png
Normal file
|
After Width: | Height: | Size: 3.3 KiB |
BIN
piqt_utils/piconnedit/icons/edit-table-insert-row-below.png
Normal file
|
After Width: | Height: | Size: 852 B |
BIN
piqt_utils/piconnedit/icons/edit-undo.png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |