mirror of
https://github.com/renbaoshuo/s2oj-gcc.git
synced 2024-09-07 23:05:17 +00:00
chore: upload dist to artifacts
This commit is contained in:
parent
53cd2cff86
commit
f13b8e8730
15
.github/workflows/build.yml
vendored
15
.github/workflows/build.yml
vendored
@ -15,6 +15,13 @@ jobs:
|
||||
apt install -y curl flex bzip2 git make gcc g++ libgmp-dev libmpfr-dev libmpc-dev gcc-multilib
|
||||
- name: Build
|
||||
run: bash build.sh
|
||||
- name: Upload to artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: s2oj-gcc.zip
|
||||
path: deb/
|
||||
- name: Pack
|
||||
run: dpkg-deb --build deb s2oj-gcc-$(cat GCC_VERSION)~1baoshuo1.deb
|
||||
- name: Upload
|
||||
run: |
|
||||
curl --user "${GITEA_USER}:${GITEA_TOKEN}" \
|
||||
@ -24,3 +31,11 @@ jobs:
|
||||
GITEA_ENDPOINT: https://git.m.ac
|
||||
GITEA_USER: baoshuo
|
||||
GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }}
|
||||
- name: Get Package Filename
|
||||
id: GetPackageFilename
|
||||
run: echo ::set-output name=filename::s2oj-gcc-$(cat GCC_VERSION)~1baoshuo1.deb
|
||||
- name: Upload to artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: s2oj-gcc.deb
|
||||
path: ${{ steps.GetPackageFilename.outputs.filename }}
|
||||
|
6
build.sh
6
build.sh
@ -34,7 +34,6 @@ build_cd ${CURRENT_DIR}
|
||||
# Configure GCC
|
||||
echo "===> Configuring GCC..."
|
||||
build_cd ${CURRENT_DIR}/build
|
||||
echo " Now at: $(pwd)"
|
||||
${GCC_SRC}/configure -v \
|
||||
--enable-languages=c,c++ \
|
||||
--prefix=/usr \
|
||||
@ -47,8 +46,8 @@ ${GCC_SRC}/configure -v \
|
||||
echo "===> Building GCC..."
|
||||
make -j$(nproc)
|
||||
|
||||
# Make .deb package
|
||||
echo "===> Making .deb package \"s2oj-gcc-$GCC_VERSION~1baoshuo1.deb\" ..."
|
||||
# Prepare for packaging
|
||||
echo "===> Preparing for packaging..."
|
||||
make -j$(nproc) DESTDIR=${CURRENT_DIR}/deb install
|
||||
build_cd ${CURRENT_DIR}/deb
|
||||
mkdir -p DEBIAN
|
||||
@ -62,4 +61,3 @@ Maintainer: Baoshuo <i@baoshuo.ren>
|
||||
Description: GCC $GCC_VERSION for S2OJ
|
||||
EOF
|
||||
build_cd ${CURRENT_DIR}
|
||||
dpkg-deb --build deb s2oj-gcc-$GCC_VERSION~1baoshuo1.deb
|
||||
|
Loading…
Reference in New Issue
Block a user