tiffread/compile

26 lines
634 B
Bash
Executable File

#!/bin/bash
CC=clang
CFLAGS="-g -Wall -Werror -pedantic -fsanitize=address -fsanitize=undefined"
INCLUDES="\
-I$(find ./src -type d | xargs -I{} echo -n "-I{} ") \
-Iintern/wizapp/aliases \
-Iintern/wizapp/cpath/include \
-Iintern/wizapp/dstr/include \
$(find intern/wizapp/mem/include -type d | xargs -I{} echo -n "-I{} ") \
$(pkg-config --cflags sdl2) \
"
LIBS="\
-lm \
$(pkg-config --libs sdl2) \
"
SRC="\
$(find ./src -name *.c | xargs -I{} echo -n "{} ") \
intern/wizapp/cpath/src/*.c \
intern/wizapp/dstr/src/*.c \
intern/wizapp/mem/src/*/*.c \
"
OUT=tiffread
( set -x ; $CC $CFLAGS $INCLUDES $LIBS $SRC -o $OUT )