Skip to content

Commit

Permalink
v1170
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonhilton87 committed Aug 1, 2024
1 parent 8b0e0c8 commit 7eba8ba
Show file tree
Hide file tree
Showing 53 changed files with 1,191 additions and 258 deletions.
40 changes: 20 additions & 20 deletions .github/workflows/c-cpp.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Continuous Integration
name: All Integration

on:
workflow_dispatch:
Expand Down Expand Up @@ -27,15 +27,15 @@ jobs:
PYTHON_DEBUG: "1"
WINEDEBUG: fixme-all
SDK_URL: https://bitcoincore.org/depends-sources/sdks
VERSION: "1.1.6.1"
VERSION: "1.1.7.0"


strategy:
fail-fast: false
matrix:
name:
- x86_64-linux
- x86_64-macos
#- x86_64-macos
- x86_64-win
- aarch64-linux
- armhf-linux
Expand Down Expand Up @@ -69,16 +69,16 @@ jobs:
goal: install
strip-cmd: "strip"

- name: x86_64-macos
host: x86_64-apple-darwin11
os: ubuntu-20.04
packages: cmake imagemagick libcap-dev librsvg2-bin libz-dev libtiff-tools libtinfo5 python3-setuptools xorriso libtinfo5
run-tests: false
dep-opts: ""
config-opts: "--enable-gui=qt5 --enable-reduce-exports"
goal: install
sdk: 10.11
strip-cmd: "x86_64-apple-darwin11-strip"
#- name: x86_64-macos
# host: x86_64-apple-darwin11
# os: ubuntu-20.04
# packages: cmake imagemagick libcap-dev librsvg2-bin libz-dev libtiff-tools libtinfo5 python3-setuptools xorriso libtinfo5
# run-tests: false
# dep-opts: ""
# config-opts: "--enable-gui=qt5 --enable-reduce-exports"
# goal: install
# sdk: 10.11
# strip-cmd: "x86_64-apple-darwin11-strip"

- name: x86_64-win
host: x86_64-w64-mingw32
Expand All @@ -96,7 +96,7 @@ jobs:
strip-cmd: "x86_64-w64-mingw32-strip"

runs-on: ${{ matrix.os }}

steps:
- name: Add architecture
if: ${{ matrix.arch }}
Expand All @@ -112,11 +112,11 @@ jobs:
run: ${{ matrix.postinstall }}

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: SDK cache
if: ${{ matrix.sdk }}
uses: actions/cache@v3
uses: actions/cache@v4
env:
cache-name: sdk
with:
Expand All @@ -131,7 +131,7 @@ jobs:
curl --location --fail $SDK_URL/MacOSX${{ matrix.sdk }}.sdk.tar.gz -o depends/sdk-sources/MacOSX${{ matrix.sdk }}.sdk.tar.gz
tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${{ matrix.sdk }}.sdk.tar.gz
- name: Dependency cache
uses: actions/cache@v3
uses: actions/cache@v4
env:
cache-name: depends
with:
Expand All @@ -142,7 +142,7 @@ jobs:
run: |
make $MAKEJOBS -C depends HOST=${{ matrix.host }} ${{ matrix.dep-opts }}
- name: CCache
uses: actions/cache@v3
uses: actions/cache@v4
env:
cache-name: ccache
with:
Expand Down Expand Up @@ -188,7 +188,7 @@ jobs:
matrix.name != 'x86_64-macos' &&
matrix.name != 'x86_64-win'
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4

with:
name: Pulsar-${{ env.VERSION }}-${{ matrix.name }}
Expand All @@ -200,7 +200,7 @@ jobs:
matrix.name == 'x86_64-macos' ||
matrix.name == 'x86_64-win'
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4

with:
name: Pulsar-${{ env.VERSION }}-${{ matrix.name }}
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Publish Release
on:
workflow_dispatch:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
build:
name: Upload Release Asset
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Build project # This would actually build your project, using zip for an example artifact
run: |
zip --junk-paths my-artifact README.md
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: "v1.1.7.x"
release_name: Release ${{ github.ref }}
draft: true
prerelease: false
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./my-artifact.zip
asset_name: my-artifact.zip
asset_content_type: application/zip
193 changes: 193 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
name: Windows Only TEST

on:
workflow_dispatch:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10


jobs:
build:
name: ${{ matrix.name }}

env:
MAKEJOBS: "-j20"
CHECK_DOC: "0"
CCACHE_SIZE: "100M"
CCACHE_TEMPDIR: /tmp/.ccache-temp
CCACHE_COMPRESS: "1"
PYTHON_DEBUG: "1"
WINEDEBUG: fixme-all
SDK_URL: https://bitcoincore.org/depends-sources/sdks
VERSION: "1.1.7.0"
RELEASE_NAME: "$GITHUB_WORKFLOW"
RELEASE_TAG: "v1.1.7.x"

strategy:
fail-fast: false
matrix:
name:
- x86_64-win

include:
- name: x86_64-win
host: x86_64-w64-mingw32
arch: "i386"
os: ubuntu-20.04
packages: python3 nsis g++-mingw-w64-x86-64 wine64 bc wine-binfmt
postinstall: |
sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix
sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
sudo update-binfmts --import /usr/share/binfmts/wine
run-tests: false
dep-opts: ""
config-opts: "--disable-shared --enable-gui=qt5"
goal: install
strip-cmd: "x86_64-w64-mingw32-strip"

runs-on: self-hosted

steps:
- name: Add architecture
if: ${{ matrix.arch }}
run: |
sudo dpkg --add-architecture "${{ matrix.arch }}"
- name: Install packages
run: |
sudo apt-get update
sudo apt-get install build-essential libtool autotools-dev automake pkg-config bsdmainutils curl ca-certificates ccache python3 rsync git procps bison
sudo apt-get install ${{ matrix.packages }}
- name: Post install
if: ${{ matrix.postinstall }}
run: ${{ matrix.postinstall }}

- name: Checkout
uses: actions/checkout@v4

- name: Cache SDK
uses: actions/cache@v4
with:
path: depends/sdk-sources
key: sdk-${{ runner.os }}-${{ matrix.name }}
restore-keys: sdk-${{ runner.os }}-
save-always: true

- name: Install SDK
if: ${{ matrix.sdk }}
run: |
mkdir -p depends/sdk-sources
mkdir -p depends/SDKs
curl --location --fail $SDK_URL/MacOSX${{ matrix.sdk }}.sdk.tar.gz -o depends/sdk-sources/MacOSX${{ matrix.sdk }}.sdk.tar.gz
tar -C depends/SDKs -xf depends/sdk-sources/MacOSX${{ matrix.sdk }}.sdk.tar.gz
- name: Cache Dependencies
uses: actions/cache@v4
with:
path: depends/built
key: dependencies-${{ runner.os }}-${{ matrix.name }}-${{ hashFiles('depends/packages/*') }}
restore-keys: dependencies-${{ runner.os }}-${{ matrix.name }}-
save-always: true

- name: Build depends
id: Build_Depends
run: |
make -C depends HOST=${{ matrix.host }} ${{ env.MAKEJOBS }} ${{ matrix.dep-opts }}
continue-on-error: true

- name: CCache
uses: actions/cache@v4
with:
path: ~/.ccache
key: ccache-${{ runner.os }}-${{ matrix.name }}-${{ hashFiles('**/configure.ac') }}
restore-keys: ccache-${{ runner.os }}-${{ matrix.name }}-

- name: Build Pulsar Core
run: |
./autogen.sh
./configure --prefix=`pwd`/depends/${{ matrix.host }} ${{ matrix.config-opts }} || ( cat config.log && false)
make ${{ env.MAKEJOBS }} ${{ matrix.goal }} || ( echo "Build failure. Verbose build follows." && make ${{ matrix.goal }} V=1 ; false )
- name: Strip built binaries
run: |
${{ matrix.strip-cmd }} depends/${{ matrix.host }}/bin/pulsard* src/qt/pulsar-qt* src/pulsar-cli* src/pulsar-tx* dist/Pulsar-Qt.app* || ( echo "Failed stripping builds. The build will have a bigger file size" )
- name: Move to release
run: |
mkdir release
cp depends/${{ matrix.host }}/bin/pulsard* release/
cp src/qt/pulsar-qt* release/
cp src/pulsar-cli* release/
cp src/pulsar-tx* release/
continue-on-error: true

- name: Upload artifacts WIN/OSX
if: |
matrix.name == 'x86_64-macos' ||
matrix.name == 'x86_64-win'
uses: actions/upload-artifact@v4
with:
name: Pulsar-${{ env.VERSION }}-${{ matrix.name }}
path: |
release/pulsard*
release/pulsar-qt
release/pulsar-qt.exe
release/pulsar-cli
release/pulsar-cli.exe
release/Pulsar-Qt.app
#TESTING

- name: Set enviroment for github-release
run: |
- name: Save state
run: echo "RELEASE_TAG=${{ env.RELEASE_TAG }}" >> $GITHUB_STATE
- name: Set output
run: echo "RELEASE_NAME={$GITHUB_WORKFLOW}" >> $GITHUB_OUTPUT
continue-on-error: true

- uses: meeDamian/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ env.RELEASE_TAG }}
name: ${{ env.RELEASE_TAG }}
body: >
testing.....
gzip: false
files: >
./release/Pulsar-${{ env.VERSION }}-${{ matrix.name }}.zip
continue-on-error: true



- name: Checkout code
uses: actions/checkout@v2
- name: Build project # This would actually build your project, using zip for an example artifact
run: |
zip --junk-paths my-artifact README.md
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ env.TAG_NAME }}
release_name: ${{ env.VERSION }}
draft: true
prerelease: false
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./my-artifact.zip
asset_name: my-artifact.zip
asset_content_type: application/zip

Loading

0 comments on commit 7eba8ba

Please sign in to comment.