-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed bug#354 in qutest.py (https://sourceforge.net/p/qpc/bugs/354/) Added customizable tkinter frame to qview.py Cmake support
- Loading branch information
1 parent
f3a1b84
commit 2303bde
Showing
9 changed files
with
245 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
# use a recent CMake version | ||
cmake_minimum_required(VERSION 3.23 FATAL_ERROR) | ||
cmake_policy(VERSION 3.23) | ||
cmake_policy(SET CMP0083 NEW) | ||
|
||
# first of all protect against in-source builds | ||
file(REAL_PATH "${CMAKE_SOURCE_DIR}" _srcdir) | ||
file(REAL_PATH "${CMAKE_BINARY_DIR}" _bindir) | ||
|
||
if(${_srcdir} STREQUAL ${_bindir}) | ||
message(FATAL_ERROR " FATAL: In-source builds are not allowed! | ||
You should create a separate directory for build files.") | ||
endif() | ||
unset(_srcdir) | ||
unset(_bindir) | ||
|
||
# update CMAKE_MODULE_PATH | ||
list(PREPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/source/cmake ${CMAKE_SOURCE_DIR}/cmake ${CMAKE_SOURCE_DIR} ${HOME_PATH}/cmake) | ||
|
||
if(NOT SW_VERSION) | ||
set(SW_VERSION "7.3.3" CACHE STRING "Software Version") | ||
endif() | ||
|
||
message(STATUS "`qtools` - see \"https://www.state-machine.com/qtools/\" for further details.") | ||
|
||
# the `qtools` project, consisting of the tools listed below | ||
# qtools - https://www.state-machine.com/qtools/ | ||
project( | ||
qtools | ||
VERSION ${SW_VERSION} | ||
DESCRIPTION "QTools - https://www.state-machine.com/qtools/" | ||
HOMEPAGE_URL "https://www.state-machine.com/qtools/" | ||
LANGUAGES C | ||
) | ||
|
||
# select target platform specific source directory | ||
if(WIN32 OR CMAKE_SYSTEM_NAME STREQUAL Windows) | ||
set(PLATFORM_DIR win32) | ||
else() | ||
set(PLATFORM_DIR posix) | ||
endif() | ||
|
||
# the qclean tool - https://www.state-machine.com/qtools/qclean.html | ||
add_executable(qclean) | ||
add_subdirectory(qclean) | ||
|
||
# the qfsgen tool - https://www.state-machine.com/qtools/qfsgen.html | ||
add_executable(qfsgen) | ||
add_subdirectory(qfsgen) | ||
|
||
# the qspy tool - https://www.state-machine.com/qtools/qspy.html | ||
add_executable(qspy) | ||
add_subdirectory(qspy) | ||
|
||
# the `install` targets | ||
set(QDATAROOT share/qtools) | ||
set(QTARGETS qclean qfsgen qspy) | ||
set(QDIRS qcalc qutest qview qwin) | ||
set(QBIN cmock generate_test_runner python3 qcalc qspy_exit sha256) | ||
list(TRANSFORM QBIN APPEND .bat) | ||
list(APPEND QBIN Termite.ini) | ||
list(TRANSFORM QBIN PREPEND bin/) | ||
|
||
install(TARGETS ${QTARGETS}) | ||
install(PROGRAMS ${BIN_FILES} TYPE BIN) | ||
install(DIRECTORY doc LICENSES DESTINATION ${QDATAROOT}/doc) | ||
install(FILES README.md DESTINATION ${QDATAROOT}/doc) | ||
install(DIRECTORY ${QDIRS} DESTINATION ${QDATAROOT}/data) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"version": 6, | ||
"cmakeMinimumRequired": { | ||
"major": 3, | ||
"minor": 23, | ||
"patch": 0 | ||
}, | ||
|
||
"configurePresets": [ | ||
{ | ||
"name": "qtools", | ||
"displayName": "qtools", | ||
"description": "Build all qtools", | ||
"binaryDir": "${sourceDir}/build", | ||
"generator": "Ninja Multi-Config", | ||
"cacheVariables": { | ||
"CMAKE_CONFIGURATION_TYPES": { | ||
"type": "STRING", | ||
"value": "Debug;Release" | ||
}, | ||
"CMAKE_BUILD_TYPE": { | ||
"type": "STRING", | ||
"value": "Debug" | ||
} | ||
} | ||
} | ||
], | ||
|
||
"buildPresets": [ | ||
{ | ||
"name": "qtools", | ||
"displayName": "qtools", | ||
"description": "Build all qtools", | ||
"configurePreset": "qtools", | ||
"configuration": "Release" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
message(STATUS "`qtools/qclean` - see \"https://www.state-machine.com/qtools/qclean.html\" for further details.") | ||
|
||
# the main target | ||
target_sources(qclean PRIVATE | ||
source/main.c | ||
source/getopt.c | ||
${PLATFORM_DIR}/filesearch.c | ||
) | ||
|
||
# add include dirs to target (-I...) | ||
target_include_directories(qclean PRIVATE include) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# QTools/qfsgen | ||
message(STATUS "`qtools/qfsgen` - see \"https://www.state-machine.com/qtools/qfsgen.html\" for further details.") | ||
|
||
# the main target | ||
target_sources(qfsgen PRIVATE | ||
source/main.c | ||
${PLATFORM_DIR}/filesearch.c | ||
) | ||
|
||
# add include dirs to target (-I...) | ||
target_include_directories(qfsgen PRIVATE include) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# QTools/qspy | ||
message(STATUS "`qtools/qspy` - see \"https://www.state-machine.com/qtools/qspy.html\" for further details.") | ||
|
||
# the main target | ||
target_sources(qspy PRIVATE | ||
source/qspy.c | ||
source/qspy_main.c | ||
source/qspy_be.c | ||
source/qspy_dict.c | ||
source/qspy_seq.c | ||
source/qspy_tx.c | ||
source/getopt.c | ||
${PLATFORM_DIR}/qspy_pal.c | ||
) | ||
|
||
# add include dirs to target (-I...) | ||
target_include_directories(qspy PRIVATE | ||
${PLATFORM_DIR} | ||
include | ||
) | ||
|
||
# set defines (-D...) | ||
target_compile_definitions(qspy PRIVATE QSPY_APP) | ||
|
||
# add link libraries (-l...) | ||
if(CMAKE_SYSTEM_NAME STREQUAL Windows) | ||
target_link_libraries(qspy PRIVATE ws2_32) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ | |
|
||
setup( | ||
name="qutest", | ||
version="7.3.3", | ||
version="7.3.4", | ||
author="Quantum Leaps", | ||
author_email="[email protected]", | ||
description="QUTest Python scripting support", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters