Skip to content

Commit

Permalink
Arm64 Build of g2o
Browse files Browse the repository at this point in the history
  • Loading branch information
hsm4 committed Jan 22, 2024
1 parent 4e46de6 commit bf11316
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/build-dep-g2o.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,19 +47,19 @@ jobs:
working-directory: ${{ github.workspace }}/externals/prebuild_scripts/
run: arch -x86_64 ./build_g2o_for_mac64.sh

#- name: Run build script arm
# working-directory: ${{ github.workspace }}/externals/prebuild_scripts/
# run: arch -arm64 ./build_g2o_for_macArm64.sh
- name: Run build script arm
working-directory: ${{ github.workspace }}/externals/prebuild_scripts/
run: ./build_g2o_for_macArm64.sh

- name: Archive prebuilt g2o intel
uses: actions/upload-artifact@v3
with:
name: prebuilt-g2o-mac64
path: ${{ github.workspace }}/externals/prebuilt/mac64_g2o_20170730

#- name: Archive prebuilt g2o arm
# uses: actions/upload-artifact@v3
# with:
# name: prebuilt-g2o-arm64
# path: ${{ github.workspace }}/externals/prebuilt/macArm64_g2o
- name: Archive prebuilt g2o arm
uses: actions/upload-artifact@v3
with:
name: prebuilt-g2o-arm64
path: ${{ github.workspace }}/externals/prebuilt/macArm64_g2o_20170730

3 changes: 2 additions & 1 deletion cmake/DownloadPrebuilts.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -772,7 +772,8 @@ elseif ("${SYSTEM_NAME_UPPER}" STREQUAL "DARWIN" AND
foreach (lib ${g2o_LINK_LIBS})
add_library(${lib} SHARED IMPORTED)
set_target_properties(${lib} PROPERTIES
IMPORTED_LOCATION "${g2o_DIR}/Debug/lib${lib}.dylib"
IMPORTED_LOCATION "${g2o_DIR}/Release/lib${lib}.dylib"
IMPORTED_LOCATION_DEBUG "${g2o_DIR}/Debug/lib${lib}.dylib"
INTERFACE_INCLUDE_DIRECTORIES "${g2o_INCLUDE_DIR}")
set(g2o_LIBS ${g2o_LIBS} ${lib})
endforeach (lib)
Expand Down
1 change: 1 addition & 0 deletions externals/prebuild_scripts/build_g2o_for_macArm64.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ cmake \
-DG2O_BUILD_EXAMPLES=off \
-DCMAKE_BUILD_TYPE=Release \
-DEIGEN3_INCLUDE_DIR=../eigen \
-DG2O_USE_OPENGL=off \
../..

# finally build it
Expand Down

0 comments on commit bf11316

Please sign in to comment.