Add build scripts

This commit is contained in:
Abdelrahman Said 2023-11-03 22:47:26 +00:00
parent 26254cfd4e
commit ba1ac3e135
2 changed files with 12 additions and 0 deletions

3
build Normal file
View File

@ -0,0 +1,3 @@
#!/bin/bash
bear -- ./compile "$@"

9
compile Normal file
View File

@ -0,0 +1,9 @@
#!/bin/bash
CC=clang
AR=ar
CFLAGS="-c -fPIC -Wall -Werror -pedantic -O3 -Iinclude -Ic-cpp-aliases"
SRC="src/cpath.c"
OUT=libcpath.a
(set -x ; $CC $CFLAGS $SRC ; $AR -r $OUT *.o ; rm *.o)