Skip to content

Commit

Permalink
Merge pull request #1246 from hans-schmidt/master_update_build_system
Browse files Browse the repository at this point in the history
Update .github build scripts- cleanup, use Ubuntu-20.04, use Node-20
  • Loading branch information
TronBlack authored May 10, 2024
2 parents e48d932 + bffd787 commit 6d48ae0
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 279 deletions.
25 changes: 14 additions & 11 deletions .github/scripts/00-install-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,10 @@ elif [[ ${OS} == "osx" ]]; then
s3curl \
sleuthkit \
bison \
libtinfo5
libtinfo5 \
python3-pip

pip3 install ds-store

elif [[ ${OS} == "linux" || ${OS} == "linux-disable-wallet" || ${OS} == "aarch64" || ${OS} == "aarch64-disable-wallet" ]]; then
apt -y install \
Expand All @@ -80,10 +83,10 @@ elif [[ ${OS} == "linux" || ${OS} == "linux-disable-wallet" || ${OS} == "aarch64
ca-certificates \
curl \
g++-aarch64-linux-gnu \
g++-8-aarch64-linux-gnu \
g++-8-multilib \
gcc-8-aarch64-linux-gnu \
gcc-8-multilib \
g++-9-aarch64-linux-gnu \
g++-9-multilib \
gcc-9-aarch64-linux-gnu \
gcc-9-multilib \
git \
gnupg \
libtool \
Expand All @@ -110,13 +113,13 @@ elif [[ ${OS} == "arm32v7" || ${OS} == "arm32v7-disable-wallet" ]]; then
ca-certificates \
curl \
g++-aarch64-linux-gnu \
g++-8-aarch64-linux-gnu \
gcc-8-aarch64-linux-gnu \
g++-9-aarch64-linux-gnu \
gcc-9-aarch64-linux-gnu \
g++-arm-linux-gnueabihf \
g++-8-arm-linux-gnueabihf \
gcc-8-arm-linux-gnueabihf \
g++-8-multilib \
gcc-8-multilib \
g++-9-arm-linux-gnueabihf \
gcc-9-arm-linux-gnueabihf \
g++-9-multilib \
gcc-9-multilib \
git \
libtool \
pkg-config \
Expand Down
62 changes: 15 additions & 47 deletions .github/scripts/02-copy-build-dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
OS=${1}
GITHUB_WORKSPACE=${2}
GITHUB_REF=${3}
FORCEBUILDDEPS="1"

if [[ ! ${OS} || ! ${GITHUB_WORKSPACE} ]]; then
echo "Error: Invalid options"
Expand All @@ -18,51 +17,20 @@ if [[ ${OS} == "arm32v7-disable-wallet" || ${OS} == "linux-disable-wallet" || ${
OS=`echo ${OS} | cut -d"-" -f1`
fi

if [[ ${GITHUB_REF} =~ "release" || ${FORCEBUILDDEPS} = "1" ]]; then
echo "----------------------------------------"
echo "Building Dependencies for ${OS}"
echo "----------------------------------------"

cd depends
if [[ ${OS} == "windows" ]]; then
make HOST=x86_64-w64-mingw32 -j2
elif [[ ${OS} == "osx" ]]; then
cd ${GITHUB_WORKSPACE}
# curl -O <url>
echo "LEGAL issues with OSX SDK, need to get it yourself and extract the valuable stuff."
echo "See github -> contrib/macdeploy/README.md"
echo "Countdown from 3 sec. Make sure your SDK is at /tmp/SDKs and it is the only *.tar.gz file."
echo "3..."
sleep 1
echo "2..."
sleep 1
echo "1..."
sleep 1
echo "0.. continuing.."
mkdir -p ${GITHUB_WORKSPACE}/depends/SDKs
cd ${GITHUB_WORKSPACE}/depends/SDKs
tar -zxf /tmp/SDKs/*.tar.gz
cd ${GITHUB_WORKSPACE}/depends && make HOST=x86_64-apple-darwin14 -j2
elif [[ ${OS} == "linux" || ${OS} == "linux-disable-wallet" ]]; then
make HOST=x86_64-linux-gnu -j2
elif [[ ${OS} == "arm32v7" || ${OS} == "arm32v7-disable-wallet" ]]; then
make HOST=arm-linux-gnueabihf -j2
elif [[ ${OS} == "aarch64" || ${OS} == "aarch64-disable-wallet" ]]; then
make HOST=aarch64-linux-gnu -j2
fi
else
echo "----------------------------------------"
echo "Retrieving Dependencies for ${OS}"
echo "----------------------------------------"
echo "----------------------------------------"
echo "Building Dependencies for ${OS}"
echo "----------------------------------------"

cd /tmp
curl -O https://raven-build-resources.s3.amazonaws.com/${OS}/raven-${OS}-dependencies.tar.gz
curl -O https://raven-build-resources.s3.amazonaws.com/${OS}/SHASUM
if [[ $(sha256sum -c /tmp/SHASUM) ]]; then
cd ${GITHUB_WORKSPACE}/depends
tar zxvf /tmp/raven-${OS}-dependencies.tar.gz
else
echo "SHASUM doesn't match"
exit 1
fi
cd depends
if [[ ${OS} == "windows" ]]; then
make HOST=x86_64-w64-mingw32 -j2
elif [[ ${OS} == "osx" ]]; then
echo "OSX building is not currently enabled"
exit 1
elif [[ ${OS} == "linux" || ${OS} == "linux-disable-wallet" ]]; then
make HOST=x86_64-linux-gnu -j2
elif [[ ${OS} == "arm32v7" || ${OS} == "arm32v7-disable-wallet" ]]; then
make HOST=arm-linux-gnueabihf -j2
elif [[ ${OS} == "aarch64" || ${OS} == "aarch64-disable-wallet" ]]; then
make HOST=aarch64-linux-gnu -j2
fi
7 changes: 3 additions & 4 deletions .github/workflows/build-raven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ env:
jobs:
check-jobs:
# continue-on-error: true # Uncomment once integration is finished
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
# Map a step output to a job output
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
Expand All @@ -52,11 +52,10 @@ jobs:

build:
needs: check-jobs
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
strategy:
matrix:
OS: [ 'windows', 'linux', 'linux-disable-wallet', 'arm32v7', 'arm32v7-disable-wallet', 'aarch64', 'aarch64-disable-wallet' ]
# OS: [ 'windows', 'linux', 'linux-disable-wallet', 'osx', 'arm32v7', 'arm32v7-disable-wallet' ]

steps:
- if: ${{ needs.check-jobs.outputs.should_skip != 'true' }}
Expand All @@ -69,7 +68,7 @@ jobs:

- if: ${{ needs.check-jobs.outputs.should_skip != 'true' }}
name: Cache dependencies.
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: |
${{ GITHUB.WORKSPACE }}/depends/built
Expand Down
51 changes: 0 additions & 51 deletions .github/workflows/dependencies-arm32v7.yml

This file was deleted.

51 changes: 0 additions & 51 deletions .github/workflows/dependencies-linux.yml

This file was deleted.

61 changes: 0 additions & 61 deletions .github/workflows/dependencies-osx.yml

This file was deleted.

54 changes: 0 additions & 54 deletions .github/workflows/dependencies-windows.yml

This file was deleted.

0 comments on commit 6d48ae0

Please sign in to comment.