2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
* conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf' with `kernel.img'. (kernel_elf_SOURCES): Rename to ... (kernel_img_SOURCES): ... this. (kernel_elf_HEADERS): Rename to ... (kernel_img_HEADERS): ... this. Update all users. (kernel_elf_ASFLAGS): Rename to ... (kernel_img_ASFLAGS): ... this. (kernel_elf_CFLAGS): Rename to ... (kernel_img_CFLAGS): ... this. (kernel_elf_LDFLAGS): Rename to ... (kernel_img_LDFLAGS): ... this. * conf/i386-coreboot.rmk: Likewise. * conf/powerpc-ieee1275.rmk: Likewise. * util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf" with "kernel.img".
This commit is contained in:
parent
c3cee41331
commit
bf3372349c
5 changed files with 47 additions and 27 deletions
20
ChangeLog
20
ChangeLog
|
@ -1,3 +1,23 @@
|
||||||
|
2009-06-22 Robert Millan <rmh.grub@aybabtu.com>
|
||||||
|
|
||||||
|
* conf/i386-ieee1275.rmk (pkglib_PROGRAMS): Replace `kernel.elf'
|
||||||
|
with `kernel.img'.
|
||||||
|
(kernel_elf_SOURCES): Rename to ...
|
||||||
|
(kernel_img_SOURCES): ... this.
|
||||||
|
(kernel_elf_HEADERS): Rename to ...
|
||||||
|
(kernel_img_HEADERS): ... this. Update all users.
|
||||||
|
(kernel_elf_ASFLAGS): Rename to ...
|
||||||
|
(kernel_img_ASFLAGS): ... this.
|
||||||
|
(kernel_elf_CFLAGS): Rename to ...
|
||||||
|
(kernel_img_CFLAGS): ... this.
|
||||||
|
(kernel_elf_LDFLAGS): Rename to ...
|
||||||
|
(kernel_img_LDFLAGS): ... this.
|
||||||
|
* conf/i386-coreboot.rmk: Likewise.
|
||||||
|
* conf/powerpc-ieee1275.rmk: Likewise.
|
||||||
|
|
||||||
|
* util/elf/grub-mkimage.c (add_segments): Replace "kernel.elf"
|
||||||
|
with "kernel.img".
|
||||||
|
|
||||||
2009-06-21 Pavel Roskin <proski@gnu.org>
|
2009-06-21 Pavel Roskin <proski@gnu.org>
|
||||||
|
|
||||||
* loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
|
* loader/powerpc/ieee1275/linux.c (offset_phdr): Fix prototypes
|
||||||
|
|
|
@ -8,10 +8,10 @@ COMMON_LDFLAGS = -m32 -nostdlib
|
||||||
script/sh/lexer.c_DEPENDENCIES = grub_script.tab.h
|
script/sh/lexer.c_DEPENDENCIES = grub_script.tab.h
|
||||||
|
|
||||||
# Images.
|
# Images.
|
||||||
pkglib_PROGRAMS = kernel.elf
|
pkglib_PROGRAMS = kernel.img
|
||||||
|
|
||||||
# For kernel.elf.
|
# For kernel.img.
|
||||||
kernel_elf_SOURCES = kern/i386/coreboot/startup.S \
|
kernel_img_SOURCES = kern/i386/coreboot/startup.S \
|
||||||
kern/i386/coreboot/init.c \
|
kern/i386/coreboot/init.c \
|
||||||
kern/i386/multiboot_mmap.c \
|
kern/i386/multiboot_mmap.c \
|
||||||
kern/main.c kern/device.c \
|
kern/main.c kern/device.c \
|
||||||
|
@ -26,22 +26,22 @@ kernel_elf_SOURCES = kern/i386/coreboot/startup.S \
|
||||||
kern/env.c \
|
kern/env.c \
|
||||||
term/i386/pc/vga_text.c term/i386/vga_common.c \
|
term/i386/pc/vga_text.c term/i386/vga_common.c \
|
||||||
symlist.c
|
symlist.c
|
||||||
kernel_elf_HEADERS = boot.h cache.h device.h disk.h dl.h elf.h elfload.h \
|
kernel_img_HEADERS = boot.h cache.h device.h disk.h dl.h elf.h elfload.h \
|
||||||
env.h err.h file.h fs.h kernel.h loader.h misc.h mm.h net.h parser.h \
|
env.h err.h file.h fs.h kernel.h loader.h misc.h mm.h net.h parser.h \
|
||||||
partition.h pc_partition.h reader.h symbol.h term.h time.h types.h \
|
partition.h pc_partition.h reader.h symbol.h term.h time.h types.h \
|
||||||
machine/boot.h machine/console.h machine/init.h \
|
machine/boot.h machine/console.h machine/init.h \
|
||||||
machine/memory.h machine/loader.h list.h handler.h command.h
|
machine/memory.h machine/loader.h list.h handler.h command.h
|
||||||
kernel_elf_CFLAGS = $(COMMON_CFLAGS)
|
kernel_img_CFLAGS = $(COMMON_CFLAGS)
|
||||||
kernel_elf_ASFLAGS = $(COMMON_ASFLAGS)
|
kernel_img_ASFLAGS = $(COMMON_ASFLAGS)
|
||||||
kernel_elf_LDFLAGS = $(COMMON_LDFLAGS) -Wl,-N,-S,-Ttext,0x8200,-Bstatic
|
kernel_img_LDFLAGS = $(COMMON_LDFLAGS) -Wl,-N,-S,-Ttext,0x8200,-Bstatic
|
||||||
|
|
||||||
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
||||||
DEFSYMFILES += kernel_syms.lst
|
DEFSYMFILES += kernel_syms.lst
|
||||||
|
|
||||||
symlist.c: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h gensymlist.sh
|
symlist.c: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h gensymlist.sh
|
||||||
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
kernel_syms.lst: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h genkernsyms.sh
|
kernel_syms.lst: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h genkernsyms.sh
|
||||||
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
# Utilities.
|
# Utilities.
|
||||||
|
|
|
@ -8,10 +8,10 @@ COMMON_LDFLAGS = -nostdlib
|
||||||
script/sh/lexer.c_DEPENDENCIES = grub_script.tab.h
|
script/sh/lexer.c_DEPENDENCIES = grub_script.tab.h
|
||||||
|
|
||||||
# Images.
|
# Images.
|
||||||
pkglib_PROGRAMS = kernel.elf
|
pkglib_PROGRAMS = kernel.img
|
||||||
|
|
||||||
# For kernel.elf.
|
# For kernel.img.
|
||||||
kernel_elf_SOURCES = kern/i386/ieee1275/startup.S kern/i386/ieee1275/init.c \
|
kernel_img_SOURCES = kern/i386/ieee1275/startup.S kern/i386/ieee1275/init.c \
|
||||||
kern/ieee1275/init.c \
|
kern/ieee1275/init.c \
|
||||||
kern/ieee1275/mmap.c \
|
kern/ieee1275/mmap.c \
|
||||||
kern/ieee1275/cmain.c kern/ieee1275/openfw.c \
|
kern/ieee1275/cmain.c kern/ieee1275/openfw.c \
|
||||||
|
@ -27,22 +27,22 @@ kernel_elf_SOURCES = kern/i386/ieee1275/startup.S kern/i386/ieee1275/init.c \
|
||||||
term/ieee1275/ofconsole.c \
|
term/ieee1275/ofconsole.c \
|
||||||
disk/ieee1275/ofdisk.c \
|
disk/ieee1275/ofdisk.c \
|
||||||
symlist.c
|
symlist.c
|
||||||
kernel_elf_HEADERS = cache.h device.h disk.h dl.h elf.h elfload.h \
|
kernel_img_HEADERS = cache.h device.h disk.h dl.h elf.h elfload.h \
|
||||||
env.h err.h file.h fs.h kernel.h loader.h misc.h mm.h net.h parser.h \
|
env.h err.h file.h fs.h kernel.h loader.h misc.h mm.h net.h parser.h \
|
||||||
partition.h pc_partition.h reader.h symbol.h term.h time.h types.h \
|
partition.h pc_partition.h reader.h symbol.h term.h time.h types.h \
|
||||||
ieee1275/ieee1275.h machine/kernel.h machine/loader.h machine/memory.h \
|
ieee1275/ieee1275.h machine/kernel.h machine/loader.h machine/memory.h \
|
||||||
list.h handler.h command.h
|
list.h handler.h command.h
|
||||||
kernel_elf_CFLAGS = $(COMMON_CFLAGS)
|
kernel_img_CFLAGS = $(COMMON_CFLAGS)
|
||||||
kernel_elf_ASFLAGS = $(COMMON_ASFLAGS)
|
kernel_img_ASFLAGS = $(COMMON_ASFLAGS)
|
||||||
kernel_elf_LDFLAGS = $(COMMON_LDFLAGS) -Wl,-N,-S,-Ttext,0x10000,-Bstatic
|
kernel_img_LDFLAGS = $(COMMON_LDFLAGS) -Wl,-N,-S,-Ttext,0x10000,-Bstatic
|
||||||
|
|
||||||
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
||||||
DEFSYMFILES += kernel_syms.lst
|
DEFSYMFILES += kernel_syms.lst
|
||||||
|
|
||||||
symlist.c: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h gensymlist.sh
|
symlist.c: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h gensymlist.sh
|
||||||
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
kernel_syms.lst: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h genkernsyms.sh
|
kernel_syms.lst: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h genkernsyms.sh
|
||||||
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
# Utilities.
|
# Utilities.
|
||||||
|
|
|
@ -13,20 +13,20 @@ script/sh/lexer.c_DEPENDENCIES = grub_script.tab.h
|
||||||
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
MOSTLYCLEANFILES += symlist.c kernel_syms.lst
|
||||||
DEFSYMFILES += kernel_syms.lst
|
DEFSYMFILES += kernel_syms.lst
|
||||||
|
|
||||||
kernel_elf_HEADERS = boot.h cache.h device.h disk.h dl.h elf.h elfload.h \
|
kernel_img_HEADERS = boot.h cache.h device.h disk.h dl.h elf.h elfload.h \
|
||||||
env.h err.h file.h fs.h kernel.h misc.h mm.h net.h parser.h reader.h \
|
env.h err.h file.h fs.h kernel.h misc.h mm.h net.h parser.h reader.h \
|
||||||
symbol.h term.h time.h types.h powerpc/libgcc.h loader.h partition.h \
|
symbol.h term.h time.h types.h powerpc/libgcc.h loader.h partition.h \
|
||||||
pc_partition.h ieee1275/ieee1275.h machine/kernel.h handler.h list.h \
|
pc_partition.h ieee1275/ieee1275.h machine/kernel.h handler.h list.h \
|
||||||
command.h
|
command.h
|
||||||
|
|
||||||
symlist.c: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h gensymlist.sh
|
symlist.c: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h gensymlist.sh
|
||||||
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh gensymlist.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
kernel_syms.lst: $(addprefix include/grub/,$(kernel_elf_HEADERS)) config.h genkernsyms.sh
|
kernel_syms.lst: $(addprefix include/grub/,$(kernel_img_HEADERS)) config.h genkernsyms.sh
|
||||||
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
/bin/sh genkernsyms.sh $(filter %.h,$^) > $@ || (rm -f $@; exit 1)
|
||||||
|
|
||||||
# Programs
|
# Programs
|
||||||
pkglib_PROGRAMS = kernel.elf
|
pkglib_PROGRAMS = kernel.img
|
||||||
|
|
||||||
# Utilities.
|
# Utilities.
|
||||||
sbin_UTILITIES = grub-mkdevicemap
|
sbin_UTILITIES = grub-mkdevicemap
|
||||||
|
@ -82,7 +82,7 @@ grub_emu_SOURCES = commands/minicmd.c commands/cat.c commands/cmp.c \
|
||||||
|
|
||||||
grub_emu_LDFLAGS = $(LIBCURSES)
|
grub_emu_LDFLAGS = $(LIBCURSES)
|
||||||
|
|
||||||
kernel_elf_SOURCES = kern/powerpc/ieee1275/startup.S kern/ieee1275/cmain.c \
|
kernel_img_SOURCES = kern/powerpc/ieee1275/startup.S kern/ieee1275/cmain.c \
|
||||||
kern/ieee1275/ieee1275.c kern/main.c kern/device.c \
|
kern/ieee1275/ieee1275.c kern/main.c kern/device.c \
|
||||||
kern/disk.c kern/dl.c kern/err.c kern/file.c kern/fs.c \
|
kern/disk.c kern/dl.c kern/err.c kern/file.c kern/fs.c \
|
||||||
kern/misc.c kern/mm.c kern/reader.c kern/term.c \
|
kern/misc.c kern/mm.c kern/reader.c kern/term.c \
|
||||||
|
@ -95,9 +95,9 @@ kernel_elf_SOURCES = kern/powerpc/ieee1275/startup.S kern/ieee1275/cmain.c \
|
||||||
kern/parser.c kern/partition.c kern/env.c kern/powerpc/dl.c \
|
kern/parser.c kern/partition.c kern/env.c kern/powerpc/dl.c \
|
||||||
kern/generic/millisleep.c kern/time.c \
|
kern/generic/millisleep.c kern/time.c \
|
||||||
symlist.c kern/powerpc/cache.S
|
symlist.c kern/powerpc/cache.S
|
||||||
kernel_elf_CFLAGS = $(COMMON_CFLAGS)
|
kernel_img_CFLAGS = $(COMMON_CFLAGS)
|
||||||
kernel_elf_ASFLAGS = $(COMMON_ASFLAGS)
|
kernel_img_ASFLAGS = $(COMMON_ASFLAGS)
|
||||||
kernel_elf_LDFLAGS = $(COMMON_LDFLAGS) -static-libgcc -lgcc \
|
kernel_img_LDFLAGS = $(COMMON_LDFLAGS) -static-libgcc -lgcc \
|
||||||
-Wl,-N,-S,-Ttext,0x200000,-Bstatic
|
-Wl,-N,-S,-Ttext,0x200000,-Bstatic
|
||||||
|
|
||||||
# Scripts.
|
# Scripts.
|
||||||
|
|
|
@ -193,7 +193,7 @@ add_segments (char *dir, char *prefix, FILE *out, int chrp, char *mods[], char *
|
||||||
int i, phdr_size;
|
int i, phdr_size;
|
||||||
|
|
||||||
/* Read ELF header. */
|
/* Read ELF header. */
|
||||||
kernel_path = grub_util_get_path (dir, "kernel.elf");
|
kernel_path = grub_util_get_path (dir, "kernel.img");
|
||||||
in = fopen (kernel_path, "rb");
|
in = fopen (kernel_path, "rb");
|
||||||
if (! in)
|
if (! in)
|
||||||
grub_util_error ("cannot open %s", kernel_path);
|
grub_util_error ("cannot open %s", kernel_path);
|
||||||
|
|
Loading…
Reference in a new issue