Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
83 changes: 83 additions & 0 deletions .github/workflows/mac.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: Mac

on:
push:
branches:
- main
pull_request:
types: [ assigned, opened, synchronize, reopened ]
release:
types: [ published, edited ]

jobs:
build:
name: ${{ matrix.config.os }} ${{ matrix.config.arch }} ${{ matrix.config.cmakeBuildType }}
runs-on: ${{ matrix.config.os }}
strategy:
matrix:
config: [
{
os: macos-14,
arch: arm64,
cmakeBuildType: Release,
},
]

env:
COMPILER_CACHE_VERSION: 1
COMPILER_CACHE_DIR: ${{ github.workspace }}/compiler-cache
CCACHE_DIR: ${{ github.workspace }}/compiler-cache/ccache
CCACHE_BASEDIR: ${{ github.workspace }}

steps:
- uses: actions/checkout@v4
- uses: actions/cache@v4
id: cache-builds
with:
key: v${{ env.COMPILER_CACHE_VERSION }}-${{ matrix.config.os }}-${{ matrix.config.arch }}-${{ matrix.config.cmakeBuildType }}-${{ github.run_id }}-${{ github.run_number }}
restore-keys: v${{ env.COMPILER_CACHE_VERSION }}-${{ matrix.config.os }}-${{ matrix.config.arch }}-${{ matrix.config.cmakeBuildType }}
path: ${{ env.COMPILER_CACHE_DIR }}

- name: Setup Mac
run: |
brew install \
cmake \
ninja \
boost \
eigen \
flann \
freeimage \
metis \
glog \
googletest \
ceres-solver \
qt5 \
glew \
cgal \
sqlite3 \
ccache

- name: Configure and build
run: |
cmake --version
mkdir build
cd build
cmake .. \
-GNinja \
-DCMAKE_BUILD_TYPE=${{ matrix.config.cmakeBuildType }} \
-DTESTS_ENABLED=ON \
-DCMAKE_PREFIX_PATH="$(brew --prefix qt@5)"
ninja

- name: Run tests
run: |
cd build
set +e
ctest --output-on-failure -E .+colmap_.*

- name: Cleanup compiler cache
run: |
set -x
ccache --show-stats --verbose
ccache --evict-older-than 1d
ccache --show-stats --verbose
2 changes: 1 addition & 1 deletion .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,4 +185,4 @@ jobs:
# Delete cache older than 10 days.
find "$CTCACHE_DIR"/*/ -mtime +10 -print0 | xargs -0 rm -rf
echo "Size of ctcache after: $(du -sh $CTCACHE_DIR)"
echo "Number of ctcache files after: $(find $CTCACHE_DIR | wc -l)"
echo "Number of ctcache files after: $(find $CTCACHE_DIR | wc -l)"''
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
build
data
/build
/data
/.vscode
1 change: 0 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)

set_property(GLOBAL PROPERTY GLOBAL_DEPENDS_NO_CYCLES ON)

option(OPENMP_ENABLED "Whether to enable OpenMP parallelization" ON)
option(TESTS_ENABLED "Whether to build test binaries" OFF)
option(ASAN_ENABLED "Whether to enable AddressSanitizer flags" OFF)
option(CCACHE_ENABLED "Whether to enable compiler caching, if available" ON)
Expand Down
5 changes: 0 additions & 5 deletions cmake/FindDependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ if(TESTS_ENABLED)
find_package(GTest REQUIRED)
endif()

if (OPENMP_ENABLED)
message(STATUS "Enabling OpenMP")
find_package(OpenMP REQUIRED)
endif()

include(FetchContent)
FetchContent_Declare(PoseLib
GIT_REPOSITORY https://github.com/PoseLib/PoseLib.git
Expand Down
193 changes: 0 additions & 193 deletions docs/INSTALL_MAC.md
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we want to remove this documentation? I think it might still be helpful for others?

This file was deleted.

4 changes: 0 additions & 4 deletions glomap/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,6 @@ target_link_libraries(
)
target_include_directories(glomap PUBLIC ..)

if(OPENMP_FOUND)
target_link_libraries(glomap PUBLIC OpenMP::OpenMP_CXX)
endif()

if(MSVC)
target_compile_options(glomap PRIVATE /bigobj)
else()
Expand Down
Loading