diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..5b5c277 --- /dev/null +++ b/Makefile @@ -0,0 +1,41 @@ +#- +# This file is part of Tris Game. +# +# Tris Game is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# Tris Game is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Tris Game. If not, see <http://www.gnu.org/licenses/>. +# + +CC = gcc +PROG = tris + +LIBS = x11 opengl glx + +SRC_DIR = src/main +SRC != find ${SRC_DIR} -name *.c +OBJ = ${SRC:.c=.o} + +CFLAGS != pkg-config --cflags ${LIBS} +LFLAGS != pkg-config --libs ${LIBS} + +prova: + @echo ${LFLAGS} + +${PROG}: ${OBJ} + ${CC} ${OBJ} -o $@ ${LFLAGS} + +.c.o: + ${CC} ${CFLAGS} -c $< -o $@ + +clean: + rm -rf ${OBJ} + rm -f ${PROG} |