dont include funct* in the Ins struct

This commit is contained in:
2026-03-08 21:56:04 +01:00
parent df7fc4ed63
commit bc29d79586
3 changed files with 128 additions and 119 deletions

View File

@@ -1,15 +1,23 @@
#!/bin/bash
COMMON="-g -Wall -Wextra -Wpedantic -Wno-unused-variable"
CFLAGS="-Wall -Wextra -Wpedantic"
if [[ -n "$RELEASE" ]]; then
CFLAGS="$CFLAGS -O3 -flto -march=native"
else
CFLAGS="$CFLAGS -g"
fi
echo "CFLAGS: $CFLAGS"
echo "building mos6502..."
cc $COMMON -std=c99 -o mos6502 mos6502.c
cc $CFLAGS -std=c99 -o mos6502 mos6502.c
if command -v pkg-config >/dev/null; then
RAYLIB_FLAGS=$(pkg-config --cflags --libs raylib 2>/dev/null)
if [ $? -eq 0 ]; then
echo "building chip8..."
cc $COMMON -std=c99 -o chip8 chip8.c $RAYLIB_FLAGS
cc $CFLAGS -std=c99 -o chip8 chip8.c $RAYLIB_FLAGS
else
echo "raylib not found - skipping chip8..."
fi
@@ -17,7 +25,7 @@ if command -v pkg-config >/dev/null; then
LIBELF_FLAGS=$(pkg-config --cflags --libs libelf 2>/dev/null)
if [ $? -eq 0 ]; then
echo "building riscv64..."
c++ -std=c++23 $COMMON -o riscv64 riscv64.cc $LIBELF_FLAGS
c++ -std=c++23 $CFLAGS -o riscv64 riscv64.cc $LIBELF_FLAGS
else
echo "libelf not found - skipping riscv64..."
fi