Fix leaking file descriptors on error.
[kugel-rb.git] / rbutil / tools / Makefile
blobbaafdf84be01ccb0bbf8e5aeb1536d26a9db1ca0
1 CFLAGS=-Wall -W -D_LARGEFILE64_SOURCE
3 ifeq ($(findstring CYGWIN,$(shell uname)),CYGWIN)
4 CROSS=
5 CFLAGS+=-mno-cygwin
6 else
7 ifeq ($(findstring MINGW,$(shell uname)),MINGW)
8 CROSS=
9 else
10 CROSS=i586-mingw32msvc-
11 endif
12 endif
14 NATIVECC = gcc
15 CC = $(CROSS)gcc
16 WINDRES = $(CROSS)windres
19 all: bin2c
21 bin2c: bin2c.c
22 $(NATIVECC) $(CFLAGS) -o bin2c bin2c.c
24 clean:
25 $(RM) bin2c bin2c.exe