diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 52eb04b..f5da4a9 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -12,11 +12,19 @@ on: jobs: main: - runs-on: ubuntu-latest + strategy: + matrix: + include: + - os: ubuntu-latest + conda_env_file: dev-linux-64.yaml + - os: macos-latest + conda_env_file: dev-osx-64.yaml + + runs-on: ${{ matrix.os }} timeout-minutes: 20 concurrency: - group: ci-main-${{ github.ref }} + group: ci-${{ matrix.os }}-main-${{ github.ref }} cancel-in-progress: true defaults: @@ -37,11 +45,16 @@ jobs: channels: conda-forge,nodefaults channel-priority: true activate-environment: arx - environment-file: conda/dev-linux-64.yaml + environment-file: conda/${{ matrix.conda_env_file }} - - name: build + - name: Build on Linux + if: ${{ matrix.os == 'ubuntu-latest' }} run: make build-dev CLEAN=1 + - name: Build on OSX + if: ${{ matrix.os == 'macos-latest' }} + run: make build-dev CLEAN=1 CC=clang-cl + - name: test flags run: | build/arx --version diff --git a/Makefile b/Makefile index 6a2dedf..2c04e7d 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # build CLEAN=0 -CXX=clang++ -CC=clang +CXX:=clang++ +CC:=clang ARGS:= diff --git a/conda/dev-linux-64.yaml b/conda/dev-linux-64.yaml index f80790a..3d53b44 100644 --- a/conda/dev-linux-64.yaml +++ b/conda/dev-linux-64.yaml @@ -14,7 +14,6 @@ dependencies: - gdb - glib - libclang-cpp 15.* -# - libcxx 15.* - libstdcxx-devel_linux-64 - libstdcxx-ng - lld 15.* diff --git a/conda/dev-osx-64.yaml b/conda/dev-osx-64.yaml new file mode 100644 index 0000000..56e4c71 --- /dev/null +++ b/conda/dev-osx-64.yaml @@ -0,0 +1,40 @@ +name: arx +channels: +- nodefaults +- conda-forge +dependencies: +# build +- clangdev 14.* +- clangxx 14.* +- cmake +- compiler-rt 14.* +- compilers +# it would be nice to replace that by lldb, but +# the latest version on conda-forge is very old. +- gdb +- glib +- libclang-cpp 14.* +- lld 14.* +- llvmdev 14.* +- make +- meson +- ninja +- pkg-config +# run +- arrow-c-glib 10.* +- arrow-cpp 10.* +- cli11 +- glog +# dev +- cppcheck +- docker-compose +- doxygen +- gmock +- gtest +# - include-what-you-use >=0.18 +- jupyterlab +- lcov +- mkdocs +- mkdocs-jupyter +- nodejs +- pre-commit diff --git a/meson.build b/meson.build index c229320..c11eeb4 100644 --- a/meson.build +++ b/meson.build @@ -11,9 +11,22 @@ PROJECT_PATH = meson.source_root() cxx = meson.get_compiler('cpp') +r = run_command('echo', '$OSTYPE', check: true) +operating_system = r.stdout().strip() + +# note: probably not a good approach but we should have both +# OS with the same pinning soon + +if 'Linux' in operating_system + llvm_version = '>=15.0.0' +else + # osx + llvm_version = '>=14.0.0' +endif + deps = [ dependency('arrow'), - dependency('llvm', version : '>=14.0.0'), + dependency('llvm', version : llvm_version), dependency('CLI11'), dependency('threads'), dependency('glog'),