-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 7795639
Showing
31 changed files
with
1,376 additions
and
0 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,54 @@ | ||
# C++ objects and libs | ||
*.slo | ||
*.lo | ||
*.o | ||
*.a | ||
*.la | ||
*.lai | ||
*.so | ||
*.so.* | ||
*.dll | ||
*.dylib | ||
|
||
# Qt-es | ||
object_script.*.Release | ||
object_script.*.Debug | ||
*_plugin_import.cpp | ||
/.qmake.cache | ||
/.qmake.stash | ||
*.pro.user | ||
*.pro.user.* | ||
*.qbs.user | ||
*.qbs.user.* | ||
*.moc | ||
moc_*.cpp | ||
moc_*.h | ||
qrc_*.cpp | ||
ui_*.h | ||
*.qmlc | ||
*.jsc | ||
Makefile* | ||
*build-* | ||
*.qm | ||
*.prl | ||
|
||
# Qt unit tests | ||
target_wrapper.* | ||
|
||
# QtCreator | ||
*.autosave | ||
|
||
# QtCreator Qml | ||
*.qmlproject.user | ||
*.qmlproject.user.* | ||
|
||
# QtCreator CMake | ||
CMakeLists.txt.user* | ||
|
||
# QtCreator 4.8< compilation database | ||
compile_commands.json | ||
|
||
# QtCreator local machine specific files for imported projects | ||
*creator.user* | ||
|
||
*_qmlcache.qrc |
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,49 @@ | ||
cmake_minimum_required(VERSION 3.16) | ||
|
||
if(NOT QOMPASS_VERSION) | ||
message(WARNING "Notice: QOMPASS_VERSION variable was not set. Defaulting to 0.1") | ||
set(QOMPASS_VERSION "0.1") | ||
endif() | ||
|
||
project(qompass VERSION ${QOMPASS_VERSION} LANGUAGES CXX) | ||
|
||
set(CMAKE_AUTOMOC ON) | ||
set(CMAKE_AUTORCC ON) | ||
set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
|
||
find_package(Qt6 6.2 REQUIRED COMPONENTS Quick Sensors) | ||
|
||
configure_file(main.cpp.in main.cpp @ONLY) | ||
|
||
qt_add_executable(qompass | ||
${CMAKE_BINARY_DIR}/main.cpp | ||
) | ||
|
||
qt_add_qml_module(qompass | ||
URI qompass | ||
VERSION 1.0 | ||
QML_FILES Main.qml | ||
) | ||
|
||
set_property(TARGET qompass PROPERTY QT_ANDROID_PACKAGE_SOURCE_DIR | ||
${CMAKE_CURRENT_SOURCE_DIR}/android) | ||
|
||
target_link_libraries(qompass | ||
PRIVATE Qt6::Quick | ||
Qt6::Sensors | ||
) | ||
|
||
qt_add_resources(qompass | ||
"main" | ||
PREFIX | ||
"/" | ||
FILES | ||
images/degrees_indicator.png | ||
images/north_indicator.png | ||
) | ||
|
||
install(TARGETS qompass | ||
BUNDLE DESTINATION . | ||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} | ||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} | ||
) |
Oops, something went wrong.