aboutsummaryrefslogtreecommitdiffstats
path: root/com32/lib
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2010-02-23 22:32:32 -0800
committerH. Peter Anvin <hpa@zytor.com>2010-02-23 22:32:32 -0800
commite0e20f0ab948e372444c748ffbef65a30aafe4f8 (patch)
tree67820846d529a75107014bb4ee660cde70b2464d /com32/lib
parent1115737d431cf3b6a02faa90a0971bf91bef2370 (diff)
downloadsyslinux-e0e20f0ab948e372444c748ffbef65a30aafe4f8.tar.gz
syslinux-e0e20f0ab948e372444c748ffbef65a30aafe4f8.tar.xz
syslinux-e0e20f0ab948e372444c748ffbef65a30aafe4f8.zip
core: use better malloc; add low memory malloc; fix com32 exit
Use a better malloc for the core. In particular, use the same core that we should eventually be able to use for the entire system in Syslinux 5 -- with module awareness, etc. This code can also accommodate multiple heaps. Set up a separate heap for lowmem; the intent is to use explicit lowmem allocations instead of the static bounce buffer. The lowmem allocation is also exported via the pmapi mechanism, so modules can safely allocate lowmem. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'com32/lib')
-rw-r--r--com32/lib/Makefile28
1 files changed, 26 insertions, 2 deletions
diff --git a/com32/lib/Makefile b/com32/lib/Makefile
index 3e6aa810..87505792 100644
--- a/com32/lib/Makefile
+++ b/com32/lib/Makefile
@@ -31,7 +31,7 @@ LIBOBJS = \
\
opendir.o readdir.o closedir.o getcwd.o chdir.o fdopendir.o \
\
- libgcc/__ashldi3.o libgcc/__udivdi3.o \
+ libgcc/__ashldi3.o libgcc/__udivdi3.o \
libgcc/__negdi2.o libgcc/__ashrdi3.o libgcc/__lshrdi3.o \
libgcc/__muldi3.o libgcc/__udivmoddi4.o libgcc/__umoddi3.o \
libgcc/__divdi3.o libgcc/__moddi3.o \
@@ -118,6 +118,25 @@ LIBOBJS = \
syslinux/video/fontquery.o syslinux/video/forcetext.o \
syslinux/video/reportmode.o
+# These are the objects which are also imported into the core
+LIBCOREOBJS = \
+ memcpy.o mempcpy.o memset.o memcmp.o memmove.o \
+ strlen.o stpcpy.o strcpy.o strcmp.o strlcpy.o strlcat.o \
+ strchr.o strncmp.o strncpy.o \
+ \
+ snprintf.o sprintf.o vsnprintf.o \
+ \
+ dprintf.o vdprintf.o \
+ \
+ zalloc.o strdup.o \
+ \
+ sys/intcall.o sys/farcall.o sys/cfarcall.o sys/zeroregs.o \
+ \
+ libgcc/__ashldi3.o libgcc/__udivdi3.o \
+ libgcc/__negdi2.o libgcc/__ashrdi3.o libgcc/__lshrdi3.o \
+ libgcc/__muldi3.o libgcc/__udivmoddi4.o libgcc/__umoddi3.o \
+ libgcc/__divdi3.o libgcc/__moddi3.o
+
BINDIR = /usr/bin
LIBDIR = /usr/lib
DATADIR = /usr/share
@@ -125,13 +144,18 @@ AUXDIR = $(DATADIR)/syslinux
INCDIR = /usr/include
COM32DIR = $(AUXDIR)/com32
-all: libcom32.a
+all: libcom32.a libcomcore.a
libcom32.a : $(LIBOBJS)
rm -f $@
$(AR) cq $@ $^
$(RANLIB) $@
+libcomcore.a : $(LIBCOREOBJS)
+ rm -f $@
+ $(AR) cq $@ $^
+ $(RANLIB) $@
+
tidy dist clean:
rm -f sys/vesa/alphatbl.c
find . \( -name \*.o -o -name \*.a -o -name .\*.d -o -name \*.tmp \) -print0 | \