mirror of
https://gitlab.com/dosowisko.net/libsuperderpy.git
synced 2025-02-08 06:06:43 +01:00
add makefile
This commit is contained in:
parent
4a3160b3b8
commit
b19476aa44
4 changed files with 24 additions and 2 deletions
21
Makefile
Normal file
21
Makefile
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
IDIR =.
|
||||||
|
CC=gcc
|
||||||
|
CFLAGS=-I$(IDIR) -std=gnu99 -Wall -DDEBUG -g
|
||||||
|
|
||||||
|
SRCDIR=src
|
||||||
|
ODIR=obj
|
||||||
|
LIBS=-lallegro -lallegro_audio-debug -lallegro_acodec-debug -lallegro_image-debug -lallegro_font-debug -lallegro_ttf-debug -lm
|
||||||
|
|
||||||
|
_OBJ = main.o about.o intro.o loading.o map.o menu.o
|
||||||
|
OBJ = $(patsubst %,$(ODIR)/%,$(_OBJ))
|
||||||
|
|
||||||
|
$(ODIR)/%.o: $(SRCDIR)/%.c
|
||||||
|
$(CC) -c -o $@ $< $(CFLAGS)
|
||||||
|
|
||||||
|
bin/superderpy: $(OBJ)
|
||||||
|
gcc -o $@ $^ $(CFLAGS) $(LIBS)
|
||||||
|
|
||||||
|
.PHONY: clean
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -f $(ODIR)/*.o *~ allegro.log $(SRCDIR)/*~
|
2
build
Executable file
2
build
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/bin/sh
|
||||||
|
make && bin/superderpy
|
2
make
2
make
|
@ -1,2 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
gcc src/loading.c src/main.c src/menu.c src/about.c src/intro.c src/map.c -o bin/superderpy -lallegro -lallegro_audio-debug -lallegro_acodec-debug -lallegro_image-debug -lallegro_font-debug -lallegro_ttf-debug -DDEBUG -std=gnu99 -g -Wall && ./bin/superderpy
|
|
1
obj/.gitignore
vendored
Normal file
1
obj/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
||||||
|
*.o
|
Loading…
Reference in a new issue