add github.com/status-im/nim-leopard to vendor (#61)
* [leopard] add github.com/status-im/nim-leopard to vendor * [leopard] specify absolute path for nimcache dir * [leopard] make adjustments to nim-dagger CI GHA workflow
This commit is contained in:
parent
43cea1743a
commit
1e5b41a447
|
@ -7,7 +7,6 @@ jobs:
|
|||
fail-fast: false
|
||||
max-parallel: 20
|
||||
matrix:
|
||||
branch: [v1.4.6]
|
||||
target:
|
||||
# Unit tests
|
||||
- os: linux
|
||||
|
@ -35,7 +34,7 @@ jobs:
|
|||
- target:
|
||||
os: windows
|
||||
builder: windows-2019
|
||||
name: '${{ matrix.target.os }}-${{ matrix.target.cpu }} (${{ matrix.branch }})'
|
||||
name: '${{ matrix.target.os }}-${{ matrix.target.cpu }}'
|
||||
runs-on: ${{ matrix.builder }}
|
||||
steps:
|
||||
- name: Checkout nim-dagger
|
||||
|
@ -93,6 +92,25 @@ jobs:
|
|||
EOF
|
||||
chmod 755 external/bin/gcc external/bin/g++
|
||||
echo '${{ github.workspace }}/external/bin' >> $GITHUB_PATH
|
||||
NIMFLAGS="-d:LeopardCmakeFlags='-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS=-m32 -DCMAKE_CXX_FLAGS=-m32'"
|
||||
quote () {
|
||||
local quoted=${1//\'/\'\\\'\'};
|
||||
printf "'%s'" "$quoted"
|
||||
}
|
||||
echo "NIMFLAGS=$(quote "${NIMFLAGS}")" >> $GITHUB_ENV
|
||||
|
||||
- name: Install build dependencies (macOS)
|
||||
if: runner.os == 'macOS'
|
||||
run: |
|
||||
brew install libomp
|
||||
echo "$(brew --prefix)/opt/llvm/bin" >> $GITHUB_PATH
|
||||
echo "LDFLAGS=-L$(brew --prefix)/opt/libomp/lib -L$(brew --prefix)/opt/llvm/lib -Wl,-rpath,$(brew --prefix)/opt/llvm/lib" >> $GITHUB_ENV
|
||||
NIMFLAGS="-d:LeopardCmakeFlags='-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=$(brew --prefix)/opt/llvm/bin/clang -DCMAKE_CXX_COMPILER=$(brew --prefix)/opt/llvm/bin/clang++' -d:LeopardExtraCompilerlags='-fopenmp' -d:LeopardExtraLinkerFlags='-fopenmp -L$(brew --prefix)/opt/libomp/lib'"
|
||||
quote () {
|
||||
local quoted=${1//\'/\'\\\'\'};
|
||||
printf "'%s'" "$quoted"
|
||||
}
|
||||
echo "NIMFLAGS=$(quote "${NIMFLAGS}")" >> $GITHUB_ENV
|
||||
|
||||
- name: Restore MinGW-W64 (Windows) from cache
|
||||
if: runner.os == 'Windows'
|
||||
|
@ -186,3 +204,12 @@ jobs:
|
|||
working-directory: nim-dagger
|
||||
run: |
|
||||
make testAll
|
||||
if [[ ${{ runner.os }} = macOS ]]; then
|
||||
echo
|
||||
echo otool -L build/testDagger
|
||||
otool -L build/testDagger
|
||||
else
|
||||
echo
|
||||
echo ldd build/testDagger
|
||||
ldd build/testDagger
|
||||
fi
|
||||
|
|
|
@ -175,3 +175,6 @@
|
|||
url = https://github.com/status-im/nim-taskpools.git
|
||||
ignore = untracked
|
||||
branch = master
|
||||
[submodule "vendor/nim-leopard"]
|
||||
path = vendor/nim-leopard
|
||||
url = https://github.com/status-im/nim-leopard.git
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
import std/os
|
||||
|
||||
if defined(release):
|
||||
switch("nimcache", "nimcache/release/$projectName")
|
||||
switch("nimcache", joinPath(currentSourcePath.parentDir, "nimcache/release/$projectName"))
|
||||
else:
|
||||
switch("nimcache", "nimcache/debug/$projectName")
|
||||
switch("nimcache", joinPath(currentSourcePath.parentDir, "nimcache/debug/$projectName"))
|
||||
|
||||
if defined(windows):
|
||||
# disable timestamps in Windows PE headers - https://wiki.debian.org/ReproducibleBuilds/TimestampsInPEBinaries
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 41cd86df5bfa67afe7d3660e8ab0878133c8600e
|
Loading…
Reference in New Issue