Skip to content

Commit 09c9450

Browse files
authored
Merge branch 'metacall:develop' into brew-ruby-CI-CD-fix
2 parents 0ee9bce + 8dcf690 commit 09c9450

File tree

1 file changed

+39
-3
lines changed

1 file changed

+39
-3
lines changed

.github/workflows/test.yml

Lines changed: 39 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
workflow_dispatch:
55
pull_request:
66

7+
env:
8+
METACALL_BASE_IMAGE: debian:bullseye-slim
9+
710
jobs:
811
linux-test:
912
name: Linux (Ubuntu) GCC Test
@@ -16,7 +19,22 @@ jobs:
1619

1720
# Revert the NodeJS version in order to use the system one instead (needed due to libnode)
1821
- name: Delete latest version of NodeJS
19-
run: yes | sudo n uninstall
22+
run: |
23+
yes | sudo n uninstall
24+
# Source: https://github.com/tj/n/issues/540#issuecomment-443844202
25+
sudo rm -f "/usr/local/bin/node"
26+
sudo rm -f "/usr/local/bin/npm"
27+
sudo rm -f "/usr/local/bin/npx"
28+
sudo rm -rf "/usr/local/include/node"
29+
sudo rm -rf "/usr/local/lib/dtrace/node.d"
30+
sudo rm -rf "/usr/local/lib/node_modules/npm"
31+
sudo rm -rf "/usr/local/share/doc/node"
32+
sudo rm -rf "/usr/local/share/man/man1/node.1"
33+
sudo rm -rf "/usr/local/share/systemtap/tapset/node.stp"
34+
# Creating a symbolic link to bypass path reference bug
35+
sudo ln -s /usr/bin/node /usr/local/bin/node
36+
sudo ln -s /usr/bin/npm /usr/local/bin/npm
37+
sudo ln -s /usr/bin/npx /usr/local/bin/npx
2038
2139
- name: Set up the environment
2240
run: sudo ./tools/metacall-environment.sh $METACALL_INSTALL_OPTIONS
@@ -27,7 +45,7 @@ jobs:
2745
LTTNG_UST_REGISTER_TIMEOUT: 0
2846
NUGET_XMLDOC_MODE: skip
2947
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'
30-
METACALL_INSTALL_OPTIONS: root base python ruby netcore5 nodejs typescript file rpc wasm java c cobol rapidjson funchook swig pack # clangformat v8rep51 coverage
48+
METACALL_INSTALL_OPTIONS: root base python ruby netcore5 nodejs typescript file rpc wasm java c cobol rust rapidjson funchook swig pack # clangformat v8rep51 coverage
3149

3250
- name: Run the configuration script
3351
run: |
@@ -43,7 +61,25 @@ jobs:
4361
sudo "$METACALL_PATH/tools/metacall-configure.sh" $METACALL_BUILD_OPTIONS
4462
env:
4563
METACALL_BUILD_TYPE: debug
46-
METACALL_BUILD_OPTIONS: root python ruby netcore5 nodejs typescript file rpc wasm java c cobol examples tests scripts ports dynamic install pack benchmarks # sanitizer v8 coverage
64+
METACALL_BUILD_OPTIONS: root python ruby netcore5 nodejs typescript file rpc wasm java c cobol rust examples tests scripts ports dynamic install pack benchmarks # sanitizer v8 coverage
65+
DEBIAN_FRONTEND: noninteractive
66+
NODE_PATH: /usr/lib/node_modules
67+
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'
68+
69+
- name: Build
70+
run: |
71+
export "METACALL_PATH=$(pwd)"
72+
export "LOADER_LIBRARY_PATH=$METACALL_PATH/build"
73+
export "LOADER_SCRIPT_PATH=$METACALL_PATH/build/scripts"
74+
export "CONFIGURATION_PATH=$METACALL_PATH/build/configurations/global.json"
75+
export "SERIAL_LIBRARY_PATH=$METACALL_PATH/build"
76+
export "DETOUR_LIBRARY_PATH=$METACALL_PATH/build"
77+
export "PORT_LIBRARY_PATH=$METACALL_PATH/build"
78+
cd "$METACALL_PATH/build"
79+
sudo "$METACALL_PATH/tools/metacall-build.sh" $METACALL_BUILD_OPTIONS
80+
env:
81+
METACALL_BUILD_TYPE: debug
82+
METACALL_BUILD_OPTIONS: root python ruby netcore5 nodejs typescript file rpc wasm java c cobol rust examples tests scripts ports dynamic install pack benchmarks # sanitizer v8 coverage
4783
DEBIAN_FRONTEND: noninteractive
4884
NODE_PATH: /usr/lib/node_modules
4985
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'

0 commit comments

Comments
 (0)