diff options
author | Matt Fleming <matt.fleming@linux.intel.com> | 2011-04-26 09:59:53 +0100 |
---|---|---|
committer | Matt Fleming <matt.fleming@linux.intel.com> | 2011-04-26 10:04:59 +0100 |
commit | 74518b8b691c8aba1425673864c45b7721d9a738 (patch) | |
tree | 2b0d26c3617cabfd1c5e60bc046fd872014def4a /com32/elflink/modules/Makefile | |
parent | 8f10ba6d251ac05b54f183cb98bf5310a0675338 (diff) | |
download | syslinux-74518b8b691c8aba1425673864c45b7721d9a738.tar.gz syslinux-74518b8b691c8aba1425673864c45b7721d9a738.tar.xz syslinux-74518b8b691c8aba1425673864c45b7721d9a738.zip |
elflink: Make ELF the default object format
com32/elflink/modules was originally created to house ELF modules and
keep them separate from the COM32 modules as the elflink branch was
being developed. However, this has inadvertently created a maintenance
nightmare because code was copied from elsewhere in the tree into
com32/elflink/modules, resulting in duplication. Bug fixes have been
going into the original code but have not been merged onto the elflink
branch, leaving the duplicate code in com32/elflink/modules buggy.
So let's delete this directory. There really is no reason to keep ELF
and COM32 modules separate because there's no reason to need both
COM32 and ELF modules to coexist. ELF is a far superior object file
format and all modules are not emitted as ELF objects.
Now that we're outputting ELF modules we can use dynamic memory
instead of the cs_bounce bounce buffer.
This commit requires a certain amount of shuffling for some
files. quicksort.c isn't a module and belongs as part of the util
library. cli.h belongs in com32/include so that other modules can make
use of the cli code in ldlinux.c32.
All libraries are now ELF shared libraries which are only loaded to
fixup unresolved symbols for executable modules and renamed from *.a
to *.c32. This reduces the runtime memory footprint because libraries
are only loaded when needed and because every executable no longer
gets its own copy of code/data (as it would if linking with a static
library). Also, remove MINLIBOBJS from libcom32.c32 because it is
already part of libcom32min.a and we don't want to have any duplicate
symbols between the core (which links with libcom32min.a) and
libcom32.c32.
Welcome to the New World Order of ELF modules!
Signed-off-by: Matt Fleming <matt.fleming@linux.intel.com>
Diffstat (limited to 'com32/elflink/modules/Makefile')
-rw-r--r-- | com32/elflink/modules/Makefile | 103 |
1 files changed, 0 insertions, 103 deletions
diff --git a/com32/elflink/modules/Makefile b/com32/elflink/modules/Makefile deleted file mode 100644 index 8a274aef..00000000 --- a/com32/elflink/modules/Makefile +++ /dev/null @@ -1,103 +0,0 @@ -## ----------------------------------------------------------------------- -## -## Copyright 2001-2008 H. Peter Anvin - All Rights Reserved -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation, Inc., 53 Temple Place Ste 330, -## Boston MA 02111-1307, USA; either version 2 of the License, or -## (at your option) any later version; incorporated herein by reference. -## -## ----------------------------------------------------------------------- - -topdir = ../../.. -MAKEDIR = $(topdir)/mk -include $(MAKEDIR)/elf.mk - -CFLAGS += -I$(topdir)/core/elflink - -MODULES = hello.c32 sort.c32 mytest.c32 menumain.c32 printmsg.c32 background.c32 passwd.c32 sha1hash.c32 \ - unbase64.c32 sha512crypt.c32 md5.c32 crypt-md5.c32 sha256crypt.c32 get_key.c32 ansiraw.c32 test.c32 \ - meminfo.c32 menu.c32 drain.c32 vesainfo.c32 - -TESTFILES = - -all: $(MODULES) $(TESTFILES) - -test.c32 : test.o - $(LD) $(LDFLAGS) -o $@ $^ - -menu.c32 : menu.o - $(LD) $(LDFLAGS) -o $@ $^ - -hello.c32 : hello.o - $(LD) $(LDFLAGS) -o $@ $^ - -sort.c32 : sort.o - $(LD) $(LDFLAGS) -o $@ $^ - -mytest.c32 : mytest.o - $(LD) $(LDFLAGS) -o $@ $^ - -menumain.c32 : menumain.o - $(LD) $(LDFLAGS) -o $@ $^ - -printmsg.c32 : printmsg.o - $(LD) $(LDFLAGS) -o $@ $^ - -background.c32 : background.o - $(LD) $(LDFLAGS) -o $@ $^ - -drain.c32 : drain.o - $(LD) $(LDFLAGS) -o $@ $^ - -passwd.c32 : passwd.o - $(LD) $(LDFLAGS) -o $@ $^ - -sha1hash.c32 : sha1hash.o - $(LD) $(LDFLAGS) -o $@ $^ - -unbase64.c32 : unbase64.o - $(LD) $(LDFLAGS) -o $@ $^ - -sha512crypt.c32 : sha512crypt.o - $(LD) $(LDFLAGS) -o $@ $^ - -sha256crypt.c32 : sha256crypt.o - $(LD) $(LDFLAGS) -o $@ $^ - -md5.c32 : md5.o - $(LD) $(LDFLAGS) -o $@ $^ - -crypt-md5.c32 : crypt-md5.o - $(LD) $(LDFLAGS) -o $@ $^ - -get_key.c32 : get_key.o - $(LD) $(LDFLAGS) -o $@ $^ - -ansiraw.c32 : ansiraw.o - $(LD) $(LDFLAGS) -o $@ $^ - -meminfo.c32 : meminfo.o - $(LD) $(LDFLAGS) -o $@ $^ - -pcitest.c32 : pcitest.o - $(LD) $(LDFLAGS) -o $@ $^ - -vesainfo.c32 : vesainfo.o - $(LD) $(LDFLAGS) -o $@ $^ - -tidy dist: - rm -f *.o *.lo *.a *.lst .*.d - -clean: tidy - rm -f *.lss *.lnx *.com *.c32 - -spotless: clean - rm -f *~ \#* - -install: all - mkdir -m 755 -p $(INSTALLROOT)$(AUXDIR) - install -m 644 $(MODULES) $(INSTALLROOT)$(AUXDIR) - --include .*.d |