8514a1e003
* boot/powerpc/ieee1275/crt0.S (_start): Don't set up the stack. * conf/powerpc-ieee1275.rmk (grub_emu_SOURCE): Remove `kern/powerpc/cache.S'.
1389 lines
61 KiB
Makefile
1389 lines
61 KiB
Makefile
|
|
# -*- makefile -*-
|
|
|
|
COMMON_ASFLAGS = -nostdinc -D__ASSEMBLY__
|
|
COMMON_CFLAGS = -ffreestanding -msoft-float
|
|
|
|
# Images.
|
|
|
|
MOSTLYCLEANFILES += grubof_symlist.c kernel_syms.lst
|
|
DEFSYMFILES += kernel_syms.lst
|
|
|
|
grubof_HEADERS = arg.h boot.h device.h disk.h dl.h elf.h env.h err.h \
|
|
file.h fs.h kernel.h misc.h mm.h net.h rescue.h symbol.h \
|
|
term.h types.h machine/biosdisk.h powerpc/libgcc.h loader.h \
|
|
partition.h pc_partition.h machine/time.h machine/ieee1275.h
|
|
|
|
grubof_symlist.c: $(addprefix include/grub/,$(grubof_HEADERS)) gensymlist.sh
|
|
sh $(srcdir)/gensymlist.sh $(filter %.h,$^) > $@
|
|
|
|
kernel_syms.lst: $(addprefix include/grub/,$(grubof_HEADERS)) genkernsyms.sh
|
|
sh $(srcdir)/genkernsyms.sh $(filter %h,$^) > $@
|
|
|
|
# Programs
|
|
pkgdata_PROGRAMS = grubof
|
|
|
|
# Utilities.
|
|
bin_UTILITIES = grub-emu
|
|
noinst_UTILITIES = genmoddep
|
|
|
|
# For grub-emu
|
|
grub_emu_SOURCES = kern/main.c kern/device.c \
|
|
kern/disk.c kern/dl.c kern/file.c kern/fs.c kern/err.c \
|
|
kern/misc.c kern/loader.c kern/rescue.c kern/term.c \
|
|
partmap/amiga.c partmap/pc.c partmap/apple.c fs/fshelp.c \
|
|
util/i386/pc/biosdisk.c fs/fat.c fs/ext2.c fs/ufs.c fs/minix.c fs/hfs.c \
|
|
fs/jfs.c fs/iso9660.c \
|
|
normal/cmdline.c normal/command.c normal/main.c normal/menu.c \
|
|
normal/arg.c kern/partition.c \
|
|
util/console.c util/grub-emu.c util/misc.c util/i386/pc/getroot.c \
|
|
kern/env.c commands/ls.c \
|
|
commands/terminal.c commands/boot.c commands/cmp.c commands/cat.c
|
|
CLEANFILES += grub-emu grub_emu-kern_main.o grub_emu-kern_device.o grub_emu-kern_disk.o grub_emu-kern_dl.o grub_emu-kern_file.o grub_emu-kern_fs.o grub_emu-kern_err.o grub_emu-kern_misc.o grub_emu-kern_loader.o grub_emu-kern_rescue.o grub_emu-kern_term.o grub_emu-partmap_amiga.o grub_emu-partmap_pc.o grub_emu-partmap_apple.o grub_emu-fs_fshelp.o grub_emu-util_i386_pc_biosdisk.o grub_emu-fs_fat.o grub_emu-fs_ext2.o grub_emu-fs_ufs.o grub_emu-fs_minix.o grub_emu-fs_hfs.o grub_emu-fs_jfs.o grub_emu-fs_iso9660.o grub_emu-normal_cmdline.o grub_emu-normal_command.o grub_emu-normal_main.o grub_emu-normal_menu.o grub_emu-normal_arg.o grub_emu-kern_partition.o grub_emu-util_console.o grub_emu-util_grub_emu.o grub_emu-util_misc.o grub_emu-util_i386_pc_getroot.o grub_emu-kern_env.o grub_emu-commands_ls.o grub_emu-commands_terminal.o grub_emu-commands_boot.o grub_emu-commands_cmp.o grub_emu-commands_cat.o
|
|
MOSTLYCLEANFILES += grub_emu-kern_main.d grub_emu-kern_device.d grub_emu-kern_disk.d grub_emu-kern_dl.d grub_emu-kern_file.d grub_emu-kern_fs.d grub_emu-kern_err.d grub_emu-kern_misc.d grub_emu-kern_loader.d grub_emu-kern_rescue.d grub_emu-kern_term.d grub_emu-partmap_amiga.d grub_emu-partmap_pc.d grub_emu-partmap_apple.d grub_emu-fs_fshelp.d grub_emu-util_i386_pc_biosdisk.d grub_emu-fs_fat.d grub_emu-fs_ext2.d grub_emu-fs_ufs.d grub_emu-fs_minix.d grub_emu-fs_hfs.d grub_emu-fs_jfs.d grub_emu-fs_iso9660.d grub_emu-normal_cmdline.d grub_emu-normal_command.d grub_emu-normal_main.d grub_emu-normal_menu.d grub_emu-normal_arg.d grub_emu-kern_partition.d grub_emu-util_console.d grub_emu-util_grub_emu.d grub_emu-util_misc.d grub_emu-util_i386_pc_getroot.d grub_emu-kern_env.d grub_emu-commands_ls.d grub_emu-commands_terminal.d grub_emu-commands_boot.d grub_emu-commands_cmp.d grub_emu-commands_cat.d
|
|
|
|
grub-emu: grub_emu-kern_main.o grub_emu-kern_device.o grub_emu-kern_disk.o grub_emu-kern_dl.o grub_emu-kern_file.o grub_emu-kern_fs.o grub_emu-kern_err.o grub_emu-kern_misc.o grub_emu-kern_loader.o grub_emu-kern_rescue.o grub_emu-kern_term.o grub_emu-partmap_amiga.o grub_emu-partmap_pc.o grub_emu-partmap_apple.o grub_emu-fs_fshelp.o grub_emu-util_i386_pc_biosdisk.o grub_emu-fs_fat.o grub_emu-fs_ext2.o grub_emu-fs_ufs.o grub_emu-fs_minix.o grub_emu-fs_hfs.o grub_emu-fs_jfs.o grub_emu-fs_iso9660.o grub_emu-normal_cmdline.o grub_emu-normal_command.o grub_emu-normal_main.o grub_emu-normal_menu.o grub_emu-normal_arg.o grub_emu-kern_partition.o grub_emu-util_console.o grub_emu-util_grub_emu.o grub_emu-util_misc.o grub_emu-util_i386_pc_getroot.o grub_emu-kern_env.o grub_emu-commands_ls.o grub_emu-commands_terminal.o grub_emu-commands_boot.o grub_emu-commands_cmp.o grub_emu-commands_cat.o
|
|
$(BUILD_CC) -o $@ $^ $(BUILD_LDFLAGS) $(grub_emu_LDFLAGS)
|
|
|
|
grub_emu-kern_main.o: kern/main.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_main.d: kern/main.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,main\.o[ :]*,grub_emu-kern_main.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_main.d
|
|
|
|
grub_emu-kern_device.o: kern/device.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_device.d: kern/device.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,device\.o[ :]*,grub_emu-kern_device.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_device.d
|
|
|
|
grub_emu-kern_disk.o: kern/disk.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_disk.d: kern/disk.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,disk\.o[ :]*,grub_emu-kern_disk.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_disk.d
|
|
|
|
grub_emu-kern_dl.o: kern/dl.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_dl.d: kern/dl.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,dl\.o[ :]*,grub_emu-kern_dl.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_dl.d
|
|
|
|
grub_emu-kern_file.o: kern/file.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_file.d: kern/file.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,file\.o[ :]*,grub_emu-kern_file.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_file.d
|
|
|
|
grub_emu-kern_fs.o: kern/fs.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_fs.d: kern/fs.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,fs\.o[ :]*,grub_emu-kern_fs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_fs.d
|
|
|
|
grub_emu-kern_err.o: kern/err.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_err.d: kern/err.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,err\.o[ :]*,grub_emu-kern_err.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_err.d
|
|
|
|
grub_emu-kern_misc.o: kern/misc.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_misc.d: kern/misc.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,misc\.o[ :]*,grub_emu-kern_misc.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_misc.d
|
|
|
|
grub_emu-kern_loader.o: kern/loader.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_loader.d: kern/loader.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,loader\.o[ :]*,grub_emu-kern_loader.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_loader.d
|
|
|
|
grub_emu-kern_rescue.o: kern/rescue.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_rescue.d: kern/rescue.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,rescue\.o[ :]*,grub_emu-kern_rescue.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_rescue.d
|
|
|
|
grub_emu-kern_term.o: kern/term.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_term.d: kern/term.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,term\.o[ :]*,grub_emu-kern_term.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_term.d
|
|
|
|
grub_emu-partmap_amiga.o: partmap/amiga.c
|
|
$(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-partmap_amiga.d: partmap/amiga.c
|
|
set -e; $(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,amiga\.o[ :]*,grub_emu-partmap_amiga.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-partmap_amiga.d
|
|
|
|
grub_emu-partmap_pc.o: partmap/pc.c
|
|
$(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-partmap_pc.d: partmap/pc.c
|
|
set -e; $(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,pc\.o[ :]*,grub_emu-partmap_pc.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-partmap_pc.d
|
|
|
|
grub_emu-partmap_apple.o: partmap/apple.c
|
|
$(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-partmap_apple.d: partmap/apple.c
|
|
set -e; $(BUILD_CC) -Ipartmap -I$(srcdir)/partmap $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,apple\.o[ :]*,grub_emu-partmap_apple.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-partmap_apple.d
|
|
|
|
grub_emu-fs_fshelp.o: fs/fshelp.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_fshelp.d: fs/fshelp.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,fshelp\.o[ :]*,grub_emu-fs_fshelp.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_fshelp.d
|
|
|
|
grub_emu-util_i386_pc_biosdisk.o: util/i386/pc/biosdisk.c
|
|
$(BUILD_CC) -Iutil/i386/pc -I$(srcdir)/util/i386/pc $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-util_i386_pc_biosdisk.d: util/i386/pc/biosdisk.c
|
|
set -e; $(BUILD_CC) -Iutil/i386/pc -I$(srcdir)/util/i386/pc $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,biosdisk\.o[ :]*,grub_emu-util_i386_pc_biosdisk.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-util_i386_pc_biosdisk.d
|
|
|
|
grub_emu-fs_fat.o: fs/fat.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_fat.d: fs/fat.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,fat\.o[ :]*,grub_emu-fs_fat.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_fat.d
|
|
|
|
grub_emu-fs_ext2.o: fs/ext2.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_ext2.d: fs/ext2.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,ext2\.o[ :]*,grub_emu-fs_ext2.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_ext2.d
|
|
|
|
grub_emu-fs_ufs.o: fs/ufs.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_ufs.d: fs/ufs.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,ufs\.o[ :]*,grub_emu-fs_ufs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_ufs.d
|
|
|
|
grub_emu-fs_minix.o: fs/minix.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_minix.d: fs/minix.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,minix\.o[ :]*,grub_emu-fs_minix.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_minix.d
|
|
|
|
grub_emu-fs_hfs.o: fs/hfs.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_hfs.d: fs/hfs.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,hfs\.o[ :]*,grub_emu-fs_hfs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_hfs.d
|
|
|
|
grub_emu-fs_jfs.o: fs/jfs.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_jfs.d: fs/jfs.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,jfs\.o[ :]*,grub_emu-fs_jfs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_jfs.d
|
|
|
|
grub_emu-fs_iso9660.o: fs/iso9660.c
|
|
$(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-fs_iso9660.d: fs/iso9660.c
|
|
set -e; $(BUILD_CC) -Ifs -I$(srcdir)/fs $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,iso9660\.o[ :]*,grub_emu-fs_iso9660.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-fs_iso9660.d
|
|
|
|
grub_emu-normal_cmdline.o: normal/cmdline.c
|
|
$(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-normal_cmdline.d: normal/cmdline.c
|
|
set -e; $(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,cmdline\.o[ :]*,grub_emu-normal_cmdline.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-normal_cmdline.d
|
|
|
|
grub_emu-normal_command.o: normal/command.c
|
|
$(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-normal_command.d: normal/command.c
|
|
set -e; $(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,command\.o[ :]*,grub_emu-normal_command.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-normal_command.d
|
|
|
|
grub_emu-normal_main.o: normal/main.c
|
|
$(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-normal_main.d: normal/main.c
|
|
set -e; $(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,main\.o[ :]*,grub_emu-normal_main.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-normal_main.d
|
|
|
|
grub_emu-normal_menu.o: normal/menu.c
|
|
$(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-normal_menu.d: normal/menu.c
|
|
set -e; $(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,menu\.o[ :]*,grub_emu-normal_menu.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-normal_menu.d
|
|
|
|
grub_emu-normal_arg.o: normal/arg.c
|
|
$(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-normal_arg.d: normal/arg.c
|
|
set -e; $(BUILD_CC) -Inormal -I$(srcdir)/normal $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,arg\.o[ :]*,grub_emu-normal_arg.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-normal_arg.d
|
|
|
|
grub_emu-kern_partition.o: kern/partition.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_partition.d: kern/partition.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,partition\.o[ :]*,grub_emu-kern_partition.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_partition.d
|
|
|
|
grub_emu-util_console.o: util/console.c
|
|
$(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-util_console.d: util/console.c
|
|
set -e; $(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,console\.o[ :]*,grub_emu-util_console.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-util_console.d
|
|
|
|
grub_emu-util_grub_emu.o: util/grub-emu.c
|
|
$(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-util_grub_emu.d: util/grub-emu.c
|
|
set -e; $(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,grub\-emu\.o[ :]*,grub_emu-util_grub_emu.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-util_grub_emu.d
|
|
|
|
grub_emu-util_misc.o: util/misc.c
|
|
$(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-util_misc.d: util/misc.c
|
|
set -e; $(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,misc\.o[ :]*,grub_emu-util_misc.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-util_misc.d
|
|
|
|
grub_emu-util_i386_pc_getroot.o: util/i386/pc/getroot.c
|
|
$(BUILD_CC) -Iutil/i386/pc -I$(srcdir)/util/i386/pc $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-util_i386_pc_getroot.d: util/i386/pc/getroot.c
|
|
set -e; $(BUILD_CC) -Iutil/i386/pc -I$(srcdir)/util/i386/pc $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,getroot\.o[ :]*,grub_emu-util_i386_pc_getroot.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-util_i386_pc_getroot.d
|
|
|
|
grub_emu-kern_env.o: kern/env.c
|
|
$(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-kern_env.d: kern/env.c
|
|
set -e; $(BUILD_CC) -Ikern -I$(srcdir)/kern $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,env\.o[ :]*,grub_emu-kern_env.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-kern_env.d
|
|
|
|
grub_emu-commands_ls.o: commands/ls.c
|
|
$(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-commands_ls.d: commands/ls.c
|
|
set -e; $(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,ls\.o[ :]*,grub_emu-commands_ls.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-commands_ls.d
|
|
|
|
grub_emu-commands_terminal.o: commands/terminal.c
|
|
$(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-commands_terminal.d: commands/terminal.c
|
|
set -e; $(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,terminal\.o[ :]*,grub_emu-commands_terminal.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-commands_terminal.d
|
|
|
|
grub_emu-commands_boot.o: commands/boot.c
|
|
$(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-commands_boot.d: commands/boot.c
|
|
set -e; $(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,boot\.o[ :]*,grub_emu-commands_boot.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-commands_boot.d
|
|
|
|
grub_emu-commands_cmp.o: commands/cmp.c
|
|
$(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-commands_cmp.d: commands/cmp.c
|
|
set -e; $(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,cmp\.o[ :]*,grub_emu-commands_cmp.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-commands_cmp.d
|
|
|
|
grub_emu-commands_cat.o: commands/cat.c
|
|
$(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -c -o $@ $<
|
|
|
|
grub_emu-commands_cat.d: commands/cat.c
|
|
set -e; $(BUILD_CC) -Icommands -I$(srcdir)/commands $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(grub_emu_CFLAGS) -M $< | sed 's,cat\.o[ :]*,grub_emu-commands_cat.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grub_emu-commands_cat.d
|
|
|
|
grub_emu_LDFLAGS = -lncurses
|
|
|
|
grubof_SOURCES = boot/powerpc/ieee1275/crt0.S boot/powerpc/ieee1275/cmain.c \
|
|
boot/powerpc/ieee1275/ieee1275.c kern/main.c kern/device.c \
|
|
kern/disk.c kern/dl.c kern/file.c kern/fs.c kern/err.c \
|
|
kern/misc.c kern/mm.c kern/loader.c kern/rescue.c kern/term.c \
|
|
kern/powerpc/ieee1275/init.c term/powerpc/ieee1275/ofconsole.c \
|
|
kern/powerpc/ieee1275/openfw.c disk/powerpc/ieee1275/ofdisk.c \
|
|
kern/partition.c kern/env.c kern/powerpc/dl.c grubof_symlist.c \
|
|
kern/powerpc/cache.S
|
|
CLEANFILES += grubof grubof-boot_powerpc_ieee1275_crt0.o grubof-boot_powerpc_ieee1275_cmain.o grubof-boot_powerpc_ieee1275_ieee1275.o grubof-kern_main.o grubof-kern_device.o grubof-kern_disk.o grubof-kern_dl.o grubof-kern_file.o grubof-kern_fs.o grubof-kern_err.o grubof-kern_misc.o grubof-kern_mm.o grubof-kern_loader.o grubof-kern_rescue.o grubof-kern_term.o grubof-kern_powerpc_ieee1275_init.o grubof-term_powerpc_ieee1275_ofconsole.o grubof-kern_powerpc_ieee1275_openfw.o grubof-disk_powerpc_ieee1275_ofdisk.o grubof-kern_partition.o grubof-kern_env.o grubof-kern_powerpc_dl.o grubof-grubof_symlist.o grubof-kern_powerpc_cache.o
|
|
MOSTLYCLEANFILES += grubof-boot_powerpc_ieee1275_crt0.d grubof-boot_powerpc_ieee1275_cmain.d grubof-boot_powerpc_ieee1275_ieee1275.d grubof-kern_main.d grubof-kern_device.d grubof-kern_disk.d grubof-kern_dl.d grubof-kern_file.d grubof-kern_fs.d grubof-kern_err.d grubof-kern_misc.d grubof-kern_mm.d grubof-kern_loader.d grubof-kern_rescue.d grubof-kern_term.d grubof-kern_powerpc_ieee1275_init.d grubof-term_powerpc_ieee1275_ofconsole.d grubof-kern_powerpc_ieee1275_openfw.d grubof-disk_powerpc_ieee1275_ofdisk.d grubof-kern_partition.d grubof-kern_env.d grubof-kern_powerpc_dl.d grubof-grubof_symlist.d grubof-kern_powerpc_cache.d
|
|
|
|
grubof: grubof-boot_powerpc_ieee1275_crt0.o grubof-boot_powerpc_ieee1275_cmain.o grubof-boot_powerpc_ieee1275_ieee1275.o grubof-kern_main.o grubof-kern_device.o grubof-kern_disk.o grubof-kern_dl.o grubof-kern_file.o grubof-kern_fs.o grubof-kern_err.o grubof-kern_misc.o grubof-kern_mm.o grubof-kern_loader.o grubof-kern_rescue.o grubof-kern_term.o grubof-kern_powerpc_ieee1275_init.o grubof-term_powerpc_ieee1275_ofconsole.o grubof-kern_powerpc_ieee1275_openfw.o grubof-disk_powerpc_ieee1275_ofdisk.o grubof-kern_partition.o grubof-kern_env.o grubof-kern_powerpc_dl.o grubof-grubof_symlist.o grubof-kern_powerpc_cache.o
|
|
$(BUILD_CC) -o $@ $^ $(BUILD_LDFLAGS) $(grubof_LDFLAGS)
|
|
|
|
grubof-boot_powerpc_ieee1275_crt0.o: boot/powerpc/ieee1275/crt0.S
|
|
$(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-boot_powerpc_ieee1275_crt0.d: boot/powerpc/ieee1275/crt0.S
|
|
set -e; $(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,crt0\.o[ :]*,grubof-boot_powerpc_ieee1275_crt0.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-boot_powerpc_ieee1275_crt0.d
|
|
|
|
grubof-boot_powerpc_ieee1275_cmain.o: boot/powerpc/ieee1275/cmain.c
|
|
$(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-boot_powerpc_ieee1275_cmain.d: boot/powerpc/ieee1275/cmain.c
|
|
set -e; $(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,cmain\.o[ :]*,grubof-boot_powerpc_ieee1275_cmain.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-boot_powerpc_ieee1275_cmain.d
|
|
|
|
grubof-boot_powerpc_ieee1275_ieee1275.o: boot/powerpc/ieee1275/ieee1275.c
|
|
$(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-boot_powerpc_ieee1275_ieee1275.d: boot/powerpc/ieee1275/ieee1275.c
|
|
set -e; $(CC) -Iboot/powerpc/ieee1275 -I$(srcdir)/boot/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,ieee1275\.o[ :]*,grubof-boot_powerpc_ieee1275_ieee1275.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-boot_powerpc_ieee1275_ieee1275.d
|
|
|
|
grubof-kern_main.o: kern/main.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_main.d: kern/main.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,main\.o[ :]*,grubof-kern_main.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_main.d
|
|
|
|
grubof-kern_device.o: kern/device.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_device.d: kern/device.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,device\.o[ :]*,grubof-kern_device.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_device.d
|
|
|
|
grubof-kern_disk.o: kern/disk.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_disk.d: kern/disk.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,disk\.o[ :]*,grubof-kern_disk.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_disk.d
|
|
|
|
grubof-kern_dl.o: kern/dl.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_dl.d: kern/dl.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,dl\.o[ :]*,grubof-kern_dl.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_dl.d
|
|
|
|
grubof-kern_file.o: kern/file.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_file.d: kern/file.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,file\.o[ :]*,grubof-kern_file.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_file.d
|
|
|
|
grubof-kern_fs.o: kern/fs.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_fs.d: kern/fs.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,fs\.o[ :]*,grubof-kern_fs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_fs.d
|
|
|
|
grubof-kern_err.o: kern/err.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_err.d: kern/err.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,err\.o[ :]*,grubof-kern_err.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_err.d
|
|
|
|
grubof-kern_misc.o: kern/misc.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_misc.d: kern/misc.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,misc\.o[ :]*,grubof-kern_misc.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_misc.d
|
|
|
|
grubof-kern_mm.o: kern/mm.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_mm.d: kern/mm.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,mm\.o[ :]*,grubof-kern_mm.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_mm.d
|
|
|
|
grubof-kern_loader.o: kern/loader.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_loader.d: kern/loader.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,loader\.o[ :]*,grubof-kern_loader.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_loader.d
|
|
|
|
grubof-kern_rescue.o: kern/rescue.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_rescue.d: kern/rescue.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,rescue\.o[ :]*,grubof-kern_rescue.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_rescue.d
|
|
|
|
grubof-kern_term.o: kern/term.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_term.d: kern/term.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,term\.o[ :]*,grubof-kern_term.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_term.d
|
|
|
|
grubof-kern_powerpc_ieee1275_init.o: kern/powerpc/ieee1275/init.c
|
|
$(CC) -Ikern/powerpc/ieee1275 -I$(srcdir)/kern/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_powerpc_ieee1275_init.d: kern/powerpc/ieee1275/init.c
|
|
set -e; $(CC) -Ikern/powerpc/ieee1275 -I$(srcdir)/kern/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,init\.o[ :]*,grubof-kern_powerpc_ieee1275_init.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_powerpc_ieee1275_init.d
|
|
|
|
grubof-term_powerpc_ieee1275_ofconsole.o: term/powerpc/ieee1275/ofconsole.c
|
|
$(CC) -Iterm/powerpc/ieee1275 -I$(srcdir)/term/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-term_powerpc_ieee1275_ofconsole.d: term/powerpc/ieee1275/ofconsole.c
|
|
set -e; $(CC) -Iterm/powerpc/ieee1275 -I$(srcdir)/term/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,ofconsole\.o[ :]*,grubof-term_powerpc_ieee1275_ofconsole.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-term_powerpc_ieee1275_ofconsole.d
|
|
|
|
grubof-kern_powerpc_ieee1275_openfw.o: kern/powerpc/ieee1275/openfw.c
|
|
$(CC) -Ikern/powerpc/ieee1275 -I$(srcdir)/kern/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_powerpc_ieee1275_openfw.d: kern/powerpc/ieee1275/openfw.c
|
|
set -e; $(CC) -Ikern/powerpc/ieee1275 -I$(srcdir)/kern/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,openfw\.o[ :]*,grubof-kern_powerpc_ieee1275_openfw.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_powerpc_ieee1275_openfw.d
|
|
|
|
grubof-disk_powerpc_ieee1275_ofdisk.o: disk/powerpc/ieee1275/ofdisk.c
|
|
$(CC) -Idisk/powerpc/ieee1275 -I$(srcdir)/disk/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-disk_powerpc_ieee1275_ofdisk.d: disk/powerpc/ieee1275/ofdisk.c
|
|
set -e; $(CC) -Idisk/powerpc/ieee1275 -I$(srcdir)/disk/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,ofdisk\.o[ :]*,grubof-disk_powerpc_ieee1275_ofdisk.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-disk_powerpc_ieee1275_ofdisk.d
|
|
|
|
grubof-kern_partition.o: kern/partition.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_partition.d: kern/partition.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,partition\.o[ :]*,grubof-kern_partition.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_partition.d
|
|
|
|
grubof-kern_env.o: kern/env.c
|
|
$(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_env.d: kern/env.c
|
|
set -e; $(CC) -Ikern -I$(srcdir)/kern $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,env\.o[ :]*,grubof-kern_env.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_env.d
|
|
|
|
grubof-kern_powerpc_dl.o: kern/powerpc/dl.c
|
|
$(CC) -Ikern/powerpc -I$(srcdir)/kern/powerpc $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_powerpc_dl.d: kern/powerpc/dl.c
|
|
set -e; $(CC) -Ikern/powerpc -I$(srcdir)/kern/powerpc $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,dl\.o[ :]*,grubof-kern_powerpc_dl.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_powerpc_dl.d
|
|
|
|
grubof-grubof_symlist.o: grubof_symlist.c
|
|
$(CC) -I. -I$(srcdir)/. $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-grubof_symlist.d: grubof_symlist.c
|
|
set -e; $(CC) -I. -I$(srcdir)/. $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,grubof_symlist\.o[ :]*,grubof-grubof_symlist.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-grubof_symlist.d
|
|
|
|
grubof-kern_powerpc_cache.o: kern/powerpc/cache.S
|
|
$(CC) -Ikern/powerpc -I$(srcdir)/kern/powerpc $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -c -o $@ $<
|
|
|
|
grubof-kern_powerpc_cache.d: kern/powerpc/cache.S
|
|
set -e; $(CC) -Ikern/powerpc -I$(srcdir)/kern/powerpc $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(grubof_CFLAGS) -M $< | sed 's,cache\.o[ :]*,grubof-kern_powerpc_cache.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include grubof-kern_powerpc_cache.d
|
|
|
|
grubof_HEADERS = grub/powerpc/ieee1275/ieee1275.h
|
|
grubof_CFLAGS = $(COMMON_CFLAGS)
|
|
grubof_ASFLAGS = $(COMMON_ASFLAGS)
|
|
grubof_LDFLAGS = -nostdlib -static-libgcc -lgcc -Wl,-N,-S,-Ttext,0x200000,-Bstatic
|
|
|
|
# For genmoddep.
|
|
genmoddep_SOURCES = util/genmoddep.c
|
|
CLEANFILES += genmoddep genmoddep-util_genmoddep.o
|
|
MOSTLYCLEANFILES += genmoddep-util_genmoddep.d
|
|
|
|
genmoddep: genmoddep-util_genmoddep.o
|
|
$(BUILD_CC) -o $@ $^ $(BUILD_LDFLAGS) $(genmoddep_LDFLAGS)
|
|
|
|
genmoddep-util_genmoddep.o: util/genmoddep.c
|
|
$(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(genmoddep_CFLAGS) -c -o $@ $<
|
|
|
|
genmoddep-util_genmoddep.d: util/genmoddep.c
|
|
set -e; $(BUILD_CC) -Iutil -I$(srcdir)/util $(BUILD_CPPFLAGS) $(BUILD_CFLAGS) -DGRUB_UTIL=1 $(genmoddep_CFLAGS) -M $< | sed 's,genmoddep\.o[ :]*,genmoddep-util_genmoddep.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include genmoddep-util_genmoddep.d
|
|
|
|
|
|
# Modules.
|
|
pkgdata_MODULES = _linux.mod linux.mod fat.mod ufs.mod ext2.mod minix.mod \
|
|
hfs.mod jfs.mod normal.mod hello.mod font.mod \
|
|
boot.mod cmp.mod cat.mod terminal.mod fshelp.mod amiga.mod apple.mod pc.mod
|
|
|
|
# For fshelp.mod.
|
|
fshelp_mod_SOURCES = fs/fshelp.c
|
|
CLEANFILES += fshelp.mod mod-fshelp.o mod-fshelp.c pre-fshelp.o fshelp_mod-fs_fshelp.o def-fshelp.lst und-fshelp.lst
|
|
MOSTLYCLEANFILES += fshelp_mod-fs_fshelp.d
|
|
DEFSYMFILES += def-fshelp.lst
|
|
UNDSYMFILES += und-fshelp.lst
|
|
|
|
fshelp.mod: pre-fshelp.o mod-fshelp.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-fshelp.o: fshelp_mod-fs_fshelp.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-fshelp.o: mod-fshelp.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(fshelp_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-fshelp.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'fshelp' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-fshelp.lst: pre-fshelp.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 fshelp/' > $@
|
|
|
|
und-fshelp.lst: pre-fshelp.o
|
|
echo 'fshelp' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
fshelp_mod-fs_fshelp.o: fs/fshelp.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(fshelp_mod_CFLAGS) -c -o $@ $<
|
|
|
|
fshelp_mod-fs_fshelp.d: fs/fshelp.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(fshelp_mod_CFLAGS) -M $< | sed 's,fshelp\.o[ :]*,fshelp_mod-fs_fshelp.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include fshelp_mod-fs_fshelp.d
|
|
|
|
fshelp_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For fat.mod.
|
|
fat_mod_SOURCES = fs/fat.c
|
|
CLEANFILES += fat.mod mod-fat.o mod-fat.c pre-fat.o fat_mod-fs_fat.o def-fat.lst und-fat.lst
|
|
MOSTLYCLEANFILES += fat_mod-fs_fat.d
|
|
DEFSYMFILES += def-fat.lst
|
|
UNDSYMFILES += und-fat.lst
|
|
|
|
fat.mod: pre-fat.o mod-fat.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-fat.o: fat_mod-fs_fat.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-fat.o: mod-fat.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(fat_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-fat.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'fat' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-fat.lst: pre-fat.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 fat/' > $@
|
|
|
|
und-fat.lst: pre-fat.o
|
|
echo 'fat' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
fat_mod-fs_fat.o: fs/fat.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(fat_mod_CFLAGS) -c -o $@ $<
|
|
|
|
fat_mod-fs_fat.d: fs/fat.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(fat_mod_CFLAGS) -M $< | sed 's,fat\.o[ :]*,fat_mod-fs_fat.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include fat_mod-fs_fat.d
|
|
|
|
fat_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For ext2.mod.
|
|
ext2_mod_SOURCES = fs/ext2.c
|
|
CLEANFILES += ext2.mod mod-ext2.o mod-ext2.c pre-ext2.o ext2_mod-fs_ext2.o def-ext2.lst und-ext2.lst
|
|
MOSTLYCLEANFILES += ext2_mod-fs_ext2.d
|
|
DEFSYMFILES += def-ext2.lst
|
|
UNDSYMFILES += und-ext2.lst
|
|
|
|
ext2.mod: pre-ext2.o mod-ext2.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-ext2.o: ext2_mod-fs_ext2.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-ext2.o: mod-ext2.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(ext2_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-ext2.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'ext2' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-ext2.lst: pre-ext2.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 ext2/' > $@
|
|
|
|
und-ext2.lst: pre-ext2.o
|
|
echo 'ext2' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
ext2_mod-fs_ext2.o: fs/ext2.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(ext2_mod_CFLAGS) -c -o $@ $<
|
|
|
|
ext2_mod-fs_ext2.d: fs/ext2.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(ext2_mod_CFLAGS) -M $< | sed 's,ext2\.o[ :]*,ext2_mod-fs_ext2.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include ext2_mod-fs_ext2.d
|
|
|
|
ext2_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For ufs.mod.
|
|
ufs_mod_SOURCES = fs/ufs.c
|
|
CLEANFILES += ufs.mod mod-ufs.o mod-ufs.c pre-ufs.o ufs_mod-fs_ufs.o def-ufs.lst und-ufs.lst
|
|
MOSTLYCLEANFILES += ufs_mod-fs_ufs.d
|
|
DEFSYMFILES += def-ufs.lst
|
|
UNDSYMFILES += und-ufs.lst
|
|
|
|
ufs.mod: pre-ufs.o mod-ufs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-ufs.o: ufs_mod-fs_ufs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-ufs.o: mod-ufs.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(ufs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-ufs.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'ufs' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-ufs.lst: pre-ufs.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 ufs/' > $@
|
|
|
|
und-ufs.lst: pre-ufs.o
|
|
echo 'ufs' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
ufs_mod-fs_ufs.o: fs/ufs.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(ufs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
ufs_mod-fs_ufs.d: fs/ufs.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(ufs_mod_CFLAGS) -M $< | sed 's,ufs\.o[ :]*,ufs_mod-fs_ufs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include ufs_mod-fs_ufs.d
|
|
|
|
ufs_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For minix.mod.
|
|
minix_mod_SOURCES = fs/minix.c
|
|
CLEANFILES += minix.mod mod-minix.o mod-minix.c pre-minix.o minix_mod-fs_minix.o def-minix.lst und-minix.lst
|
|
MOSTLYCLEANFILES += minix_mod-fs_minix.d
|
|
DEFSYMFILES += def-minix.lst
|
|
UNDSYMFILES += und-minix.lst
|
|
|
|
minix.mod: pre-minix.o mod-minix.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-minix.o: minix_mod-fs_minix.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-minix.o: mod-minix.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(minix_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-minix.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'minix' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-minix.lst: pre-minix.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 minix/' > $@
|
|
|
|
und-minix.lst: pre-minix.o
|
|
echo 'minix' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
minix_mod-fs_minix.o: fs/minix.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(minix_mod_CFLAGS) -c -o $@ $<
|
|
|
|
minix_mod-fs_minix.d: fs/minix.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(minix_mod_CFLAGS) -M $< | sed 's,minix\.o[ :]*,minix_mod-fs_minix.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include minix_mod-fs_minix.d
|
|
|
|
minix_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For hfs.mod.
|
|
hfs_mod_SOURCES = fs/hfs.c
|
|
CLEANFILES += hfs.mod mod-hfs.o mod-hfs.c pre-hfs.o hfs_mod-fs_hfs.o def-hfs.lst und-hfs.lst
|
|
MOSTLYCLEANFILES += hfs_mod-fs_hfs.d
|
|
DEFSYMFILES += def-hfs.lst
|
|
UNDSYMFILES += und-hfs.lst
|
|
|
|
hfs.mod: pre-hfs.o mod-hfs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-hfs.o: hfs_mod-fs_hfs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-hfs.o: mod-hfs.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(hfs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-hfs.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'hfs' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-hfs.lst: pre-hfs.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 hfs/' > $@
|
|
|
|
und-hfs.lst: pre-hfs.o
|
|
echo 'hfs' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
hfs_mod-fs_hfs.o: fs/hfs.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(hfs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
hfs_mod-fs_hfs.d: fs/hfs.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(hfs_mod_CFLAGS) -M $< | sed 's,hfs\.o[ :]*,hfs_mod-fs_hfs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include hfs_mod-fs_hfs.d
|
|
|
|
hfs_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For jfs.mod.
|
|
jfs_mod_SOURCES = fs/jfs.c
|
|
CLEANFILES += jfs.mod mod-jfs.o mod-jfs.c pre-jfs.o jfs_mod-fs_jfs.o def-jfs.lst und-jfs.lst
|
|
MOSTLYCLEANFILES += jfs_mod-fs_jfs.d
|
|
DEFSYMFILES += def-jfs.lst
|
|
UNDSYMFILES += und-jfs.lst
|
|
|
|
jfs.mod: pre-jfs.o mod-jfs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-jfs.o: jfs_mod-fs_jfs.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-jfs.o: mod-jfs.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(jfs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-jfs.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'jfs' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-jfs.lst: pre-jfs.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 jfs/' > $@
|
|
|
|
und-jfs.lst: pre-jfs.o
|
|
echo 'jfs' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
jfs_mod-fs_jfs.o: fs/jfs.c
|
|
$(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(jfs_mod_CFLAGS) -c -o $@ $<
|
|
|
|
jfs_mod-fs_jfs.d: fs/jfs.c
|
|
set -e; $(CC) -Ifs -I$(srcdir)/fs $(CPPFLAGS) $(CFLAGS) $(jfs_mod_CFLAGS) -M $< | sed 's,jfs\.o[ :]*,jfs_mod-fs_jfs.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include jfs_mod-fs_jfs.d
|
|
|
|
jfs_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For iso9660.mod.
|
|
iso9660_mod_SOURCES = fs/iso9660.c
|
|
iso9660_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For _linux.mod.
|
|
_linux_mod_SOURCES = loader/powerpc/ieee1275/linux.c
|
|
CLEANFILES += _linux.mod mod-_linux.o mod-_linux.c pre-_linux.o _linux_mod-loader_powerpc_ieee1275_linux.o def-_linux.lst und-_linux.lst
|
|
MOSTLYCLEANFILES += _linux_mod-loader_powerpc_ieee1275_linux.d
|
|
DEFSYMFILES += def-_linux.lst
|
|
UNDSYMFILES += und-_linux.lst
|
|
|
|
_linux.mod: pre-_linux.o mod-_linux.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-_linux.o: _linux_mod-loader_powerpc_ieee1275_linux.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-_linux.o: mod-_linux.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(_linux_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-_linux.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh '_linux' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-_linux.lst: pre-_linux.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 _linux/' > $@
|
|
|
|
und-_linux.lst: pre-_linux.o
|
|
echo '_linux' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
_linux_mod-loader_powerpc_ieee1275_linux.o: loader/powerpc/ieee1275/linux.c
|
|
$(CC) -Iloader/powerpc/ieee1275 -I$(srcdir)/loader/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) $(_linux_mod_CFLAGS) -c -o $@ $<
|
|
|
|
_linux_mod-loader_powerpc_ieee1275_linux.d: loader/powerpc/ieee1275/linux.c
|
|
set -e; $(CC) -Iloader/powerpc/ieee1275 -I$(srcdir)/loader/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) $(_linux_mod_CFLAGS) -M $< | sed 's,linux\.o[ :]*,_linux_mod-loader_powerpc_ieee1275_linux.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include _linux_mod-loader_powerpc_ieee1275_linux.d
|
|
|
|
_linux_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For linux.mod.
|
|
linux_mod_SOURCES = loader/powerpc/ieee1275/linux_normal.c
|
|
CLEANFILES += linux.mod mod-linux.o mod-linux.c pre-linux.o linux_mod-loader_powerpc_ieee1275_linux_normal.o def-linux.lst und-linux.lst
|
|
MOSTLYCLEANFILES += linux_mod-loader_powerpc_ieee1275_linux_normal.d
|
|
DEFSYMFILES += def-linux.lst
|
|
UNDSYMFILES += und-linux.lst
|
|
|
|
linux.mod: pre-linux.o mod-linux.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-linux.o: linux_mod-loader_powerpc_ieee1275_linux_normal.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-linux.o: mod-linux.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(linux_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-linux.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'linux' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-linux.lst: pre-linux.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 linux/' > $@
|
|
|
|
und-linux.lst: pre-linux.o
|
|
echo 'linux' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
linux_mod-loader_powerpc_ieee1275_linux_normal.o: loader/powerpc/ieee1275/linux_normal.c
|
|
$(CC) -Iloader/powerpc/ieee1275 -I$(srcdir)/loader/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) $(linux_mod_CFLAGS) -c -o $@ $<
|
|
|
|
linux_mod-loader_powerpc_ieee1275_linux_normal.d: loader/powerpc/ieee1275/linux_normal.c
|
|
set -e; $(CC) -Iloader/powerpc/ieee1275 -I$(srcdir)/loader/powerpc/ieee1275 $(CPPFLAGS) $(CFLAGS) $(linux_mod_CFLAGS) -M $< | sed 's,linux_normal\.o[ :]*,linux_mod-loader_powerpc_ieee1275_linux_normal.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include linux_mod-loader_powerpc_ieee1275_linux_normal.d
|
|
|
|
linux_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For normal.mod.
|
|
normal_mod_SOURCES = normal/cmdline.c normal/command.c normal/main.c \
|
|
normal/menu.c normal/arg.c normal/powerpc/setjmp.S
|
|
CLEANFILES += normal.mod mod-normal.o mod-normal.c pre-normal.o normal_mod-normal_cmdline.o normal_mod-normal_command.o normal_mod-normal_main.o normal_mod-normal_menu.o normal_mod-normal_arg.o normal_mod-normal_powerpc_setjmp.o def-normal.lst und-normal.lst
|
|
MOSTLYCLEANFILES += normal_mod-normal_cmdline.d normal_mod-normal_command.d normal_mod-normal_main.d normal_mod-normal_menu.d normal_mod-normal_arg.d normal_mod-normal_powerpc_setjmp.d
|
|
DEFSYMFILES += def-normal.lst
|
|
UNDSYMFILES += und-normal.lst
|
|
|
|
normal.mod: pre-normal.o mod-normal.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-normal.o: normal_mod-normal_cmdline.o normal_mod-normal_command.o normal_mod-normal_main.o normal_mod-normal_menu.o normal_mod-normal_arg.o normal_mod-normal_powerpc_setjmp.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-normal.o: mod-normal.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-normal.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'normal' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-normal.lst: pre-normal.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 normal/' > $@
|
|
|
|
und-normal.lst: pre-normal.o
|
|
echo 'normal' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
normal_mod-normal_cmdline.o: normal/cmdline.c
|
|
$(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_cmdline.d: normal/cmdline.c
|
|
set -e; $(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -M $< | sed 's,cmdline\.o[ :]*,normal_mod-normal_cmdline.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_cmdline.d
|
|
|
|
normal_mod-normal_command.o: normal/command.c
|
|
$(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_command.d: normal/command.c
|
|
set -e; $(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -M $< | sed 's,command\.o[ :]*,normal_mod-normal_command.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_command.d
|
|
|
|
normal_mod-normal_main.o: normal/main.c
|
|
$(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_main.d: normal/main.c
|
|
set -e; $(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -M $< | sed 's,main\.o[ :]*,normal_mod-normal_main.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_main.d
|
|
|
|
normal_mod-normal_menu.o: normal/menu.c
|
|
$(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_menu.d: normal/menu.c
|
|
set -e; $(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -M $< | sed 's,menu\.o[ :]*,normal_mod-normal_menu.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_menu.d
|
|
|
|
normal_mod-normal_arg.o: normal/arg.c
|
|
$(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_arg.d: normal/arg.c
|
|
set -e; $(CC) -Inormal -I$(srcdir)/normal $(CPPFLAGS) $(CFLAGS) $(normal_mod_CFLAGS) -M $< | sed 's,arg\.o[ :]*,normal_mod-normal_arg.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_arg.d
|
|
|
|
normal_mod-normal_powerpc_setjmp.o: normal/powerpc/setjmp.S
|
|
$(CC) -Inormal/powerpc -I$(srcdir)/normal/powerpc $(CPPFLAGS) $(ASFLAGS) $(normal_mod_ASFLAGS) -c -o $@ $<
|
|
|
|
normal_mod-normal_powerpc_setjmp.d: normal/powerpc/setjmp.S
|
|
set -e; $(CC) -Inormal/powerpc -I$(srcdir)/normal/powerpc $(CPPFLAGS) $(ASFLAGS) $(normal_mod_ASFLAGS) -M $< | sed 's,setjmp\.o[ :]*,normal_mod-normal_powerpc_setjmp.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include normal_mod-normal_powerpc_setjmp.d
|
|
|
|
normal_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
normal_mod_ASFLAGS = $(COMMON_ASFLAGS)
|
|
|
|
# For hello.mod.
|
|
hello_mod_SOURCES = hello/hello.c
|
|
CLEANFILES += hello.mod mod-hello.o mod-hello.c pre-hello.o hello_mod-hello_hello.o def-hello.lst und-hello.lst
|
|
MOSTLYCLEANFILES += hello_mod-hello_hello.d
|
|
DEFSYMFILES += def-hello.lst
|
|
UNDSYMFILES += und-hello.lst
|
|
|
|
hello.mod: pre-hello.o mod-hello.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-hello.o: hello_mod-hello_hello.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-hello.o: mod-hello.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(hello_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-hello.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'hello' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-hello.lst: pre-hello.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 hello/' > $@
|
|
|
|
und-hello.lst: pre-hello.o
|
|
echo 'hello' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
hello_mod-hello_hello.o: hello/hello.c
|
|
$(CC) -Ihello -I$(srcdir)/hello $(CPPFLAGS) $(CFLAGS) $(hello_mod_CFLAGS) -c -o $@ $<
|
|
|
|
hello_mod-hello_hello.d: hello/hello.c
|
|
set -e; $(CC) -Ihello -I$(srcdir)/hello $(CPPFLAGS) $(CFLAGS) $(hello_mod_CFLAGS) -M $< | sed 's,hello\.o[ :]*,hello_mod-hello_hello.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include hello_mod-hello_hello.d
|
|
|
|
hello_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For boot.mod.
|
|
boot_mod_SOURCES = commands/boot.c
|
|
CLEANFILES += boot.mod mod-boot.o mod-boot.c pre-boot.o boot_mod-commands_boot.o def-boot.lst und-boot.lst
|
|
MOSTLYCLEANFILES += boot_mod-commands_boot.d
|
|
DEFSYMFILES += def-boot.lst
|
|
UNDSYMFILES += und-boot.lst
|
|
|
|
boot.mod: pre-boot.o mod-boot.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-boot.o: boot_mod-commands_boot.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-boot.o: mod-boot.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(boot_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-boot.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'boot' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-boot.lst: pre-boot.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 boot/' > $@
|
|
|
|
und-boot.lst: pre-boot.o
|
|
echo 'boot' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
boot_mod-commands_boot.o: commands/boot.c
|
|
$(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(boot_mod_CFLAGS) -c -o $@ $<
|
|
|
|
boot_mod-commands_boot.d: commands/boot.c
|
|
set -e; $(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(boot_mod_CFLAGS) -M $< | sed 's,boot\.o[ :]*,boot_mod-commands_boot.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include boot_mod-commands_boot.d
|
|
|
|
boot_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For terminal.mod.
|
|
terminal_mod_SOURCES = commands/terminal.c
|
|
CLEANFILES += terminal.mod mod-terminal.o mod-terminal.c pre-terminal.o terminal_mod-commands_terminal.o def-terminal.lst und-terminal.lst
|
|
MOSTLYCLEANFILES += terminal_mod-commands_terminal.d
|
|
DEFSYMFILES += def-terminal.lst
|
|
UNDSYMFILES += und-terminal.lst
|
|
|
|
terminal.mod: pre-terminal.o mod-terminal.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-terminal.o: terminal_mod-commands_terminal.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-terminal.o: mod-terminal.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(terminal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-terminal.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'terminal' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-terminal.lst: pre-terminal.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 terminal/' > $@
|
|
|
|
und-terminal.lst: pre-terminal.o
|
|
echo 'terminal' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
terminal_mod-commands_terminal.o: commands/terminal.c
|
|
$(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(terminal_mod_CFLAGS) -c -o $@ $<
|
|
|
|
terminal_mod-commands_terminal.d: commands/terminal.c
|
|
set -e; $(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(terminal_mod_CFLAGS) -M $< | sed 's,terminal\.o[ :]*,terminal_mod-commands_terminal.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include terminal_mod-commands_terminal.d
|
|
|
|
terminal_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For ls.mod.
|
|
ls_mod_SOURCES = commands/ls.c
|
|
ls_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For cmp.mod.
|
|
cmp_mod_SOURCES = commands/cmp.c
|
|
CLEANFILES += cmp.mod mod-cmp.o mod-cmp.c pre-cmp.o cmp_mod-commands_cmp.o def-cmp.lst und-cmp.lst
|
|
MOSTLYCLEANFILES += cmp_mod-commands_cmp.d
|
|
DEFSYMFILES += def-cmp.lst
|
|
UNDSYMFILES += und-cmp.lst
|
|
|
|
cmp.mod: pre-cmp.o mod-cmp.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-cmp.o: cmp_mod-commands_cmp.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-cmp.o: mod-cmp.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(cmp_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-cmp.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'cmp' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-cmp.lst: pre-cmp.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 cmp/' > $@
|
|
|
|
und-cmp.lst: pre-cmp.o
|
|
echo 'cmp' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
cmp_mod-commands_cmp.o: commands/cmp.c
|
|
$(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(cmp_mod_CFLAGS) -c -o $@ $<
|
|
|
|
cmp_mod-commands_cmp.d: commands/cmp.c
|
|
set -e; $(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(cmp_mod_CFLAGS) -M $< | sed 's,cmp\.o[ :]*,cmp_mod-commands_cmp.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include cmp_mod-commands_cmp.d
|
|
|
|
cmp_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For cat.mod.
|
|
cat_mod_SOURCES = commands/cat.c
|
|
CLEANFILES += cat.mod mod-cat.o mod-cat.c pre-cat.o cat_mod-commands_cat.o def-cat.lst und-cat.lst
|
|
MOSTLYCLEANFILES += cat_mod-commands_cat.d
|
|
DEFSYMFILES += def-cat.lst
|
|
UNDSYMFILES += und-cat.lst
|
|
|
|
cat.mod: pre-cat.o mod-cat.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-cat.o: cat_mod-commands_cat.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-cat.o: mod-cat.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(cat_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-cat.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'cat' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-cat.lst: pre-cat.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 cat/' > $@
|
|
|
|
und-cat.lst: pre-cat.o
|
|
echo 'cat' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
cat_mod-commands_cat.o: commands/cat.c
|
|
$(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(cat_mod_CFLAGS) -c -o $@ $<
|
|
|
|
cat_mod-commands_cat.d: commands/cat.c
|
|
set -e; $(CC) -Icommands -I$(srcdir)/commands $(CPPFLAGS) $(CFLAGS) $(cat_mod_CFLAGS) -M $< | sed 's,cat\.o[ :]*,cat_mod-commands_cat.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include cat_mod-commands_cat.d
|
|
|
|
cat_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For font.mod.
|
|
font_mod_SOURCES = font/manager.c
|
|
CLEANFILES += font.mod mod-font.o mod-font.c pre-font.o font_mod-font_manager.o def-font.lst und-font.lst
|
|
MOSTLYCLEANFILES += font_mod-font_manager.d
|
|
DEFSYMFILES += def-font.lst
|
|
UNDSYMFILES += und-font.lst
|
|
|
|
font.mod: pre-font.o mod-font.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-font.o: font_mod-font_manager.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-font.o: mod-font.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(font_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-font.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'font' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-font.lst: pre-font.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 font/' > $@
|
|
|
|
und-font.lst: pre-font.o
|
|
echo 'font' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
font_mod-font_manager.o: font/manager.c
|
|
$(CC) -Ifont -I$(srcdir)/font $(CPPFLAGS) $(CFLAGS) $(font_mod_CFLAGS) -c -o $@ $<
|
|
|
|
font_mod-font_manager.d: font/manager.c
|
|
set -e; $(CC) -Ifont -I$(srcdir)/font $(CPPFLAGS) $(CFLAGS) $(font_mod_CFLAGS) -M $< | sed 's,manager\.o[ :]*,font_mod-font_manager.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include font_mod-font_manager.d
|
|
|
|
font_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For amiga.mod
|
|
amiga_mod_SOURCES = partmap/amiga.c
|
|
CLEANFILES += amiga.mod mod-amiga.o mod-amiga.c pre-amiga.o amiga_mod-partmap_amiga.o def-amiga.lst und-amiga.lst
|
|
MOSTLYCLEANFILES += amiga_mod-partmap_amiga.d
|
|
DEFSYMFILES += def-amiga.lst
|
|
UNDSYMFILES += und-amiga.lst
|
|
|
|
amiga.mod: pre-amiga.o mod-amiga.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-amiga.o: amiga_mod-partmap_amiga.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-amiga.o: mod-amiga.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(amiga_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-amiga.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'amiga' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-amiga.lst: pre-amiga.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 amiga/' > $@
|
|
|
|
und-amiga.lst: pre-amiga.o
|
|
echo 'amiga' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
amiga_mod-partmap_amiga.o: partmap/amiga.c
|
|
$(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(amiga_mod_CFLAGS) -c -o $@ $<
|
|
|
|
amiga_mod-partmap_amiga.d: partmap/amiga.c
|
|
set -e; $(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(amiga_mod_CFLAGS) -M $< | sed 's,amiga\.o[ :]*,amiga_mod-partmap_amiga.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include amiga_mod-partmap_amiga.d
|
|
|
|
amiga_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For apple.mod
|
|
apple_mod_SOURCES = partmap/apple.c
|
|
CLEANFILES += apple.mod mod-apple.o mod-apple.c pre-apple.o apple_mod-partmap_apple.o def-apple.lst und-apple.lst
|
|
MOSTLYCLEANFILES += apple_mod-partmap_apple.d
|
|
DEFSYMFILES += def-apple.lst
|
|
UNDSYMFILES += und-apple.lst
|
|
|
|
apple.mod: pre-apple.o mod-apple.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-apple.o: apple_mod-partmap_apple.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-apple.o: mod-apple.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(apple_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-apple.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'apple' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-apple.lst: pre-apple.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 apple/' > $@
|
|
|
|
und-apple.lst: pre-apple.o
|
|
echo 'apple' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
apple_mod-partmap_apple.o: partmap/apple.c
|
|
$(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(apple_mod_CFLAGS) -c -o $@ $<
|
|
|
|
apple_mod-partmap_apple.d: partmap/apple.c
|
|
set -e; $(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(apple_mod_CFLAGS) -M $< | sed 's,apple\.o[ :]*,apple_mod-partmap_apple.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include apple_mod-partmap_apple.d
|
|
|
|
apple_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
# For pc.mod
|
|
pc_mod_SOURCES = partmap/pc.c
|
|
CLEANFILES += pc.mod mod-pc.o mod-pc.c pre-pc.o pc_mod-partmap_pc.o def-pc.lst und-pc.lst
|
|
MOSTLYCLEANFILES += pc_mod-partmap_pc.d
|
|
DEFSYMFILES += def-pc.lst
|
|
UNDSYMFILES += und-pc.lst
|
|
|
|
pc.mod: pre-pc.o mod-pc.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -R .note -R .comment $@
|
|
|
|
pre-pc.o: pc_mod-partmap_pc.o
|
|
-rm -f $@
|
|
$(LD) -r -o $@ $^
|
|
|
|
mod-pc.o: mod-pc.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(pc_mod_CFLAGS) -c -o $@ $<
|
|
|
|
mod-pc.c: moddep.lst genmodsrc.sh
|
|
sh $(srcdir)/genmodsrc.sh 'pc' $< > $@ || (rm -f $@; exit 1)
|
|
|
|
def-pc.lst: pre-pc.o
|
|
$(NM) -g --defined-only -P -p $< | sed 's/^\([^ ]*\).*/\1 pc/' > $@
|
|
|
|
und-pc.lst: pre-pc.o
|
|
echo 'pc' > $@
|
|
$(NM) -u -P -p $< | cut -f1 -d' ' >> $@
|
|
|
|
pc_mod-partmap_pc.o: partmap/pc.c
|
|
$(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(pc_mod_CFLAGS) -c -o $@ $<
|
|
|
|
pc_mod-partmap_pc.d: partmap/pc.c
|
|
set -e; $(CC) -Ipartmap -I$(srcdir)/partmap $(CPPFLAGS) $(CFLAGS) $(pc_mod_CFLAGS) -M $< | sed 's,pc\.o[ :]*,pc_mod-partmap_pc.o $@ : ,g' > $@; [ -s $@ ] || rm -f $@
|
|
|
|
-include pc_mod-partmap_pc.d
|
|
|
|
pc_mod_CFLAGS = $(COMMON_CFLAGS)
|
|
CLEANFILES += moddep.lst
|
|
pkgdata_DATA += moddep.lst
|
|
moddep.lst: $(DEFSYMFILES) $(UNDSYMFILES) genmoddep
|
|
cat $(DEFSYMFILES) /dev/null | ./genmoddep $(UNDSYMFILES) > $@ \
|
|
|| (rm -f $@; exit 1)
|