Some changes
- Move config.h to include/ - Move config.mk to root - Remove $RM from configurepull/1/head
parent
f2e33ad320
commit
f25cd3ca01
|
@ -1,3 +1,2 @@
|
||||||
obj/
|
obj/
|
||||||
game
|
game
|
||||||
config/
|
|
||||||
|
|
9
Makefile
9
Makefile
|
@ -1,11 +1,6 @@
|
||||||
include config/config.mk
|
include config.mk
|
||||||
|
|
||||||
OUT = game
|
INCLUDE = -Iinclude
|
||||||
CFLAGS =
|
|
||||||
LDFLAGS =
|
|
||||||
INCLUDE = -Iinclude -Iconfig
|
|
||||||
CC = cc
|
|
||||||
LD = ld
|
|
||||||
RM = rm -f
|
RM = rm -f
|
||||||
SRCDIR = src
|
SRCDIR = src
|
||||||
OBJDIR = obj
|
OBJDIR = obj
|
||||||
|
|
|
@ -14,7 +14,6 @@ then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CC=${CC:-cc}
|
CC=${CC:-cc}
|
||||||
RM=${RM:-rm -f}
|
|
||||||
CFLAGS=${CFLAGS:-}
|
CFLAGS=${CFLAGS:-}
|
||||||
LDFLAGS=${LDFLAGS:-}
|
LDFLAGS=${LDFLAGS:-}
|
||||||
OUT=${OUT:-game}
|
OUT=${OUT:-game}
|
||||||
|
@ -24,7 +23,6 @@ DEFY=${DEFY:-0}
|
||||||
|
|
||||||
echo "Makefile configuration:"
|
echo "Makefile configuration:"
|
||||||
echo "Compiler: $CC"
|
echo "Compiler: $CC"
|
||||||
echo "Remove: $RM"
|
|
||||||
echo "CFLAGS: $CFLAGS"
|
echo "CFLAGS: $CFLAGS"
|
||||||
echo "LDFLAGS: $LDFLAGS"
|
echo "LDFLAGS: $LDFLAGS"
|
||||||
echo "Out file: $OUT"
|
echo "Out file: $OUT"
|
||||||
|
@ -34,19 +32,11 @@ echo "Size: $SIZE"
|
||||||
echo "Start x: $DEFX"
|
echo "Start x: $DEFX"
|
||||||
echo "Start y: $DEFY"
|
echo "Start y: $DEFY"
|
||||||
|
|
||||||
if ! test -d config; then
|
|
||||||
if test -f config; then
|
|
||||||
rm config
|
|
||||||
fi
|
|
||||||
mkdir config
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "CC = $CC
|
echo "CC = $CC
|
||||||
RM = $RM
|
|
||||||
CFLAGS = $CFLAGS
|
CFLAGS = $CFLAGS
|
||||||
LDFLAGS = $LDFLAGS
|
LDFLAGS = $LDFLAGS
|
||||||
OUT = $OUT" > config/config.mk
|
OUT = $OUT" > config.mk
|
||||||
|
|
||||||
echo "#define SIZE $SIZE
|
echo "#define SIZE $SIZE
|
||||||
#define DEFX $DEFX
|
#define DEFX $DEFX
|
||||||
#define DEFY $DEFY" > config/config.h
|
#define DEFY $DEFY" > include/config.h
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
#define SIZE 10
|
||||||
|
#define DEFX 0
|
||||||
|
#define DEFY 0
|
Loading…
Reference in New Issue