Replace shell script with makefile

Signed-off-by: Slendi <slendi@socopon.com>
This commit is contained in:
Slendi 2024-04-19 01:32:09 +03:00
parent 24967b3eb7
commit 464532d9fe
2 changed files with 6 additions and 9 deletions

6
Makefile Normal file
View File

@ -0,0 +1,6 @@
LLVMC=llvm-config
LLVM_LINKER=-lc++ $(shell ${LLVMC} --libs core --cxxflags --ldflags --system-libs|tr '\n' ' ')
all:
odin run src -o:none -debug -out:speedcat -extra-linker-flags:"${LLVM_LINKER}" -- pong.cat && \
clang -I/opt/local/include -L/opt/local/lib -lraylib -lm -framework Cocoa -framework OpenGL -framework IOKit pong.ll -o raylib

View File

@ -1,9 +0,0 @@
#!/bin/sh
set -xe
LLVMC=llvm-config
LLVM_LINKER="-lc++ $($LLVMC --libs core --cxxflags --ldflags --system-libs|tr '\n' ' ')"
odin run src -o:none -debug -out:speedcat -extra-linker-flags:"$LLVM_LINKER" -- pong.cat
clang -I/opt/local/include -L/opt/local/lib -lraylib -lm -framework Cocoa -framework OpenGL -framework IOKit pong.ll -o raylib