Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,18 @@ jobs:
-k "$MERGINSECRETS_DECRYPT_KEY" \
-md md5

- name: Extract Trimble App ID
env:
TRIMBLE_SECRETS_DECRYPT_KEY: ${{ secrets.TRIMBLE_SECRETS_DECRYPT_KEY }}
run: |
cd mm/app/position/providers/
$HOMEBREW_PREFIX/bin/openssl \
aes-256-cbc -d \
-in trimblesecrets.cpp.enc \
-out trimblesecrets.cpp \
-k "$TRIMBLE_SECRETS_DECRYPT_KEY" \
-md md5

- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
Expand Down Expand Up @@ -237,6 +249,7 @@ jobs:
-DQT_ANDROID_SIGN_APK=Yes \
-DQT_ANDROID_SIGN_AAB=Yes \
-DUSE_MM_SERVER_API_KEY=Yes \
-DWITH_TRIMBLE_PROVIDERS=TRUE \
-DUSE_KEYCHAIN=No \
-DCMAKE_TOOLCHAIN_FILE:PATH="${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake" \
-GNinja \
Expand Down
13 changes: 13 additions & 0 deletions .github/workflows/ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,18 @@ jobs:
-k "$MERGINSECRETS_DECRYPT_KEY" \
-md md5

- name: Extract Trimble App ID
env:
TRIMBLE_SECRETS_DECRYPT_KEY: ${{ secrets.TRIMBLE_SECRETS_DECRYPT_KEY }}
run: |
cd mm/app/position/providers/
$HOMEBREW_PREFIX/bin/openssl \
aes-256-cbc -d \
-in trimblesecrets.cpp.enc \
-out trimblesecrets.cpp \
-k "$TRIMBLE_SECRETS_DECRYPT_KEY" \
-md md5

- name: Configure Keychain
run: |
security create-keychain -p "" "$KEYCHAIN"
Expand Down Expand Up @@ -164,6 +176,7 @@ jobs:
-D CMAKE_SYSTEM_PROCESSOR=aarch64 \
-DIOS=TRUE \
-DUSE_MM_SERVER_API_KEY=TRUE \
-DWITH_TRIMBLE_PROVIDERS=TRUE \
-DUSE_KEYCHAIN=No \
-DCMAKE_INSTALL_PREFIX:PATH=../install-mm \
-G "Xcode" \
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ jobs:
-DVCPKG_TARGET_TRIPLET=${{ env.TRIPLET }} \
-DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake \
-DUSE_MM_SERVER_API_KEY=TRUE \
-DHAVE_BLUETOOTH=FALSE \
-DWITH_BLUETOOTH_PROVIDERS=FALSE \
-DUSE_KEYCHAIN=No \
-DCOVERAGE=TRUE \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
Expand Down
29 changes: 17 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,25 +1,30 @@
# broad file type filters
*.autosave
*.orig
*.DS_Store
*.user
*build*/
app/config.pri
core/merginsecrets.cpp
*.idea
*.vscode
*.cache
test/temp_projects/
test/temp_extra_projects/
*.gpkg-wal
*.gpkg-shm
# secrets
core/merginsecrets.cpp
app/position/providers/trimblesecrets.cpp
.github/secrets/ios/LutraConsulting*.mobileprovision
Input_keystore.keystore
google_play_key.json
# generated files
app/config.pri
*build*/
input.pro.user*
app/android/assets
app/android/AndroidManifest.xml
app/android/build.gradle
app/android/.gradle
*.gpkg-wal
*.gpkg-shm
Input_keystore.keystore
CMakeLists.txt.user
.github/secrets/ios/LutraConsulting*.mobileprovision
google_play_key.json
test/temp_projects/
test/temp_extra_projects/
fastlane/report.xml
CMakeUserPresets.json
CMakeLists.txt.user
CMakeUserPresets.json
CLAUDE.md
32 changes: 27 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,9 @@ else ()
endif ()

if (IOS)
set(HAVE_BLUETOOTH_DEFAULT FALSE)
set(WITH_BLUETOOTH_PROVIDERS_DEFAULT FALSE)
else ()
set(HAVE_BLUETOOTH_DEFAULT TRUE)
set(WITH_BLUETOOTH_PROVIDERS_DEFAULT TRUE)
endif ()

if (DEFINED ENV{MM_VERSION_CODE})
Expand Down Expand Up @@ -138,11 +138,18 @@ set(ENABLE_TESTS
${ENABLE_TESTS_DEFAULT}
CACHE BOOL "Whether to build tests"
)
set(HAVE_BLUETOOTH
${HAVE_BLUETOOTH_DEFAULT}
set(WITH_BLUETOOTH_PROVIDERS
${WITH_BLUETOOTH_PROVIDERS_DEFAULT}
CACHE BOOL "Building with bluetooth position provider"
)

set(WITH_TRIMBLE_PROVIDERS
FALSE
CACHE
BOOL
"Building with Trimble GNSS position provider via Trimble Mobile Manager (mobile only)"
)

set(USE_KEYCHAIN
FALSE
CACHE
Expand Down Expand Up @@ -257,14 +264,29 @@ if (IOS OR MACOS)
find_package(Tasn1 REQUIRED)
endif ()

if (HAVE_BLUETOOTH)
if (WITH_BLUETOOTH_PROVIDERS)
find_package(
Qt6
COMPONENTS Bluetooth
REQUIRED
)
endif ()

if (WITH_TRIMBLE_PROVIDERS)
if (NOT ANDROID AND NOT IOS)
message(
FATAL_ERROR
"WITH_TRIMBLE_PROVIDERS is only supported on Android and iOS. Set WITH_TRIMBLE_PROVIDERS=FALSE for desktop builds."
)
else ()
find_package(
Qt6
COMPONENTS WebSockets
REQUIRED
)
endif ()
endif ()

if (ENABLE_TESTS)
find_package(
Qt6
Expand Down
Loading
Loading