mirror of
https://github.com/vlang/v.git
synced 2025-09-13 14:32:26 +03:00
ci: update compile_v_with_vtcc.sh, enable its CI task again (#23063)
This commit is contained in:
parent
17f3c8f813
commit
b103ce354f
2 changed files with 12 additions and 13 deletions
19
.github/workflows/compile_v_with_vtcc.sh
vendored
19
.github/workflows/compile_v_with_vtcc.sh
vendored
|
@ -14,27 +14,26 @@ show "Clone vtcc"
|
|||
du -s vtcc/
|
||||
## TODO: just `./v vtcc`, later will cause V, to detect the compiler as tcc (which it is), and add `-fwrapv`, which causes the vtcc compiler to panic currently
|
||||
show "Compile vtcc"
|
||||
./v -o vtcc/xx vtcc/
|
||||
ls -la vtcc/xx
|
||||
./vtcc/xx --version
|
||||
cd vtcc/
|
||||
v run make.vsh
|
||||
cd ..
|
||||
|
||||
ls -la vtcc/vtcc
|
||||
./vtcc/vtcc --version
|
||||
|
||||
show "Generate the C file, for the current V version"
|
||||
./v -o vlang.c cmd/v
|
||||
ls -la vlang.c
|
||||
|
||||
show "Compile the C file with vtcc"
|
||||
export tcclib=thirdparty/tcc/lib/tcc
|
||||
export tccinc=$tcclib/include
|
||||
./vtcc/xx -o v_compiled_with_vtcc vlang.c -L$tcclib -I$tccinc -lc -ldl -pthread -ltcc1 $tcclib/bt-log.o
|
||||
./vtcc/vtcc -o v_compiled_with_vtcc vlang.c -lpthread
|
||||
ls -la v_compiled_with_vtcc
|
||||
|
||||
show "Test the resulting V compiler"
|
||||
./v_compiled_with_vtcc version
|
||||
./v_compiled_with_vtcc -showcc run examples/hello_world.v
|
||||
|
||||
## TODO: this step passes locally, but fails on the main CI:
|
||||
## show "Compile and run hello with vtcc"
|
||||
## ./v_compiled_with_vtcc -showcc -cc ./vtcc/xx run examples/hello_world.v
|
||||
show "Compile and run hello with vtcc"
|
||||
./v_compiled_with_vtcc -cc vtcc/vtcc -showcc run examples/hello_world.v
|
||||
|
||||
show "Remove the generated temporary files, so the script can be re-run cleanly"
|
||||
rm -rf v_compiled_with_vtcc vlang.c vtcc/
|
||||
|
|
|
@ -46,9 +46,9 @@ jobs:
|
|||
v retry brew install sassc libgit2
|
||||
fi
|
||||
|
||||
## - name: Test vtcc
|
||||
## if: runner.os == 'Linux'
|
||||
## run: .github/workflows/compile_v_with_vtcc.sh
|
||||
- name: Test vtcc
|
||||
if: runner.os == 'Linux'
|
||||
run: .github/workflows/compile_v_with_vtcc.sh
|
||||
|
||||
- name: Test vsql compilation and examples
|
||||
if: ${{ !cancelled() && steps.build.outcome == 'success' }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue