Skip to content

Commit 00d6507

Browse files
committed
.github/workflows/dist.yml: New
1 parent 2fb9564 commit 00d6507

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed

.github/workflows/dist.yml

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v[0-9]*'
7+
8+
workflow_dispatch:
9+
# Allow to run manually
10+
11+
env:
12+
# Ubuntu packages to install so that the projects' "make dist" can succeed
13+
DIST_PREREQ: libopenblas-dev libgmp-dev
14+
# Name of this project in the Sage distribution
15+
SPKG: linbox
16+
17+
jobs:
18+
release_dist:
19+
runs-on: ubuntu-24.04
20+
env:
21+
PREFIX: /tmp/build
22+
steps:
23+
- name: Check out givaro
24+
uses: actions/checkout@v4
25+
with:
26+
path: build/pkgs/givaro/src
27+
repository: linbox-team/givaro
28+
- name: Check out fflas-ffpack
29+
uses: actions/checkout@v4
30+
with:
31+
path: build/pkgs/fflas_ffpack/src
32+
repository: linbox-team/fflas-ffpack
33+
- name: Check out ${{ env.SPKG }}
34+
uses: actions/checkout@v4
35+
with:
36+
path: build/pkgs/${{ env.SPKG }}/src
37+
- name: Install prerequisites
38+
run: |
39+
sudo DEBIAN_FRONTEND=noninteractive apt-get update
40+
sudo DEBIAN_FRONTEND=noninteractive apt-get install $DIST_PREREQ
41+
wget https://ftpmirror.gnu.org/libtool/libtool-2.4.7.tar.gz
42+
tar xfz libtool-2.4.7.tar.gz
43+
cd libtool-2.4.7
44+
./configure --prefix=${{ env.PREFIX }}
45+
make install
46+
- name: Run make dist, prepare upstream artifact
47+
run: |
48+
export PATH="${{ env.PREFIX }}/bin:$PATH" \
49+
&& (cd build/pkgs/givaro/src && autoreconf -fi && ./configure --prefix=${{ env.PREFIX }} && make -j5 && make install) \
50+
&& export PKG_CONFIG_PATH="${{ env.PREFIX }}/lib/pkgconfig:$PKG_CONFIG_PATH" \
51+
&& (cd build/pkgs/fflas_ffpack/src && autoreconf -fi && ./configure --prefix=${{ env.PREFIX }} && make -j5 && make install) \
52+
&& (cd build/pkgs/${{ env.SPKG }}/src && autoreconf -fi && ./configure --prefix=${{ env.PREFIX }} && make -j5 distcheck || echo "(error ignored)") \
53+
&& mkdir -p upstream && cp build/pkgs/${{ env.SPKG }}/src/*.tar.gz upstream/ \
54+
&& ls -l upstream/
55+
- uses: actions/upload-artifact@v4
56+
with:
57+
path: upstream
58+
name: upstream
59+
- uses: softprops/action-gh-release@v2
60+
with:
61+
generate_release_notes: true
62+
files: |
63+
upstream/*
64+
if: startsWith(github.ref, 'refs/tags/')

0 commit comments

Comments
 (0)