-
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.
Showing
4 changed files
with
126 additions
and
9 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,78 @@ | ||
name: Test build | ||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: ["develop"] | ||
pull_request: | ||
branches: | ||
- "develop" | ||
|
||
jobs: | ||
debian: | ||
name: Debian 12 | ||
runs-on: ubuntu-latest | ||
container: ghcr.io/educelab/ci-docker:base.12.1 | ||
if: ${{ github.event_name }} == "merge_request_event" || !(${{ github.ref }} && $CI_OPEN_MERGE_REQUESTS) || ${{ github.ref }} | ||
timeout-minutes: 180 | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build vc-deps | ||
run: | | ||
cmake -S . -B build/ -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_MESSAGE=NEVER | ||
cmake --build build/ | ||
macos: | ||
name: macOS | ||
runs-on: macos-14 | ||
timeout-minutes: 180 | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Homebrew dependencies | ||
run: | | ||
brew update | ||
brew unlink libtiff libpng | ||
brew install ninja | ||
- name: Remove conflicting packages | ||
run: | | ||
sudo rm -rf /Library/Frameworks/Mono.framework/ | ||
- name: Use the Command Line Tools | ||
run: | | ||
sudo xcode-select -s /Library/Developer/CommandLineTools | ||
- name: Build vc-deps | ||
run: | | ||
cmake -S . -B build/ -GNinja -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_MESSAGE=NEVER | ||
cmake --build build/ | ||
macos_universal: | ||
name: macOS Universal | ||
runs-on: macos-14 | ||
timeout-minutes: 180 | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Homebrew dependencies | ||
run: | | ||
brew update | ||
brew unlink libtiff libpng | ||
brew install ninja | ||
- name: Remove conflicting packages | ||
run: | | ||
sudo rm -rf /Library/Frameworks/Mono.framework/ | ||
- name: Use the Command Line Tools | ||
run: | | ||
sudo xcode-select -s /Library/Developer/CommandLineTools | ||
- name: Build vc-deps | ||
run: | | ||
cmake -S . -B build/ -GNinja -GNinja -DCMAKE_BUILD_TYPE=Release -DBUILD_MACOS_MULTIARCH=ON -DCMAKE_INSTALL_MESSAGE=NEVER | ||
cmake --build build/ |
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
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,36 @@ | ||
option(VCDEPS_BUILD_GSL "Build GNU Scientific Library" ON) | ||
|
||
if(VCDEPS_BUILD_GSL) | ||
# make sure the prefix is an absolute path | ||
file(REAL_PATH ${CMAKE_INSTALL_PREFIX} GSL_INSTALL_PREFIX EXPAND_TILDE) | ||
|
||
# enable PIC | ||
if(CMAKE_POSITION_INDEPENDENT_CODE) | ||
set(GSL_WITH_PIC "--with-pic") | ||
endif() | ||
|
||
# (macOS) universal libraries | ||
if(BUILD_MACOS_MULTIARCH) | ||
set(GSL_CFLAGS "-arch x86_64 -arch arm64") | ||
endif() | ||
|
||
# build and install | ||
externalproject_add( | ||
gsl | ||
DEPENDS ${GLOBAL_DEPENDS} | ||
URL https://ftpmirror.gnu.org/gsl/gsl-2.8.tar.gz | ||
URL_HASH SHA512=4427f6ce59dc14eabd6d31ef1fcac1849b4d7357faf48873aef642464ddf21cc9b500d516f08b410f02a2daa9a6ff30220f3995584b0a6ae2f73c522d1abb66b | ||
DOWNLOAD_NO_PROGRESS true | ||
DOWNLOAD_EXTRACT_TIMESTAMP ON | ||
PATCH_COMMAND ${GSL_PATCH_CMD} | ||
CONFIGURE_COMMAND | ||
${CMAKE_COMMAND} -E env CFLAGS=${GSL_CFLAGS} | ||
./configure --prefix=${GSL_INSTALL_PREFIX} ${GSL_WITH_PIC} | ||
BUILD_COMMAND make && make install | ||
BUILD_IN_SOURCE true | ||
INSTALL_COMMAND "" | ||
) | ||
|
||
else() | ||
add_custom_target(gsl) | ||
endif() |