Skip to content

Bump unsafe-libyaml from 0.2.8 to 0.2.10 in /codegen-v2 (#3620) #3

Bump unsafe-libyaml from 0.2.8 to 0.2.10 in /codegen-v2 (#3620)

Bump unsafe-libyaml from 0.2.8 to 0.2.10 in /codegen-v2 (#3620) #3

name: Linux SampleApps CI
on:
push:
branches: [ dev, master ]
pull_request:
branches: [ dev, master ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
steps:
# Work around https://github.com/actions/runner-images/issues/8659
- name: Remove GCC 13 from runner image
shell: bash
run: |
sudo rm -f /etc/apt/sources.list.d/ubuntu-toolchain-r-ubuntu-test-jammy.list
sudo apt-get update
sudo apt-get install -y --allow-downgrades libc6=2.35-0ubuntu3.5 libc6-dev=2.35-0ubuntu3.5 libstdc++6=12.3.0-1ubuntu1~22.04 libgcc-s1=12.3.0-1ubuntu1~22.04
- uses: actions/checkout@v3
- name: Install system dependencies
run: |
tools/install-sys-dependencies-linux
tools/install-rust-dependencies
- name: Cache internal dependencies
id: internal_cache
uses: actions/cache@v3
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Code generation
run: |
tools/generate-files native
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
- name: CMake
run: |
cmake -H. -Bbuild -DCMAKE_BUILD_TYPE=Debug -DTW_UNITY_BUILD=ON
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
- name: Build
run: |
make -Cbuild -j12 TrustWalletCore
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CK_TIMEOUT_MULTIPLIER: 4
- name: Build and run C++ sample app
run: |
cd samples/cpp
cmake . -DWALLET_CORE=../../ -DCMAKE_BUILD_TYPE=Debug
make
./sample
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
- name: Build, run, and test devconsole.ts
run: |
cd samples/typescript/devconsole.ts
npm install
npm run build
echo -e "help() \n .exit" | npm run start
npm run test
- name: Install Go
env:
GO_VERSION: 1.19
GO_ARCH: amd64
run: |
curl -O -L "https://golang.org/dl/go${GO_VERSION}.linux-${GO_ARCH}.tar.gz"
tar -xf "go${GO_VERSION}.linux-${GO_ARCH}.tar.gz"
sudo chown -R root:root ./go
sudo mv -v go /usr/local
- name: Build and run GoLang sample app
run: |
cd samples/go
go version
go build -o main
./main
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
- name: Build Golang dev console
run: |
cd samples/go/dev-console
./prepare.sh
cd cmd && go build -o ../tw_dev_console && cd -
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
- name: Build and run Rust sample app
run: |
cd samples/rust
rustc --version
cargo build
cargo run