mirror of https://git.sr.ht/~rabbits/nasu
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
488 B
20 lines
488 B
#!/bin/bash |
|
|
|
# format code |
|
clang-format -i nasu.c |
|
|
|
# remove old |
|
rm ./nasu |
|
|
|
# debug(slow) |
|
# cc -std=c89 -DDEBUG -Wall -Wpedantic -Wshadow -Wextra -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Wvla -g -Og -fsanitize=address -fsanitize=undefined nasu.c -L/usr/local/lib -lSDL2 -o nasu |
|
|
|
# build(fast) |
|
cc nasu.c -std=c89 -Os -DNDEBUG -g0 -s -Wall -L/usr/local/lib -lSDL2 -o nasu |
|
|
|
# |
|
echo "Size: $(du -sk ./nasu)" |
|
|
|
# run |
|
./nasu example.chr |
|
# ./nasu example.bmp
|
|
|