aboutsummaryrefslogtreecommitdiffstats
path: root/win32
diff options
context:
space:
mode:
authorhpa <hpa>2004-12-08 19:28:05 +0000
committerhpa <hpa>2004-12-08 19:28:05 +0000
commitf50d95261e755826351601373652fd3ec6c6abc0 (patch)
tree3cdc62f20de8c86a95d24fb24aeee2641a57e7f0 /win32
parent692199a1e10ef43582c4fec41c1e5f71b7b45187 (diff)
downloadsyslinux.git-f50d95261e755826351601373652fd3ec6c6abc0.tar.gz
syslinux.git-f50d95261e755826351601373652fd3ec6c6abc0.tar.xz
syslinux.git-f50d95261e755826351601373652fd3ec6c6abc0.zip
Be less hostile to building on a mingw-less system.
Diffstat (limited to 'win32')
-rw-r--r--win32/Makefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/win32/Makefile b/win32/Makefile
index fd890ec9..3106d6b7 100644
--- a/win32/Makefile
+++ b/win32/Makefile
@@ -36,6 +36,8 @@ CC = mingw-gcc
AR = mingw-ar
RANLIB = mingw-ranlib
endif
+CC_IS_GOOD := $(shell $(CC) $(CFLAGS) $(LDFLAGS) -o hello.exe hello.c >/dev/null 2>&1 ; echo $$?)
+
CFLAGS = -W -Wall -O2 -fomit-frame-pointer -D_FILE_OFFSET_BITS=64
PIC =
LDFLAGS = -O2 -s
@@ -52,7 +54,12 @@ VERSION = $(shell cat ../version)
.c.i:
$(CC) $(INCLUDE) $(CFLAGS) -E -o $@ $<
+ifeq ($(CC_IS_GOOD),0)
all: ../syslinux.exe
+else
+all: # We don't have a working win32 compiler
+ rm -f ../syslinux.exe
+endif
libsyslinux.a: bootsect_bin.o ldlinux_bin.o syslxmod.o
rm -f $@