Hi, Currently, the organization of conf files are not optimal. There are a lot of duplication in *.rmk files. For example, i386-efi.rmk and x86_64-efi.rmk are basically the same, and grub-emu appears in every rmk, but there is only minor difference between each one. Also, related item are scattered around, which make it more likely for casual mistakes, like forgeting to add files in grub_emu_SOURCES, etc. Here are some of my thoughts:
1, Fine tune rmk layout rmk are split into different blocks accordding to function, such as common, commands, fs and partmap. Each block consists of generic and platform dependent parts. For example, for i386-efi, the full set of makefiles to be included is: common-i386-efi.rmk common-efi.rmk common-i386.rmk common.rmk commands-i386-efi.rmk commands-efi.rmk commands-i386.rmk commands.rmk fs-i386-efi.rmk fs-efi.rmk fs-i386.rmk fs.rmk partmap-i386-efi.rmk partmap-efi.rmk partmap-i386.rmk partmap.rmk Of course, not all of them needs to be present, we can use -include to add them to the main makefile. 2, Group related items together For example, for the fat module, we could write it like this: # For fat.mod. fat_mod_SOURCES = fs/fat.c fat_mod_CFLAGS = $(COMMON_CFLAGS) fat_mod_LDFLAGS = $(COMMON_LDFLAGS) pkglib_MODULES += fat.mod grub_probe_SOURCES += fs/fat.c grub_fstest_SOURCES += fs/fat.c grub_emu_SOURCES += fs/fat.c -- Bean _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel