-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6b09c39
commit 4ef3b65
Showing
8 changed files
with
111 additions
and
66 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,18 +28,28 @@ jobs: | |
fetch-depth: 5 | ||
- name: Nightly default | ||
run: rustup default nightly | ||
- name: Prepare vcpkg | ||
if: runner.os != 'Windows' | ||
uses: friendlyanon/setup-vcpkg@v1 | ||
with: { committish: 51b14cd4e1230dd51c11ffeff6f7d53c61cc5297 } | ||
- uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: | | ||
/home/runner/.hunter | ||
/Users/runner/.hunter/ | ||
/home/runner/vcpkg | ||
/Users/runner/vcpkg/ | ||
ccache | ||
key: hunter-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
deps/ | ||
c:/vcpkg | ||
!c:/vcpkg/.git | ||
!c:/vcpkg/buildtrees | ||
!c:/vcpkg/packages | ||
!c:/vcpkg/downloads | ||
key: vcpkg-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
restore-keys: | | ||
hunter-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
hunter-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
hunter-clang-v3-notest-${{ runner.temp }}- | ||
vcpkg-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
vcpkg-clang-v3-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
vcpkg-clang-v3-notest-${{ runner.temp }}- | ||
- name: install macOS dependencies | ||
if: runner.os == 'macOS' | ||
run: brew install ccache | ||
|
@@ -48,10 +58,10 @@ jobs: | |
run: sudo apt install -y git curl openssl build-essential clang cmake ccache | ||
- name: configure | ||
if: runner.os == 'macOS' | ||
run: export SDKROOT=$(xcrun --sdk macosx --show-sdk-path) && CC=/usr/bin/clang CXX=/usr/bin/clang++ mkdir build && cd build && cmake ../ -DTESTS=ON | ||
run: export SDKROOT=$(xcrun --sdk macosx --show-sdk-path) && CC=/usr/bin/clang CXX=/usr/bin/clang++ mkdir build && cd build && cmake ../ -DTESTS=ON -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake | ||
- name: configure | ||
if: runner.os == 'Linux' | ||
run: CC=/usr/bin/clang CXX=/usr/bin/clang++ mkdir build && cd build && cmake ../ | ||
run: CC=/usr/bin/clang CXX=/usr/bin/clang++ mkdir build && cd build && cmake -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake ../ | ||
- name: compile | ||
run: cd build && make -j2 | ||
# - name: run test | ||
|
@@ -66,15 +76,28 @@ jobs: | |
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 5 | ||
- name: Prepare vcpkg | ||
if: runner.os != 'Windows' | ||
uses: friendlyanon/setup-vcpkg@v1 | ||
with: { committish: 51b14cd4e1230dd51c11ffeff6f7d53c61cc5297 } | ||
- uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: /home/runner/.hunter | ||
key: hunter-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
path: | | ||
/home/runner/vcpkg | ||
/Users/runner/vcpkg/ | ||
ccache | ||
deps/ | ||
c:/vcpkg | ||
!c:/vcpkg/.git | ||
!c:/vcpkg/buildtrees | ||
!c:/vcpkg/packages | ||
!c:/vcpkg/downloads | ||
key: vcpkg-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
restore-keys: | | ||
hunter-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
hunter-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
hunter-gcc-v2-notest-${{ runner.temp }}- | ||
vcpkg-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
vcpkg-gcc-v2-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
vcpkg-gcc-v2-notest-${{ runner.temp }}- | ||
- uses: actions/cache@v2 | ||
id: ccache | ||
with: | ||
|
@@ -87,7 +110,7 @@ jobs: | |
- name: install Ubuntu dependencies | ||
run: sudo apt install -y git curl openssl build-essential cmake ccache | ||
- name: configure | ||
run: mkdir -p build && cd build && cmake ../ | ||
run: mkdir -p build && cd build && cmake -DCMAKE_TOOLCHAIN_FILE=${{ env.VCPKG_ROOT }}/scripts/buildsystems/vcpkg.cmake ../ | ||
- name: compile | ||
run: cd build && make -j4 | ||
# - name: run test | ||
|
@@ -98,45 +121,67 @@ jobs: | |
container: | ||
image: docker.io/centos:7 | ||
volumes: | ||
- /github/home/.hunter:/github/home/.hunter | ||
- /github/home/vcpkg:/github/home/vcpkg | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 5 | ||
- name: install rust language | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: nightly-2021-06-17 | ||
override: true | ||
- uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: | | ||
/home/runner/.hunter | ||
/github/home/.hunter | ||
/home/runner/.hunter/_Base/Download/ | ||
/github/home/.hunter/_Base/Download/ | ||
deps/src | ||
ccache | ||
key: hunter-centos-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
restore-keys: | | ||
hunter-centos-v2-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
hunter-centos-v2-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
hunter-centos-v2-notest-${{ runner.temp }}- | ||
- name: install CentOS dependencies | ||
- name: pre-push | ||
run: | | ||
# Sigh. | ||
sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/*.repo | ||
sed -i s/mirrorlist.centos.org/vault.centos.org/g /etc/yum.repos.d/*.repo | ||
sed -i s/^#.*baseurl=http/baseurl=http/g /etc/yum.repos.d/*.repo | ||
sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/*.repo | ||
# Avoid https://github.com/actions/checkout/issues/1590 | ||
curl -L -o bcos-boostssl.tar.gz https://github.com/${GITHUB_REPOSITORY}/archive/${GITHUB_SHA}.tar.gz | ||
tar xvf bcos-boostssl.tar.gz | ||
cd bcos-boostssl-${GITHUB_SHA} | ||
yum install -y -q epel-release centos-release-scl flex bison patch glibc-static glibc-devel libzstd-devel | ||
yum install -y -q devtoolset-11 llvm-toolset-7.0 rh-perl530-perl cmake3 zlib-devel ccache python-devel python3-devel python3-pip automake openssl | ||
yum reinstall -y -q https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm | ||
yum install -y -q git | ||
- name: configure | ||
run: | | ||
source /opt/rh/devtoolset-7/enable | ||
mkdir -p build && cd build | ||
cmake3 ../ -DHUNTER_STATUS_DEBUG=ON | ||
cmake3 ../ | ||
- name: compile | ||
run: | | ||
source /opt/rh/devtoolset-7/enable | ||
mkdir -p build && cd build | ||
make -j4 | ||
build_with_windows: | ||
name: build_with_windows | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [windows-2019] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 5 | ||
- uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: | | ||
/home/runner/vcpkg | ||
/github/home/vcpkg | ||
/Users/runner/vcpkg | ||
/home/runner/vcpkg/_Base/Download/ | ||
/github/home/vcpkg/_Base/Download/ | ||
/Users/runner/vcpkg/_Base/Download/ | ||
C:/vcpkg/ | ||
C:/vcpkg/_Base/Download/ | ||
ccache | ||
key: vcpkg-msvc-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
restore-keys: | | ||
vcpkg-msvc-v3-notest-${{ runner.temp }}-${{ github.base_ref }}-${{ hashFiles('.github/workflows/workflow.yml') }} | ||
vcpkg-msvc-v3-notest-${{ runner.temp }}-${{ github.base_ref }}- | ||
vcpkg-msvc-v3-notest-${{ runner.temp }}- | ||
- name: Add MSbuild to PATH | ||
uses: microsoft/[email protected] | ||
- name: configure | ||
if: runner.os == 'Windows' | ||
run: mkdir -p build && cd build && cmake -G "Visual Studio 16 2019" -A x64 -DVCPKG_TARGET_TRIPLET=x64-windows-static -DCMAKE_TOOLCHAIN_FILE=c:/vcpkg/scripts/buildsystems/vcpkg.cmake ../ | ||
- name: compile | ||
run: | ||
cd build && MSBuild /version && MSBuild bcos-boostssl.sln /p:Configuration=Release /p:Platform=x64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters