Skip to content

Commit

Permalink
Test python brew
Browse files Browse the repository at this point in the history
  • Loading branch information
gaetanserre committed Jul 12, 2024
1 parent 6ef8324 commit a6c642a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 30 deletions.
31 changes: 1 addition & 30 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Build GKLS

on:
push:
branches: [ "main", "dev"]
branches: [ "main", "dev", "CI"]
tags:
- 'v*'
pull_request:
Expand All @@ -11,42 +11,13 @@ on:
workflow_dispatch:

jobs:
build-x86-linux:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Install dependencies
run: |
sudo apt-get install python3
sudo apt-get install -y python3-dev
python -m pip install --upgrade pip
# Runs a single command using the runners shell
- name: Build GKLS
run: |
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.local/lib
sh build_and_install.sh
- name: Upload artifact
uses: actions/upload-artifact@master
with:
name: linux-artifact
path: |
pygkls/libpygkls.so
pygkls/pygkls*.so
build-arm-macos:
runs-on: macos-latest
needs: build-x86-linux
steps:
- uses: actions/checkout@v4

- name: Install dependencies
run: |
brew uninstall python --ignore-dependencies
brew cleanup python
python -m pip install --upgrade pip
python -m pip install pybind11
Expand Down
7 changes: 7 additions & 0 deletions build_and_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ NC="\033[0m"
platform=$(python -c "import platform; print(platform.processor())")
echo -e "${Purple}Running on ${platform} platform${NC}"

echo -e "${Purple}Which python${NC}"
which python
which python3

echo -e "${Purple}Python config${NC}"
python3-config --ldflags

unameOut="$(uname -s)"
case "${unameOut}" in
Linux*) lib_ext=so; lib_path=LD_LIBRARY_PATH;;
Expand Down

0 comments on commit a6c642a

Please sign in to comment.