Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: cypari2

on:
pull_request:
types: [opened, synchronize]
push:
tags:
- '*'
workflow_dispatch:
# Allow to run manually

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
pari-version: ['pari-2.9.4', 'pari-2.9.5', 'pari-2.11.0', 'pari-2.11.0', 'pari-2.11.2', 'pari-2.11.3', 'pari-2.11.4', 'pari-2.13.0', 'snapshot']
env:
LC_ALL: C
PARI_VERSION: ${{ matrix.pari-version }}
steps:
- name: Set up the repository
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install pari
run: |
ccache -M 256M && ccache -s
export PATH="/usr/lib/ccache:$PATH"
bash -x .travis-install-pari.sh
- name: Local build
run: |
pip install sphinx cython cysignals
make build
make install
make check
(cd docs && make html)
14 changes: 13 additions & 1 deletion .travis-install-pari.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,19 @@
# Exit on error
set -e

if [ "$PARI_VERSION" = snapshot ]; then
URLDIR=snapshots
fi

if [ "$URLDIR" = "" ]; then
PURE_VERSION=${PARI_VERSION/pari-}
URLDIR=OLD/${PURE_VERSION%.*}
fi

PARI_URL="http://pari.math.u-bordeaux.fr/pub/pari/$URLDIR"
PARI_URL1="http://pari.math.u-bordeaux.fr/pub/pari/unix"
PARI_URL2="http://pari.math.u-bordeaux.fr/pub/pari/unstable"
PARI_URL3="http://pari.math.u-bordeaux.fr/pub/pari/snapshot"

# Figure out PARI version and download location
# Note that we support giving a list of URLs
Expand All @@ -14,7 +26,7 @@ if [ "$PARI_VERSION" = snapshot ]; then
fi

# Download PARI sources
wget --no-verbose "$PARI_URL/$PARI_VERSION.tar.gz"
wget --no-verbose "$PARI_URL/$PARI_VERSION.tar.gz" || wget --no-verbose "$PARI_URL1/$PARI_VERSION.tar.gz" || wget --no-verbose "$PARI_URL2/$PARI_VERSION.tar.gz" || wget --no-verbose "$PARI_URL3/$PARI_VERSION.tar.gz"

# Install
tar xzf "$PARI_VERSION.tar.gz"
Expand Down