mirror of
https://github.com/asg017/sqlite-vec.git
synced 2026-04-25 16:56:27 +02:00
111 lines
3.4 KiB
YAML
111 lines
3.4 KiB
YAML
name: "Test"
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
permissions:
|
|
contents: read
|
|
jobs:
|
|
build-linux-x86_64-extension:
|
|
runs-on: ubuntu-20.04
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.12"
|
|
- run: ./scripts/vendor.sh
|
|
- run: make loadable
|
|
- run: pip install pytest numpy; make test-loadable
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-linux-x86_64-extension
|
|
path: dist/*
|
|
build-macos-x86_64-extension:
|
|
runs-on: macos-12
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- run: ./scripts/vendor.sh
|
|
- run: make loadable
|
|
- run: /usr/local/opt/python@3/libexec/bin/python -m pip install pytest numpy; make test-loadable python=/usr/local/opt/python@3/libexec/bin/python
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-macos-x86_64-extension
|
|
path: dist/*
|
|
build-macos-aarch64-extension:
|
|
runs-on: macos-14
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- run: ./scripts/vendor.sh
|
|
- run: make loadable
|
|
- run: /opt/homebrew/opt/python3/libexec/bin/python -m pip install pytest numpy --break-system-packages; make test-loadable python=/opt/homebrew/opt/python3/libexec/bin/python
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-macos-aarch64-extension
|
|
path: dist/*
|
|
build-windows-x86_64-extension:
|
|
runs-on: windows-2019
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.12"
|
|
- run: ./scripts/vendor.sh
|
|
shell: bash
|
|
- run: make loadable CC=gcc
|
|
- run: pip install pytest numpy; make test-loadable
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-windows-x86_64-extension
|
|
path: dist/*
|
|
build-windows-x86_64-extension-msvc:
|
|
if: false
|
|
runs-on: windows-2019
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: ilammy/msvc-dev-cmd@v1
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.12"
|
|
- run: ./scripts/vendor.sh
|
|
shell: bash
|
|
- run: make sqlite-vec.h
|
|
- run: cl.exe \
|
|
/fPIC -shared \
|
|
/W4 \
|
|
/Ivendor/ \
|
|
/O2 \
|
|
\
|
|
sqlite-vec.c -o dist/vec0.dll
|
|
- run: pip install pytest numpy; make test-loadable
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-windows-x86_64-extension
|
|
path: dist/*
|
|
build-wasm32-emscripten:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: mymindstorm/setup-emsdk@v12
|
|
with:
|
|
version: "latest"
|
|
- run: ./scripts/vendor.sh
|
|
- run: make sqlite-vec.h
|
|
- run: make wasm
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-wasm32-emscripten
|
|
path: dist/*
|
|
build-cosmopolitan:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- run: |
|
|
mkdir $HOME/cosmo
|
|
curl -L -o cosmocc-3.3.6.zip https://github.com/jart/cosmopolitan/releases/download/3.3.6/cosmocc-3.3.6.zip
|
|
unzip cosmocc-3.3.6.zip -d $HOME/cosmo
|
|
- run: ./scripts/vendor.sh
|
|
- run: make cli CC=$HOME/cosmo/bin/cosmocc AR=$HOME/cosmo/bin/cosmoar OMIT_SIMD=1
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: sqlite-vec-cosmopolitan
|
|
path: dist/*
|