1 gcc_ok
= $(shell if gcc
$(1) ..
/dummy.c
-o
/dev
/null
2>/dev
/null
; \
2 then echo
'$(1)'; else echo
'$(2)'; fi
)
5 LDHASH
:= $(call gcc_ok
,-Wl
$(comma
)--hash-style
=both
,)
10 CFLAGS
= -W
-Wall
-D_FILE_OFFSET_BITS
=64 $(OPTFLAGS
) $(INCLUDES
)
11 LDFLAGS
= $(LDHASH
) -s
13 SRCS
= syslinux.c ..
/syslxmod.c ..
/bootsect_bin.c ..
/ldlinux_bin.c
14 OBJS
= $(patsubst %.c
,%.o
,$(notdir $(SRCS
)))
16 .SUFFIXES
: .c .o .i .s .S
18 VPATH
= .
:..
:..
/libfat
23 -rm -f
*.o
*.i
*.s
*.a .
*.d
26 -rm -f syslinux syslinux-nomtools
31 installer
: syslinux syslinux-nomtools
34 $(CC
) $(LDFLAGS
) -o
$@
$^
36 syslinux-nomtools
: syslinux
40 $(CC
) -Wp
,-MT
,$@
,-MMD
,.
$@.d
$(CFLAGS
) -c
-o
$@
$<
42 $(CC
) $(CFLAGS
) -E
-o
$@
$<
44 $(CC
) $(CFLAGS
) -S
-o
$@
$<