Skip to content

kern: Misc build system upgrades #605

kern: Misc build system upgrades

kern: Misc build system upgrades #605

Workflow file for this run

name: Build Vinix kernel
on:
pull_request:
paths-ignore:
- "**.md"
push:
branches:
- main
paths-ignore:
- "**.md"
jobs:
vinix-build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install build-essential -y
- name: Clone and build current V
run: git clone https://github.com/vlang/v.git --depth=1 && cd v && make
- name: Download kernel dependencies
run: cd kernel && ./get-deps
- name: Attempt to build the Vinix kernel (debug)
run: |
set -e
cd kernel
make PROD=false \
CFLAGS="-Ulinux -U__linux -U__linux__ -U__gnu_linux__ -D__vinix__ -O2 -g -pipe" \
V="$(realpath ../v/v)"
make clean
- name: Attempt to build the Vinix kernel (prod)
run: |
set -e
cd kernel
make PROD=true \
CFLAGS="-Ulinux -U__linux -U__linux__ -U__gnu_linux__ -D__vinix__ -O2 -g -pipe" \
V="$(realpath ../v/v)"
make clean
- name: Attempt to build the util-vinix (debug)
run: |
set -e
cd util-vinix
make PROD=false \
VFLAGS="-os vinix -gc none" \
CFLAGS="-Ulinux -U__linux -U__linux__ -U__gnu_linux__ -D__vinix__ -O2 -g -pipe" \
V="$(realpath ../v/v)"
make clean
- name: Attempt to build the util-vinix (prod)
run: |
set -e
cd util-vinix
make PROD=true \
VFLAGS="-os vinix -gc none" \
CFLAGS="-Ulinux -U__linux -U__linux__ -U__gnu_linux__ -D__vinix__ -O2 -g -pipe" \
V="$(realpath ../v/v)"
make clean