aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2012-03-12 19:40:33 +0000
committerMatt Fleming <matt.fleming@intel.com>2012-03-23 16:56:16 +0000
commit0105cae269ed2488a2a99f1548740ca99326cc4a (patch)
tree22a158442b43ff3a458f46e76b6d80b2c093837a
parent9f6b6b08feb709ba8af0571ffec0b008b5d255d9 (diff)
downloadsyslinux-0105cae269ed2488a2a99f1548740ca99326cc4a.tar.gz
syslinux-0105cae269ed2488a2a99f1548740ca99326cc4a.tar.xz
syslinux-0105cae269ed2488a2a99f1548740ca99326cc4a.zip
mk: Don't link against compiler's version of libgcc
Syslinux provides its own copy of libgcc functions in com32/lib/libgcc, so we don't need to link against the version provided by the compiler. What's worse, the behaviour is different between the two versions. This caused problems, for example, when parsing the TOTALTIMEOUT config directive in com32/menu because of the following calculation, totaltimeout = (atoll(skipspace(p + 13)) * CLK_TCK + 9) / 10; which invokes __divdi3() as provided by libgcc. The results returned by the Syslinux and compiler's copy of libgcc differ, leading to differences in behaviour. Signed-off-by: Matt Fleming <matt.fleming@intel.com>
-rw-r--r--mk/elf.mk3
1 files changed, 1 insertions, 2 deletions
diff --git a/mk/elf.mk b/mk/elf.mk
index 5a2ce2d9..ca061152 100644
--- a/mk/elf.mk
+++ b/mk/elf.mk
@@ -47,14 +47,13 @@ CFLAGS = $(GCCOPT) -W -Wall -march=i386 \
-I$(com32)/libutil/include -I$(com32)/include $(GPLINCLUDE)
SFLAGS = $(GCCOPT) -D__COM32__ -march=i386
LDFLAGS = -m elf_i386 -shared --hash-style=gnu -T $(com32)/lib/elf32.ld
-LIBGCC := $(shell $(CC) $(GCCOPT) --print-libgcc)
LNXCFLAGS = -I$(com32)/libutil/include -W -Wall -O -g -D_GNU_SOURCE
LNXSFLAGS = -g
LNXLDFLAGS = -g
C_LIBS = $(com32)/libutil/libutil_com.c32 $(GPLLIB) \
- $(com32)/lib/libcom32.c32 $(LIBGCC)
+ $(com32)/lib/libcom32.c32
C_LNXLIBS = $(com32)/libutil/libutil_lnx.a \
$(com32)/elflink/ldlinux/ldlinux_lnx.a