grub/conf/i386-pc.rmk

302 lines
9.7 KiB
Text
Raw Normal View History

2002-12-27 08:53:07 +00:00
# -*- makefile -*-
2010-02-10 00:39:23 +00:00
COMMON_CFLAGS = -mrtd -mregparm=3
2002-12-27 08:53:07 +00:00
# Images.
2010-04-24 23:54:46 +00:00
pkglib_IMAGES = boot.img cdboot.img diskboot.img lnxboot.img pxeboot.img
2002-12-27 08:53:07 +00:00
# For boot.img.
boot_img_SOURCES = boot/i386/pc/boot.S
boot_img_ASFLAGS = $(COMMON_ASFLAGS)
boot_img_LDFLAGS = $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x7C00
boot_img_FORMAT = binary
2002-12-27 08:53:07 +00:00
# For pxeboot.img
pxeboot_img_SOURCES = boot/i386/pc/pxeboot.S
pxeboot_img_ASFLAGS = $(COMMON_ASFLAGS)
pxeboot_img_LDFLAGS = $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x7C00
pxeboot_img_FORMAT = binary
2002-12-27 08:53:07 +00:00
# For diskboot.img.
diskboot_img_SOURCES = boot/i386/pc/diskboot.S
diskboot_img_ASFLAGS = $(COMMON_ASFLAGS)
diskboot_img_LDFLAGS = $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x8000
diskboot_img_FORMAT = binary
2002-12-27 08:53:07 +00:00
# For lnxboot.img.
lnxboot_img_SOURCES = boot/i386/pc/lnxboot.S
lnxboot_img_ASFLAGS = $(COMMON_ASFLAGS)
lnxboot_img_LDFLAGS = $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x6000
lnxboot_img_FORMAT = binary
# For cdboot.img.
cdboot_img_SOURCES = boot/i386/pc/cdboot.S
cdboot_img_ASFLAGS = $(COMMON_ASFLAGS)
cdboot_img_LDFLAGS = $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x7C00
cdboot_img_FORMAT = binary
2002-12-27 08:53:07 +00:00
# For kernel.img.
2010-04-24 23:54:46 +00:00
pkglib_PROGRAMS = kernel.img
kernel_img_SOURCES = kern/i386/pc/startup.S \
kern/i386/misc.S \
kern/main.c kern/device.c \
2002-12-27 08:53:07 +00:00
kern/disk.c kern/dl.c kern/file.c kern/fs.c kern/err.c \
2010-01-07 21:18:59 +00:00
kern/misc.c kern/mm.c kern/term.c \
2009-05-02 Bean <bean123ch@gmail.com> * conf/common.rmk (grub_script.tab.c): Change normal/parser.y to script/sh/parser.y. (pkglib_MODULES): Add normal.mod and sh.mod. (normal_SOURCES): New variable. (normal_mod_CFLAGS): Likewise. (normal_mod_LDFLAGS): Likewise. (sh_mod_SOURCES): Likewise. (sh_mod_CFLAGS): Likewise. (sh_mod_LDFLAGS): Likewise. * conf/i386-pc.rmk (normal/lexer.c_DEPENDENCIES): Changed to script/sh/lexer.c_DEPENDENCIES. (kernel_img_SOURCES): Remove kern/rescue.c, and kern/reader.c, kern/rescue_reader.c and kern/rescue_parser.c. (kernel_img_HEADERS): Remove rescue.h, add reader.h. (grub_emu_SOURCES): Change source files. (pkglib_MODULES): Remove normal.mod. (normal_SOURCES): Removed. (normal_mod_CFLAGS): Likewise. (normal_mod_LDFLAGS): Likewise. * conf/i386-coreboot.rmk: Likewise. * conf/i386-efi.rmk: Likewise. * conf/i386-ieee1276.rmk: Likewise. * conf/powerpc-ieee1275.rmk: Likewise. * conf/sparc64-ieee1275.rmk: Likewise. * conf/x86_64-efi.rmk: Likewise. * include/grub/command.h (grub_command_execute): New inline function. * include/grub/menu.h (grub_menu_entry): Removed commands field. * include/grub/normal.h: Remove <grub/setjmp.h>. (grub_fs_module_list): Moved to normal/autofs.c. (grub_exit_env): Removed. (grub_command_execute): Likewise. (grub_normal_menu_addentry): Renamed to grub_menu_addentry, removed parameter script. (read_command_list): New function declaration. (read_fs_list): Likewise. * include/parser.h: Include <grub/reader.h>. (grub_parser_split_cmdline): Change type of getline parameter. (grub_parser): New structure. (grub_parser_class): New variable. (grub_parser_execute): New function declaration. (grub_register_rescue_parser): Likewise. (grub_parser_register): New inline function. (grub_parser_unregister): Likewise. (grub_parser_get_current): Likewise. (grub_parser_set_current): Likewise. * include/grub/reader.h: New file. * kern/reader.c: Likewise. * kern/rescue_parser.c: Likewise. * kern/rescue_reader.c: Likewise. * normal/autofs.c: Likewise. * normal/dyncmd.c: Likewise. * include/grub/rescue.h: Removed. * normal/command.h: Likewise. * include/grub/script.h: Moved to ... * include/grub/script_sh.h: ... Moved here. * normal/execute.c: Moved to ... * script/sh/execute.c: ... Moved here. * normal/function.c: Moved to ... * script/sh/function.c: ... Moved here. * normal/lexer.c: Moved to ... * script/sh/lexer.c: ... Moved here. * normal/parser.y: Moved to ... * script/sh/parser.y: ... Moved here. * normal/script.c: Moved to ... * script/sh/script.c: ... Moved here. * normal/main.c: Remove <grub/rescue.h> and <grub/script.h>, include <grub/reader.h>. (grub_exit_env): Removed. (fs_module_list): Moved to normal/autofs.c. (grub_file_getline): Don't handle comment here. (free_menu): Skip removed field entry->commands. (grub_normal_menu_addentry): Removed as grub_menu_entry, removed script parameter. (read_config_file): Removed nested parameter, change getline function. (grub_enter_normal_mode): Removed. (grub_dyncmd_dispatcher): Moved to normal/dyncmd.c. (read_command_list): Likewise. (autoload_fs_module): Moved to normal/autofs.c. (read_fs_list): Likewise. (reader_nested): New variable. (grub_normal_execute): Run parser.sh to switch to sh parser. (grub_cmd_rescue): Removed. (cmd_normal): Removed. (grub_cmd_normal): Unregister itself at the beginning. Don't register rescue command. (grub_cmdline_run): New function. (grub_normal_reader_init): Likewise. (grub_normal_read_line): Likewise. (grub_env_write_pager): Likewise. (cmdline): New variable. (grub_normal_reader): Likewise. (GRUB_MOD_INIT): Register normal reader and set as current, register pager hook, register normal command with grub_register_command_prio, so that it won't show up in command.lst. (GRUB_MOD_FINI): Unregister normal reader, unhook pager, clear grub_fs_autoload_hook. * normal/menu.c: Remove <grub/script.h>, add <grub/command.h>. (grub_menu_execute_entry): Replace grub_script_execute with grub_parser_execute, change parameter to grub_command_execute. * normal/menu_text.c: Remove <grub/script.h>. * normal/menu_entry.c: Remove <grub/script.h>, add <grub/command.h> and <grub/parser.h>. (run): Change editor_getline to use new parser interface. Change parameter to grub_command_execute. * kern/main.c: Remove <grub/rescue.h>, include <grub/command.h>, <grub/reader.h> and <grub/parser.h>. (grub_load_normal_mode): Execute normal command. (grub_main): Call grub_register_core_commands, grub_register_rescue_parser and grub_register_rescue_reader, use grub_reader_loop to enter input loop. * kern/parser.c (grub_parser_spli_cmdline): Change type of getline parameter. (grub_parser_class): New variable. (grub_parser_execute): New function. * loader/i386/multiboot.c: Remove <grub/rescue.h>. * loader/multiboot2.c: Likewise. * loader/sparc64/ieee1275/linux.c: Likewise. * util/grub-emu.c (read_command_list): New dummy function.
2009-05-02 19:49:34 +00:00
kern/rescue_parser.c kern/rescue_reader.c \
2010-03-26 23:19:42 +00:00
kern/time.c kern/list.c kern/command.c kern/corecmd.c \
kern/$(target_cpu)/dl.c kern/i386/pc/init.c kern/i386/pc/mmap.c \
2008-08-17 Robert Millan <rmh@aybabtu.com> * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/i386/pc/mmap.c'. * include/grub/i386/pc/init.h (GRUB_MACHINE_MEMORY_AVAILABLE) (GRUB_MACHINE_MEMORY_RESERVED): New macros. (grub_machine_mmap_iterate): New function declaration. * include/grub/multiboot.h (struct grub_multiboot_mmap_entry): New structure. (GRUB_MMAP_MEMORY_AVAILABLE, GRUB_MMAP_MEMORY_RESERVED): New macros. * kern/i386/pc/init.c (grub_machine_init): Replace hardcoded region type check value with `GRUB_MACHINE_MEMORY_AVAILABLE'. Move e820 parsing from here ... * kern/i386/pc/mmap.c: New file. (grub_machine_mmap_iterate): ... to here. * include/grub/i386/coreboot/memory.h: Remove `<grub/err.h>'. (GRUB_LINUXBIOS_MEMORY_AVAILABLE): Rename (for consistency) to ... (GRUB_MACHINE_MEMORY_AVAILABLE): ... this. Update all users. (grub_available_iterate): Redeclare to return `void', and redeclare its hook to use grub_uint64_t as addr and size parameters, and rename to ... (grub_machine_mmap_iterate): ... this. Update all users. * kern/i386/coreboot/mmap.c (grub_mmap_iterate): Simplify parser loop to make it more readable. Rename to ... (grub_machine_mmap_iterate): ... this. * loader/i386/pc/multiboot.c (mmap_addr, mmap_length): New variables. (grub_get_multiboot_mmap_len, grub_fill_multiboot_mmap): New functions. (grub_multiboot): Allocate an extra region after the payload, and fill it with a Multiboot memory map. Adjust a.out loader to calculate size with the extra space. (grub_multiboot_load_elf32): Adjust elf32 loader to calculate size with the extra space.
2008-08-17 16:32:18 +00:00
kern/parser.c kern/partition.c \
kern/i386/tsc.c kern/i386/pit.c \
2008-08-05 Colin D Bennett <colin@gibibit.com> High resolution timer support. Implemented for x86 CPUs using TSC. Extracted generic grub_millisleep() so it's linked in only as needed. This requires a Pentium compatible CPU; if the RDTSC instruction is not supported, then it falls back on the generic grub_get_time_ms() implementation that uses the machine's RTC. * conf/i386-pc.rmk (kernel_img_SOURCES): Add `kern/time.c', `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'. * conf/i386-efi.rmk (kernel_mod_SOURCES): Add `kern/i386/tsc.c', `kern/generic/rtc_get_time_ms.c' and `kern/generic/millisleep.c'. * conf/x86_64-efi.rml (kernel_mod_SOURCES): Add `kern/generic/millisleep.c' and `kern/generic/rtc_get_time_ms.c'. * conf/sparc64-ieee1275.rmk (kernel_elf_SOURCES): Likewise. * conf/powerpc-ieee1275.rmk (kernel_elf_SOURCES): Add `kern/generic/millisleep.c'. * conf/i386-ieee1275.rmk (kernel_elf_SOURCES): Likewise. * conf/i386-coreboot.rmk (kernel_elf_SOURCES): Add `kern/time.c'. * kern/generic/rtc_get_time_ms.c: New file. * kern/generic/millisleep.c: New file. * kern/misc.c: Don't include <kern/time.h> anymore. (grub_millisleep_generic): Removed. * commands/sleep.c (grub_interruptible_millisleep): Uses grub_get_time_ms() instead of grub_get_rtc(). * include/grub/i386/tsc.h (grub_get_tsc): New file. New inline function. (grub_cpu_is_cpuid_supported): New inline function. (grub_cpu_is_tsc_supported): New inline function. (grub_tsc_init): New function prototype. (grub_tsc_get_time_ms): New function prototype. * kern/i386/tsc.c (grub_get_time_ms): New file. * include/grub/time.h: Include <grub/types.h. (grub_millisleep_generic): Removed. (grub_get_time_ms): New prototype. (grub_install_get_time_ms): New prototype. (grub_rtc_get_time_ms): New prototype. * kern/time.c (grub_get_time_ms): New function. (grub_install_get_time_ms): New function. * kern/i386/efi/init.c: Include <grub/cpu/tsc.h>. Don't include <grub/time.h> anymore. (grub_millisleep): Removed. (grub_machine_init): Call grub_tsc_init. * kern/i386/linuxbios/init.c (grub_machine_init): Install the RTC get_time_ms() implementation. * kern/sparc64/ieee1275/init.c (grub_millisleep): Removed. (ieee1275_get_time_ms): New function. (grub_machine_init): Install get_time_ms() implementation. * kern/i386/pc/init.c: Include <grub/cpu/tsc.h>. (grub_machine_init): Call grub_tsc_init(). (grub_millisleep): Removed. * kern/ieee1275/init.c (grub_millisleep): Removed. (grub_machine_init): Install ieee1275_get_time_ms() implementation. (ieee1275_get_time_ms): New function. (grub_get_rtc): Now calls ieee1275_get_time_ms(), which does the real work.
2008-08-05 11:54:37 +00:00
kern/generic/rtc_get_time_ms.c \
kern/generic/millisleep.c \
kern/env.c \
2008-11-12 15:02:17 +00:00
term/i386/pc/console.c term/i386/vga_common.c \
2002-12-27 08:53:07 +00:00
symlist.c
2010-02-10 00:05:40 +00:00
kernel_img_HEADERS += machine/biosdisk.h machine/vga.h machine/vbe.h \
2010-04-26 19:11:16 +00:00
machine/pxe.h i386/pit.h machine/kernel.h
kernel_img_CFLAGS = $(COMMON_CFLAGS) $(TARGET_IMG_CFLAGS)
2002-12-27 08:53:07 +00:00
kernel_img_ASFLAGS = $(COMMON_ASFLAGS)
2010-04-26 11:11:43 +00:00
kernel_img_LDFLAGS += $(COMMON_LDFLAGS) $(TARGET_IMG_LDFLAGS)0x8200 $(COMMON_CFLAGS)
2002-12-27 08:53:07 +00:00
# Utilities.
sbin_UTILITIES = grub-setup
2002-12-27 08:53:07 +00:00
# For grub-setup.
util/i386/pc/grub-setup.c_DEPENDENCIES = grub_setup_init.h
2010-05-06 04:03:45 +00:00
grub_setup_SOURCES = gnulib/progname.c util/i386/pc/grub-setup.c \
util/misc.c kern/emu/misc.c kern/emu/getroot.c \
kern/emu/hostdisk.c kern/device.c kern/disk.c kern/err.c \
Use FOR_* macros instead of *_iterate whenever possible. * commands/handler.c: Removed. * commands/help.c (grub_cmd_help): Use FOR_COMMANDS. * commands/minicmd.c (grub_mini_cmd_lsmod): Use FOR_DL_MODULES. * conf/any-emu.rmk (kernel_img_SOURCES): Remove kern/handler.c. * conf/common.rmk (script/lexer.c_DEPENDENCIES): Add grub_script.yy.h. (grub_probe_SOURCES): Remove kern/parser.c. (util/grub-script-check.c_DEPENDENCIES): Removed. (grub_script_check_SOURCES): Remove kern/handler.c, kern/parser.c and grub_script_check_init.c. (grub_script_check_init.lst): Removed. (grub_script_check_init.h): Likewise. (grub_script_check_init.c): Likewise. (pkglib_MODULES): Remove handler.mod and sh.mod. (handler_mod_SOURCES): Removed. (handler_mod_CFLAGS): Likewise. (handler_mod_LDFLAGS): Likewise. (normal_mod_SOURCES): Remove normal/handler.c. Add script/main.c, script/script.c, script/execute.c, script/function.c, script/lexer.c, grub_script.tab.c and grub_script.yy.c. * conf/i386-coreboot.rmk (kernel_img_SOURCES): Remove kern/handler.c. * conf/i386-ieee1275.rmk (kernel_img_SOURCES): Likewise. * conf/i386-pc.rmk (kernel_img_SOURCES): Likewise. (grub_setup_SOURCES): Remove kern/parser.c. * conf/i386-qemu.rmk (kernel_img_SOURCES): Remove kern/handler.c. * conf/mips-qemu-mips.rmk (kernel_img_SOURCES): Likewise. * conf/mips-yeeloong.rmk (kernel_img_SOURCES): Likewise. * conf/powerpc-ieee1275.rmk (kernel_img_SOURCES): Likewise. * conf/sparc64-ieee1275.rmk (kernel_img_SOURCES): Likewise. (grub_setup_SOURCES): Remove kern/parser.c. * conf/x86-efi.rmk (kernel_img_SOURCES): Remove kern/handler.c. * gettext/gettext.c (grub_gettext_delete_list): Don't use grub_list_pop. * include/grub/command.h (grub_command_iterate): Removed. (FOR_COMMANDS): New macro. * include/grub/dl.h (grub_dl): New member next. (grub_dl_iterate): Removed. (grub_dl_head): New variable declaration. (FOR_DL_MODULES): New macro. * include/grub/fs.h: Include list.h. (grub_fs): Make next first element. (grub_fs_list): New variable declaration. (grub_fs_register): Make inline. (grub_fs_unregister): Likewise. (grub_fs_iterate): Removed. (FOR_FILESYSTEMS): New macro. * include/grub/handler.h: Removed. * include/grub/list.h (grub_list_hook_t): Removed. (grub_list_test_t): Likewise. (grub_list_pop): Likewise. (grub_list_iterate): Likewise. (grub_list_insert): Likewise. (FOR_LIST_ELEMENTS): New macro. * include/grub/parser.h (grub_parser_class): Removed. (grub_parser_register): Likewise. (grub_parser_unregister): Likewise. (grub_parser_get_current): Likewise. (grub_parser_set_current): Likewise. (grub_register_rescue_parser): Likewise. (grub_rescue_parse_line): New function. * include/grub/partition.h (FOR_PARTITION_MAPS): Use FOR_LIST_ELEMENTS. * include/grub/script_sh.h (grub_script_function_list): New variable declaration. (FOR_SCRIPT_FUNCTIONS): New macro. (grub_script_function_iterate): Removed. (grub_normal_parse_line): New prototype. * include/grub/term.h (FOR_ACTIVE_TERM_INPUTS): Use FOR_LIST_ELEMENTS. (FOR_DISABLED_TERM_INPUTS): Likewise. (FOR_ACTIVE_TERM_OUTPUTS): Likewise. (FOR_DISABLED_TERM_OUTPUTS): Likewise. * include/grub/video.h (grub_video_adapter): Move 'next' to first element. (grub_video_register): Inline. (grub_video_unregister): Likewise. (grub_video_adapter_list): New variable declaration. (grub_video_iterate): Removed. (FOR_VIDEO_ADAPTERS): New macro. * kern/dl.c (grub_dl_list): Removed. All users updated. (grub_dl_iterate): Removed. * kern/fs.c (grub_fs_list): Make global. (grub_fs_register): Removed. (grub_fs_unregister): Likewise. (grub_fs_iterate): Likewise. * kern/handler.c: Removed. * kern/list.c (grub_list_pop): Removed. (grub_list_iterate): Likewise. (grub_list_insert): Likewise. (grub_named_list_find): Use FOR_LIST_ELEMENTS. (grub_prio_list_insert): Don't use grub_list_insert. * kern/main.c (grub_register_rescue_parser): Don't call grub_register_rescue_parser. * kern/parser.c (grub_parser_class): Removed. (grub_parser_execute): Use grub_rescue_parse_line. * kern/rescue_parser.c (grub_rescue_parse_line): Make global. (grub_rescue_parser): Removed. (grub_register_rescue_parser): Likewise. * kern/rescue_reader.c (grub_rescue_run): Use grub_rescue_parse_line. * normal/auth.c (is_authenticated): Use FOR_LIST_ELEMENTS. (grub_auth_check_authentication): Likewise. * normal/completion.c (iterate_command): Removed. (grub_normal_do_completion): Use FOR_COMMANDS. * normal/handler.c: Removed. * normal/main.c (read_config_file): Remove parser changing. (grub_normal_execute): Don't call read_handler_list. (grub_normal_read_line_real): Statically allocate prompt. (grub_cmdline_run): Use grub_normal_parse_line. (GRUB_MOD_FINI): Don't call free_handler_list. * normal/menu_entry.c (run): Likewise. * script/function.c (grub_script_function_list): Make global. (grub_script_function_iterate): Removed. * script/main.c (grub_normal_parse_line): Make global. (grub_sh_parser): Removed. (GRUB_MOD_INIT): Likewise. (GRUB_MOD_FINI): Likewise. * tests/lib/functional_test.c (grub_functional_test): Use FOR_LIST_ELEMENTS. * tests/lib/test.c (free_failures): Don't use grub_list_pop. (grub_test_run): Use FOR_LIST_ELEMENTS. * tests/lib/unit_test.c (main): Likewise. * util/deviceiter.c (grub_util_iterate_devices): Don't use grub_list_pop. * util/grub-fstest.c (grub_term_input_class): Removed. (grub_term_output_class): Likewise. * util/grub-probe.c: Likewise. * util/i386/pc/grub-setup.c: Likewise. * util/sparc64/ieee1275/grub-setup.c: Likewise. * util/grub-script-check.c (main): Don't call grub_init_all and grub_fini_all. * video/video.c (grub_video_adapter_list): Make global. (grub_video_register): Removed. (grub_video_unregister): Likewise. (grub_video_iterate): Likewise.
2010-06-11 20:31:16 +00:00
kern/misc.c kern/partition.c kern/file.c \
2010-05-06 04:03:45 +00:00
kern/emu/mm.c kern/fs.c kern/env.c kern/list.c fs/fshelp.c \
\
fs/affs.c fs/cpio.c fs/ext2.c fs/fat.c fs/hfs.c \
fs/hfsplus.c fs/iso9660.c fs/udf.c fs/jfs.c fs/minix.c \
fs/nilfs2.c fs/ntfs.c fs/ntfscomp.c fs/reiserfs.c \
fs/sfs.c fs/ufs.c fs/ufs2.c fs/xfs.c fs/afs.c \
fs/afs_be.c fs/befs.c fs/befs_be.c fs/tar.c \
\
partmap/msdos.c partmap/bsdlabel.c partmap/sunpc.c \
partmap/gpt.c \
\
disk/raid.c disk/raid5_recover.c disk/raid6_recover.c \
disk/mdraid_linux.c disk/lvm.c \
2010-05-06 04:03:45 +00:00
util/raid.c util/lvm.c \
grub_setup_init.c
2003-11-17 Marco Gerards <metgerards@student.han.nl> * conf/i386-pc.rmk (sbin_UTILITIES): Added pupa-emu. (pupa_setup_SOURCES): Added util/i386/pc/getroot.c. (pupa_emu_SOURCES): New variable. (pupa_emu_LDFLAGS): Likewise. * include/pupa/fs.h (pupa_ext2_init) [PUPA_UTIL]: New prototype. (pupa_ext2_fini) [PUPA_UTIL]: Likewise. * include/pupa/normal.h (pupa_normal_init) [PUPA_UTIL]: Likewise. (pupa_normal_fini) [PUPA_UTIL]: Likewise. * include/pupa/setjmp.h [PUPA_UTIL]: Include <setjmp.h>. (pupa_jmp_buf): New typedef. (pupa_setjmp) [PUPA_UTIL]: New macro. (pupa_longjmp) [PUPA_UTIL]: Likewise. * include/pupa/term.h (struct pupa_term): New member `refresh'. (pupa_refresh): New prototype. * include/pupa/util/getroot.h: New file. * kern/misc.c (pupa_vsprintf): Refresh the screen after updating it. * kern/rescue.c (pupa_rescue_get_command_line): Likewise. (pupa_rescue_cmd_cat): Likewise. (pupa_rescue_cmd_ls): Likewise. (pupa_rescue_cmd_testload): Likewise. (pupa_rescue_cmd_lsmod): Likewise. * normal/cmdline.c (pupa_cmdline_get): Likewise. * normal/menu.c (run_menu): Likewise. * kern/term.c (pupa_cls): Likewise. (pupa_refresh): New function. * normal/normal.c (pupa_normal_init) [PUPA_UTIL]: New function. (pupa_normal_fini) [PUPA_UTIL]: Likewise. * util/console.c: New file. * util/i386/pc/getroot.c: New file. * util/i386/pc/pupa-setup.c: Include <pupa/util/getroot.h>. (pupa_putchar): New function. (pupa_refresh): Likewise. (xgetcwd): Function moved to ... (strip_extra_slashes): Likewise. (get_prefix): Likewise. * util/i386/pc/getroot.c: ... here. (find_root_device): Function moved and renamed to... * util/i386/pc/getroot.c (pupa_find_root_device): ... here. Changed all callers. * util/i386/pc/pupa-setup.c (guess_root_device): Function moved and renamed to... * util/i386/pc/getroot.c (pupa_guess_root_device): ... here. Changed all callers. * util/misc.c (pupa_memalign): New function. (pupa_mm_init_region): Likewise. (pupa_register_exported_symbols): Likewise. (pupa_putchar): Function removed. * util/pupa-emu.c: New file.
2003-11-17 18:07:09 +00:00
sbin_SCRIPTS += grub-install
grub_install_SOURCES = util/grub-install.in
bin_SCRIPTS += grub-mkrescue
grub_mkrescue_SOURCES = util/grub-mkrescue.in
pkglib_MODULES = biosdisk.mod chain.mod \
2010-02-07 22:49:49 +00:00
halt.mod \
vbe.mod vbetest.mod vbeinfo.mod \
vga.mod \
aout.mod bsd.mod pxe.mod pxecmd.mod datetime.mod \
ata_pthru.mod hdparm.mod \
2009-05-02 Vladimir Serbinenko <phcoder@gmail.com> Mmap services * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate * loader/i386/linux.c (find_mmap_size): likewise (allocate_pages): likewise * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise (grub_fill_multiboot_mmap): likewise (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition (OPENBSD_MMAP_RESERVED): likewise * include/grub/i386/pc/memory.h: include grub/memory.h (grub_lower_mem): removed (grub_upper_mem): likewise (GRUB_MACHINE_MEMORY_ACPI): new definition (GRUB_MACHINE_MEMORY_NVS): likewise (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise (GRUB_MACHINE_MEMORY_HOLE): likewise (grub_machine_mmap_register): likewise (grub_machine_mmap_unregister): likewise (grub_machine_get_upper): likewise (grub_machine_get_lower): likewise (grub_machine_get_post64): likewise * include/grub/i386/efi/memory.h: new file * include/grub/x86_64/efi/memory.h: likewise * include/grub/efi/memory.h: likewise * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod (mmap_mod_SOURCES): new variable (mmap_mod_LDFLAGS): likewise (mmap_mod_ASFLAGS): likewise * conf/i386-coreboot.rmk: likewise * conf/i386-ieee1275.rmk: likewise * conf/i386-efi.rmk: likewise * conf/x86_64-efi.rmk: likewise * include/grub/types.h (UINT_TO_PTR): new macro (PTR_TO_UINT32): likewise (PTR_TO_UINT64): likewise * include/grub/memory.h: new file * mmap/i386/pc/mmap.c: likewise * mmap/i386/pc/mmap_helper.S: likewise * mmap/i386/uppermem.c: likewise * mmap/mmap.c: likewise * mmap/efi/mmap.c: likewise * kern/i386/coreboot/init.c (grub_machine_init): don't use grub_upper_mem * kern/i386/pc/init.c (grub_lower_mem): removed variable (grub_upper_mem): likewise (grub_machine_init): don't use grub_upper_mem, make grub_lower_mem local * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower, grub_mmap_iterate and grub_mmap_get_upper (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
2009-05-02 21:46:34 +00:00
usb.mod uhci.mod ohci.mod usbtest.mod usbms.mod usb_keyboard.mod \
efiemu.mod mmap.mod acpi.mod drivemap.mod
# For drivemap.mod.
drivemap_mod_SOURCES = commands/i386/pc/drivemap.c \
commands/i386/pc/drivemap_int13h.S
drivemap_mod_ASFLAGS = $(COMMON_ASFLAGS)
drivemap_mod_CFLAGS = $(COMMON_CFLAGS)
drivemap_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For efiemu.mod.
efiemu_mod_SOURCES = efiemu/main.c efiemu/i386/loadcore32.c \
efiemu/i386/loadcore64.c efiemu/i386/pc/cfgtables.c \
efiemu/mm.c efiemu/loadcore_common.c efiemu/symbols.c \
efiemu/loadcore32.c efiemu/loadcore64.c \
efiemu/prepare32.c efiemu/prepare64.c efiemu/pnvram.c \
efiemu/i386/coredetect.c
efiemu_mod_CFLAGS = $(COMMON_CFLAGS)
efiemu_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For acpi.mod.
acpi_mod_SOURCES = commands/acpi.c commands/i386/pc/acpi.c
acpi_mod_CFLAGS = $(COMMON_CFLAGS)
acpi_mod_LDFLAGS = $(COMMON_LDFLAGS)
2009-05-02 Vladimir Serbinenko <phcoder@gmail.com> Mmap services * loader/i386/efi/linux.c (grub_linux_boot): use grub_mmap_iterate * loader/i386/linux.c (find_mmap_size): likewise (allocate_pages): likewise * loader/i386/multiboot.c (grub_get_multiboot_mmap_len): likewise (grub_fill_multiboot_mmap): likewise (grub_multiboot): use grub_mmap_get_lower and grub_mmap_get_upper * loader/i386/pc/linux.c (grub_cmd_linux): use grub_mmap_get_lower * include/grub/i386/bsd.h (OPENBSD_MMAP_AVAILABLE): new definition (OPENBSD_MMAP_RESERVED): likewise * include/grub/i386/pc/memory.h: include grub/memory.h (grub_lower_mem): removed (grub_upper_mem): likewise (GRUB_MACHINE_MEMORY_ACPI): new definition (GRUB_MACHINE_MEMORY_NVS): likewise (GRUB_MACHINE_MEMORY_MAX_TYPE): likewise (GRUB_MACHINE_MEMORY_HOLE): likewise (grub_machine_mmap_register): likewise (grub_machine_mmap_unregister): likewise (grub_machine_get_upper): likewise (grub_machine_get_lower): likewise (grub_machine_get_post64): likewise * include/grub/i386/efi/memory.h: new file * include/grub/x86_64/efi/memory.h: likewise * include/grub/efi/memory.h: likewise * conf/i386-pc.rmk (pkglib_MODULES): added mmap.mod (mmap_mod_SOURCES): new variable (mmap_mod_LDFLAGS): likewise (mmap_mod_ASFLAGS): likewise * conf/i386-coreboot.rmk: likewise * conf/i386-ieee1275.rmk: likewise * conf/i386-efi.rmk: likewise * conf/x86_64-efi.rmk: likewise * include/grub/types.h (UINT_TO_PTR): new macro (PTR_TO_UINT32): likewise (PTR_TO_UINT64): likewise * include/grub/memory.h: new file * mmap/i386/pc/mmap.c: likewise * mmap/i386/pc/mmap_helper.S: likewise * mmap/i386/uppermem.c: likewise * mmap/mmap.c: likewise * mmap/efi/mmap.c: likewise * kern/i386/coreboot/init.c (grub_machine_init): don't use grub_upper_mem * kern/i386/pc/init.c (grub_lower_mem): removed variable (grub_upper_mem): likewise (grub_machine_init): don't use grub_upper_mem, make grub_lower_mem local * loader/i386/bsd.c (grub_openbsd_boot): use grub_mmap_get_lower, grub_mmap_iterate and grub_mmap_get_upper (grub_netbsd_boot): use grub_mmap_get_lower and grub_mmap_get_upper
2009-05-02 21:46:34 +00:00
# For mmap.mod.
mmap_mod_SOURCES = mmap/mmap.c mmap/i386/uppermem.c mmap/i386/mmap.c \
mmap/i386/pc/mmap.c mmap/i386/pc/mmap_helper.S
mmap_mod_CFLAGS = $(COMMON_CFLAGS)
mmap_mod_LDFLAGS = $(COMMON_LDFLAGS)
mmap_mod_ASFLAGS = $(COMMON_ASFLAGS)
2002-12-27 08:53:07 +00:00
# For biosdisk.mod.
biosdisk_mod_SOURCES = disk/i386/pc/biosdisk.c
biosdisk_mod_CFLAGS = $(COMMON_CFLAGS)
biosdisk_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For chain.mod.
2009-03-21 Bean <bean123ch@gmail.com> * commands/blocklist.c: Add include file <grub/command.h>, remove <grub/normal.h> and <grub/arg.h>. (grub_cmd_blocklist): Use the new command interface. (GRUB_MOD_INIT): Likewise. (GRUB_MOD_FINI): Likewise. * commands/boot.c: Likewise. * commands/cat.c: Likewise. * commands/cmp.c: Likewise. * commands/configfile.c: Likewise. * commands/crc.c: Likewise. * commands/echo.c: Likewise. * commands/halt.c: Likewise. * commands/handler.c: Likewise. * commands/hdparm.c: Likewise. * commands/help.c: Likewise. * commands/hexdump.c: Likewise. * commands/loadenv.c: Likewise. * commands/ls.c: Likewise. * commands/lsmmap.c: Likewise. * commands/lspci.c: Likewise. * commands/loadenv.c: Likewise. * commands/read.c: Likewise. * commands/reboot.c: Likewise. * commands/search.c: Likewise. * commands/sleep.c: Likewise. * commands/test.c: Likewise. * commands/usbtest.c: Likewise. * commands/videotest.c: Likewise. * commands/i386/cpuid.c: Likewise. * commands/i386/pc/halt.c: Likewise. * commands/i386/pc/play.c: Likewise. * commands/i386/pc/pxecmd.c: Likewise. * commands/i386/pc/vbeinfo.c: Likewise. * commands/i386/pc/vbetest.c: Likewise. * commands/ieee1275/suspend.c: Likewise. * disk/loopback.c: Likewise. * font/font_cmd.c: Likewise. * hello/hello.c: Likewise. * loader/efi/appleloader.c: Likewise. * loader/efi/chainloader.c: Likewise. * loader/i386/bsd.c: Likewise. * loader/i386/efi/linux.c: Likewise. * loader/i386/ieee1275/linux.c: Likewise. * loader/i386/linux.c: Likewise. * loader/i386/pc/chainloader.c: Likewise. * loader/i386/pc/linux.c: Likewise. * loader/powerpc/ieee1275/linux.c: Likewise. * loader/multiboot_loader.c: Likewise. * term/gfxterm.c: Likewise. * term/i386/pc/serial.c: Likewise. * term/terminfo.c: Likewise. * term/i386/pc/vesafb.c: Removed <grub/arg.h>. * term/i386/pc/vga.c: Likewise. * video/readers/jpeg.c: Likewise. * video/readers/png.c: Likewise. * video/readers/tga.c: Likewise. * util/grub-fstest (cmd_loopback): Removed. (cmd_blocklist): Likewise. (cmd_ls): Likewise. (grub_register_command): Likewise. (grub_unregister_command): Likewise. (execute_command): Use grub_command_find to locate command and execute it. * include/grub/efi/chainloader.h: Removed. * loader/efi/chainloader_normal.c: Likewise. * loader/i386/bsd_normal.c: Likewise. * loader/i386/pc/chainloader_normal.c: Likewise. * loader/i386/pc/multiboot_normal.c: Likewise. * loader/linux_normal.c: Likewise. * loader/multiboot_loader_normal.c: Likewise. * loader/powerpc/ieee1275/linux_normal.c: Likewise. * gencmdlist.sh: Scan new registration command grub_register_extcmd and grub_register_command_p1. * conf/common.rmk (grub_fstest_SOURCES): Add kern/list.c, kern/command.c, lib/arg.c and commands/extcmd.c. (pkglib_MODULES): Remove boot.mod, and minicmd.mod and extcmd.mod. (minicmd_mod_SOURCES): New variable. (minicmd_mod_CFLAGS): Likewise. (minicmd_mod_LDFLAGS): Likewise. (extcmd_mod_SOURCES): Likewise. (extcmd_mod_CFLAGS): Likewise. (extcmd_mod_LDFLAGS): Likewise. (boot_mod_SOURCES): Removed. (boot_mod_CFLAGS): Likewise. (boot_mod_LDFLAGS): Likewise. * conf/i386-pc.rmk (kernel_img_SOURCES): Add kern/command.c and kern/corecmd.c. (kernel_img_HEADERS): Add command.h. (grub_emu_SOURCES): Remove commands/boot.c and normal/arg.c, add commands/minicmd.c, kern/command.c, kern/corecmd.c, commands/extcmd.c and lib/arg.c. (pkglib_MODULES): Change _linux.mod, _chain.mod, _bsd.mod and _multiboot.mod as linux.mod, chain.mod, bsd.mod and multiboot.mod, remove the corresponding normal mode command. (normal_mod_SOURCES): Remove normal/arg.c. * conf/i386-coreboot.rmk: Likewise. * conf/i386-efi.rmk: Likewise. * conf/i386-ieee1275.rmk: Likewise. * conf/powerpc-ieee1275.rmk: Likewise. * conf/x86_64-efi.rmk: Likewise. * include/grub/arg.h: Move from here ... * include/grub/lib/arg.h: ... to here. * normal/arg.c: Move from here ... * lib/arg.c: ... to here. * commands/extcmd.c: New file. * commands/minicmd.c: Likewise. * include/grub/command.h: Likewise. * include/grub/extcmd.h: Likewise. * kern/command.c: Likewise. * kern/corecmd.c: Likewise. * kern/list.c (grub_list_iterate): Return int instead of void. (grub_list_insert): New function. (grub_prio_list_insert): Likewise. * kern/rescue.c (grub_rescue_command): Removed. (grub_rescue_command_list): Likewise. (grub_rescue_register_command): Likewise. (grub_rescue_unregister_command): Likewise. (grub_rescue_cmd_boot): Move to minicmd.c (grub_rescue_cmd_help): Likewise. (grub_rescue_cmd_info): Likewise. (grub_rescue_cmd_boot): Likewise. (grub_rescue_cmd_testload): Likewise. (grub_rescue_cmd_dump): Likewise. (grub_rescue_cmd_rmmod): Likewise. (grub_rescue_cmd_lsmod): Likewise. (grub_rescue_cmd_exit): Likewise. (grub_rescue_print_devices): Moved to corecmd.c. (grub_rescue_print_files): Likewise. (grub_rescue_cmd_ls): Likewise. (grub_rescue_cmd_insmod): Likewise. (grub_rescue_cmd_set): Likewise. (grub_rescue_cmd_unset): Likewise. (attemp_normal_mode): Use grub_command_find to get normal module. (grub_enter_rescue_mode): Use grub_register_core_commands to register commands, remove grub_rescue_regiter_command calls. * normal/command.c (grub_regiser_command): Removed. (grub_unregister_command): Likewise. (grub_command_find): Likewise. (grub_iterate_commands): Likewise. (rescue_command): Likewise. (export_command): Moved to corecmd.c. (set_command): Removed. (unset_command): Likewise. (insmod_command): Likewise. (rmmod_command): Likewise. (lsmod_command): Likewise. (grub_command_init): Likewise. * normal/completion.c (iterate_command): Use cmd->prio to check for active command. (complete_arguments): Use grub_extcmd_t structure to find options. (grub_normal_do_completion): Change function grub_iterate_commands to grub_command_iterate. * normal/execute.c (grub_script_execute_cmd): No need to parse argument here. * normal/main.c (grub_dyncmd_dispatcher): New function. (read_command_list): Register unload commands as dyncmd. (grub_cmd_normal): Use new command interface, register rescue, unregister normal at entry, register normal, unregister rescue at exit. * include/grub/list.h (grub_list_test_t): New type. (grub_list_iterate): Return int instead of void. (grub_list_insert): New function. (GRUB_AS_NAMED_LIST_P): New macro. (GRUB_AS_PRIO_LIST): Likewise. (GRUB_AS_PRIO_LIST_P): Likewise. (GRUB_PRIO_LIST_PRIO_MASK): New constant. (GRUB_PRIO_LIST_FLAG_ACTIVE): Likewise. (grub_prio_list): New structure. (grub_prio_list_insert): New function. (grub_prio_list_remove): New inline function. * include/grub/normal.h: Remove <grub/arg.h>, add <grub/command.h>. (GRUB_COMMAND_FLAG_CMDLINE): Moved to command.h. (GRUB_COMMAND_FLAG_MENU): Likewise. (GRUB_COMMAND_FLAG_BOTH): Likewise. (GRUB_COMMAND_FLAG_TITLE): Likewise. (GRUB_COMMAND_FLAG_NO_ECHO): Likewise. (GRUB_COMMAND_FLAG_NO_ARG_PARSE): Removed. (GRUB_COMMAND_FLAG_NOT_LOADED): Likewise. (grub_command): Likewise. (grub_register_command): Likewise. (grub_command_find): Likewise. (grub_iterate_commands): Likewise. (grub_command_init): Likewise. (grub_arg_parse): Likewise. (grub_arg_show_help): Likewise. * include/grub/rescue.h (grub_rescue_register_command): Removed. (grub_rescue_unregister_command): Likewise. * include/grub/i386/bsd.h: Remove grub_rescue_cmd_freebsd, grub_rescue_cmd_openbsd, grub_rescue_cmd_netbsd, grub_rescue_cmd_freebsd_loadenv and grub_rescue_cmd_freebsd_module. * include/grub/i386/efi/loader.h: Remove grub_rescue_cmd_linux and grub_rescue_cmd_initrd. * include/grub/i386/loader.h: Likewise. * include/grub/x86_64/loader.h: Likewise. * include/grub/i386/pc/chainloader.h: Remove grub_chainloader_cmd.
2009-03-21 08:39:59 +00:00
chain_mod_SOURCES = loader/i386/pc/chainloader.c
chain_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
chain_mod_LDFLAGS = $(COMMON_LDFLAGS)
pkglib_MODULES += linux16.mod
linux16_mod_SOURCES = loader/i386/pc/linux.c
linux16_mod_CFLAGS = $(COMMON_CFLAGS)
linux16_mod_LDFLAGS = $(COMMON_LDFLAGS)
pkglib_MODULES += linux.mod
linux_mod_SOURCES = loader/i386/linux.c
linux_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
linux_mod_LDFLAGS = $(COMMON_LDFLAGS)
2003-01-20 Yoshinori K. Okuji <okuji@enbug.org> * include/pupa/normal.h: New file. * include/pupa/setjmp.h: Likewise. * include/pupa/i386/setjmp.h: Likewise. * normal/cmdline.c: Likewise. * normal/command.c: Likewise. * normal/main.c: Likewise. * normal/menu.c: Likewise. * normal/i386/setjmp.S: Likewise. * loader/i386/pc/linux.c (pupa_rescue_cmd_linux): Made global. (pupa_rescue_cmd_initrd): Likewise. * loader/i386/pc/chainloader.c (pupa_rescue_cmd_chainloader): Likewise. * kern/i386/pc/startup.S (translation_table): New variable. (translate_keycode): New function. (pupa_console_getkey): Call translate_keycode. * kern/rescue.c (attempt_normal_mode): New function. (pupa_enter_rescue_mode): Attempt to execute the normal mode. If it failed, print a message. * kern/mm.c (pupa_real_malloc): Print more information when a free magic is broken. (pupa_free): If the first free header is not free actually, set it to P. * kern/main.c (pupa_load_normal_mode): Just load the module "normal". (pupa_main): Don't print the message "Entering into rescue mode..." here. * include/pupa/i386/pc/loader.h (pupa_rescue_cmd_initrd): Declared. (pupa_rescue_cmd_initrd): Likewise. (pupa_rescue_cmd_initrd): Likewise. * include/pupa/symbol.h (FUNCTION): Specify the type. (VARIABLE): Likewise. * include/pupa/err.h (pupa_err_t): Added PUPA_ERR_UNKNOWN_COMMAND. * include/pupa/dl.h (pupa_dl_set_prefix): Exported. (pupa_dl_get_prefix): Likewise. * conf/i386-pc.rmk (pkgdata_MODULES): Added normal.mod. Added _chain.mod and _linux.mod instead of chain.mod and linux.mod. (chain_mod_SOURCES): Renamed to ... (_chain_mod_SOURCES): ... this. (chain_mod_CFLAGS): Renamed to ... (_chain_mod_CFLAGS): ... this. (linux_mod_SOURCES): Renamed to ... (_linux_mod_SOURCES): ... this. (linux_mod_CFLAGS): Renamed to ... (_linux_mod_CFLAGS): ... this. (normal_mod_SOURCES): New variable. (normal_mod_CFLAGS): Likewise. (normal_mod_ASFLAGS): Likewise. 2003-01-18 Yoshinori K. Okuji <okuji@enbug.org> * kern/rescue.c (pupa_rescue_cmd_rmmod): Call pupa_dl_unload, if possible. * kern/dl.c (pupa_dl_ref): Refer dependending modules recursively. (pupa_dl_unref): Unrefer depending modules recursively. Don't call pupa_dl_unload implicitly, because PUPA can crash if a module is unloaded before one depending on that module is unloaded. (pupa_dl_unload): Unload depending modules explicitly, if possible.
2003-01-20 04:13:46 +00:00
pkglib_MODULES += xnu.mod
2009-12-16 18:04:58 +00:00
xnu_mod_SOURCES = loader/xnu_resume.c loader/i386/xnu.c \
2009-12-18 02:57:32 +00:00
loader/macho32.c loader/macho64.c loader/macho.c loader/xnu.c
xnu_mod_CFLAGS = $(COMMON_CFLAGS)
xnu_mod_LDFLAGS = $(COMMON_LDFLAGS)
xnu_mod_ASFLAGS = $(COMMON_ASFLAGS)
# For halt.mod.
halt_mod_SOURCES = commands/i386/pc/halt.c
halt_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
halt_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For vbe.mod.
2009-08-14 Vladimir Serbinenko <phcoder@gmail.com> Framebuffer split. * commands/i386/pc/vbetest.c (grub_cmd_vbetest): Restore video subsystem at the end. * conf/common.rmk (pkglib_MODULES): Add video_fb.mod. (video_fb_mod_SOURCES): New variable. (video_fb_mod_CFLAGS): Likewise. (video_fb_mod_LDFLAGS): Likewise. * conf/i386-pc.rmk (vbe_mod_SOURCES): Remove video/i386/pc/vbeblit.c, video/i386/pc/vbefill.c and video/i386/pc/vbeutil.c. * video/i386/pc/vbeblit.c: Moved from here ... * video/fb/fbblit.c: ..here. Replaced 'vbe' with 'fb'. * video/i386/pc/vbefill.c: Moved from here ... * video/fb/fbfill.c: ..here. Replaced 'vbe' with 'fb'. * video/i386/pc/vbeutil.c: Moved from here ... * video/fb/fbutil.c: ..here. Replaced 'vbe' with 'fb'. * include/grub/i386/pc/vbeblit.h: Moved from here ... * include/grub/fbblit.h: ... here. Replaced 'vbe' with 'fb'. * include/grub/i386/pc/vbefill.h: Moved from here ... * include/grub/fbfill.h: ... here. Replaced 'vbe' with 'fb'. * include/grub/i386/pc/vbeutil.h: Moved from here ... * include/grub/fbutil.h: ... here. Replaced 'vbe' with 'fb'. * include/grub/i386/pc/vbe.h: Moved framebuffer part ... * include/grub/video_fb.h: ... here. Replaced 'vbe' with 'fb'. * include/grub/video.h (GRUB_VIDEO_RENDER_TARGET_FRONT_BUFFER): Removed. (GRUB_VIDEO_RENDER_TARGET_BACK_BUFFER): Likewise. (grub_video_adapter): Added 'get_info_and_fini'. (grub_video_get_info_and_fini): New prototype. (grub_video_set_mode): make modestring const char *. * loader/i386/linux.c (grub_linux_setup_video): Use grub_video_get_info_and_fini. (grub_linux_boot): Move modesetting just before booting. * loader/i386/pc/xnu.c (grub_xnu_set_video): Use grub_video_get_info_and_fini. * video/i386/pc/vbe.c: Moved framebuffer part ... * video/fb/video_fb.c: ... here. Replaced 'vbe' with 'fb'. * video/i386/pc/vbe.c (grub_vbe_set_video_mode): Use grub_video_fbstd_colors and grub_video_fb_set_palette. (grub_video_vbe_init): Clear 'framebuffer' variable and use grub_video_fb_init. (grub_video_vbe_fini): Use grub_video_fb_fini. (grub_video_vbe_setup): Use framebuffer.render_target instead of render_target and use grub_video_fb_set_active_render_target and grub_video_fb_set_palette. (grub_video_vbe_set_palette): Use grub_video_fb_set_palette. (grub_video_vbe_set_viewport): Use grub_video_fb_set_viewport. (grub_video_vbe_adapter): Use framebuffer. * video/video.c (grub_video_get_info_and_fini): New function. (grub_video_set_mode): Make modestring const char *. (GRUB_MOD_INIT(video_video)): Don't set variables to 0 since these values are already initialised.
2009-08-14 12:41:58 +00:00
vbe_mod_SOURCES = video/i386/pc/vbe.c
vbe_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
vbe_mod_LDFLAGS = $(COMMON_LDFLAGS)
2005-08-19 Yoshinori K. Okuji <okuji@enbug.org> * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and commands/i386/pc/vbetest.c. * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL, call grub_vbe_get_controller_info again, because the returned information is volatile. (grub_vbe_set_video_mode): Mostly rewritten. (grub_vbe_get_video_mode): Use grub_vbe_probe and use grub_vbe_status_t correctly. (grub_vbe_get_video_mode_info): Likewise. (grub_vbe_set_pixel_rgb): Use a switch statement rather than several if statements. * commands/i386/pc/vbe_list_modes.c: Renamed to ... * commands/i386/pc/vbeinfo.c: ... this. * commands/i386/pc/vbe_test.c: Renamed to ... * commands/i386/pc/vbetest.c: ... this. * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to ... (grub_cmd_vbeinfo): ... this. Save video modes before iterating. Skip a video mode, if it is not available, not enough information is given or it is monochrome. Show the memory model. Leave the interpretation of MODEVAR to grub_strtoul completely. (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo. (GRUB_MOD_FINI): Likewise. * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ... (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a duplicated grub_env_get. Leave the interpretation of MODEVAR to grub_strtoul completely. (real2pm): Removed. (GRUB_MOD_INIT): Rename vbe_test to vbetest. (GRUB_MOD_FINI): Likewise. * normal/misc.c: Include grub/mm.h. * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and vbe_list_modes with vbetest.mod and vbeinfo.mod. (vbe_list_modes_mod_SOURCES): Removed. (vbe_list_modes_mod_CFLAGS): Likewise. (vbe_test_mod_SOURCES): Likewise. (vbe_test_mod_CFLAGS): Likewise. (vbeinfo_mod_SOURCES): New variable. (vbeinfo_mod_CFLAGS): Likewise. (vbetest_mod_SOURCES): Likewise. (vbetest_mod_CFLAGS): Likewise.
2005-08-19 00:32:01 +00:00
# For vbeinfo.mod.
vbeinfo_mod_SOURCES = commands/i386/pc/vbeinfo.c
vbeinfo_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
vbeinfo_mod_LDFLAGS = $(COMMON_LDFLAGS)
2005-08-19 Yoshinori K. Okuji <okuji@enbug.org> * DISTLIST: Replace commands/i386/pc/vbe_list_modes.c and commands/i386/pc/vbe_test.c with commands/i386/pc/vbeinfo.c and commands/i386/pc/vbetest.c. * video/i386/pc/vbe.c (grub_vbe_probe): If INFOBLOCK is not NULL, call grub_vbe_get_controller_info again, because the returned information is volatile. (grub_vbe_set_video_mode): Mostly rewritten. (grub_vbe_get_video_mode): Use grub_vbe_probe and use grub_vbe_status_t correctly. (grub_vbe_get_video_mode_info): Likewise. (grub_vbe_set_pixel_rgb): Use a switch statement rather than several if statements. * commands/i386/pc/vbe_list_modes.c: Renamed to ... * commands/i386/pc/vbeinfo.c: ... this. * commands/i386/pc/vbe_test.c: Renamed to ... * commands/i386/pc/vbetest.c: ... this. * commands/i386/pc/vbeinfo.c (grub_cmd_vbe_list_modes): Renamed to ... (grub_cmd_vbeinfo): ... this. Save video modes before iterating. Skip a video mode, if it is not available, not enough information is given or it is monochrome. Show the memory model. Leave the interpretation of MODEVAR to grub_strtoul completely. (GRUB_MOD_INIT): Rename vbe_list_modes to vbeinfo. (GRUB_MOD_FINI): Likewise. * commands/i386/pc/vbetest.c (grub_cmd_vbe_test): Renamed to ... (grub_cmd_vbetest): ... this. Don't print unnecessarily. Use grub_err_t instead of grub_uint32_t. Don't use SPTR. Remove a duplicated grub_env_get. Leave the interpretation of MODEVAR to grub_strtoul completely. (real2pm): Removed. (GRUB_MOD_INIT): Rename vbe_test to vbetest. (GRUB_MOD_FINI): Likewise. * normal/misc.c: Include grub/mm.h. * conf/i386-pc.rmk (pkgdata_MODULES): Replaced vbe_test.mod and vbe_list_modes with vbetest.mod and vbeinfo.mod. (vbe_list_modes_mod_SOURCES): Removed. (vbe_list_modes_mod_CFLAGS): Likewise. (vbe_test_mod_SOURCES): Likewise. (vbe_test_mod_CFLAGS): Likewise. (vbeinfo_mod_SOURCES): New variable. (vbeinfo_mod_CFLAGS): Likewise. (vbetest_mod_SOURCES): Likewise. (vbetest_mod_CFLAGS): Likewise.
2005-08-19 00:32:01 +00:00
# For vbetest.mod.
vbetest_mod_SOURCES = commands/i386/pc/vbetest.c
vbetest_mod_CFLAGS = $(COMMON_CFLAGS)
2005-10-01 Marco Gerards <mgerards@xs4all.nl> * configure.ac: Accept `x86_64' as host_cpu. In that case add `-m32' to CFLAGS. * genmk.rb (class PModule): Always use `$(#{prefix}_LDFLAGS)' when linking. * conf/i386-pc.rmk (COMMON_CFLAGS): Add `-m32'. (COMMON_LDFLAGS): New variable. (kernel_img_LDFLAGS): Include `COMMON_FLAGS'. (_chain_mod_LDFLAGS, fshelp_mod_LDFLAGS, fat_mod_LDFLAGS) (ext2_mod_LDFLAGS, ufs_mod_LDFLAGS, minix_mod_LDFLAGS) (hfs_mod_LDFLAGS, jfs_mod_LDFLAGS, iso9660_mod_LDFLAGS) (xfs_mod_LDFLAGS, _linux_mod_LDFLAGS, linux_mod_LDFLAGS) (normal_mod_LDFLAGS, hello_mod_LDFLAGS, boot_mod_LDFLAGS) (terminal_mod_LDFLAGS, ls_mod_LDFLAGS, cmp_mod_LDFLAGS) (cat_mod_LDFLAGS, help_mod_LDFLAGS, reboot_mod_LDFLAGS) (halt_mod_LDFLAGS, vga_mod_LDFLAGS, font_mod_LDFLAGS) (terminfo_mod_LDFLAGS, serial_mod_LDFLAGS, _multiboot_mod_LDFLAGS) (multiboot_mod_LDFLAGS, amiga_mod_LDFLAGS, apple_mod_LDFLAGS) (pc_mod_LDFLAGS, sun_mod_LDFLAGS, loopback_mod_LDFLAGS) (default_mod_LDFLAGS, timeout_mod_LDFLAGS, configfile_mod_LDFLAGS) (vbe_mod_LDFLAGS, vesafb_mod_LDFLAGS, vbeinfo_mod_LDFLAGS) (vbetest_mod_LDFLAGS, search_mod_LDFLAGS, gzio_mod_LDFLAGS): New variables. (normal_mod_ASFLAGS): Add `-m32'. * include/grub/types.h (grub_host_addr_t, grub_host_off_t) (grub_host_size_t, grub_host_ssize_t): New types. (grub_addr_t, grub_off_t, grub_size_t, grub_ssize_t): Make type dependant of `GRUB_CPU_SIZEOF_VOID_P' instead on `GRUB_HOST_SIZEOF_VOID_P'. * include/grub/kernel.h (struct grub_module_header): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'. (struct grub_module_info): Type of member offset changed to `grub_host_off_t'. Type of member size changed to `grub_host_size_t'.
2005-10-01 19:49:55 +00:00
vbetest_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For vga.mod.
Transform (broken) vga terminal into (working) vga video driver. * conf/i386-pc.rmk (vga_mod_SOURCES): Change term/i386/pc/vga.c to video/i386/pc/vga.c. * include/grub/video.h (grub_video_driver_id): Add GRUB_VIDEO_DRIVER_VGA. * term/i386/pc/vga.c: Renamed to ... * video/i386/pc/vga.c: ...this (DEBUG_VGA): Removed. (CHAR_WIDTH): Likewise. (CHAR_HEIGHT): Likewise. (TEXT_WIDTH): Likewise. (TEXT_HEIGHT): Likewise. (DEFAULT_FG_COLOR): Likewise. (DEFAULT_BG_COLOR): Likewise. (colored_char): Likewise. (xpos): Likewise. (ypos): Likewise. (cursor_state): Likewise. (fg_color): Likewise. (bg_color): Likewise. (text_buf): Likewise. (page): Likewise. (font): Likewise. (framebuffer): New variable. (set_read_map): Disabled. (setup): New variable. (is_target): Likewise. (grub_vga_mod_init): Likewise. (grub_vga_mod_fini): Likewise. (check_vga_mem): Likewise. (write_char): Likewise. (write_cursor): Likewise. (scroll_up): Likewise. (grub_vga_putchar): Likewise. (grub_vga_getcharwidth): Likewise. (grub_vga_getwh): Likewise. (grub_vga_getxy): Likewise. (grub_vga_gotoxy): Likewise. (grub_vga_cls): Likewise. (grub_vga_setcolorstate): Likewise. (grub_vga_setcursor): Likewise. (grub_video_vga_init): New function. (grub_video_vga_setup): Likewise. (grub_video_vga_fini): Likewise. (update_target): Likewise. (grub_video_vga_blit_bitmap): Likewise. (grub_video_vga_blit_render_target): Likewise. (grub_video_vga_set_active_render_target): Likewise. (grub_video_vga_get_active_render_target): Likewise. (grub_video_vga_swap_buffers): Likewise. (grub_video_vga_set_palette): Likewise. (grub_video_vga_get_info_and_fini): Likewise. (grub_vga_term): Removed. (grub_video_vga_adapter): New variable. (GRUB_MOD_INIT): Register a video driver instead of terminal. (GRUB_MOD_FINI): Unrefister a video driver instead of terminal.
2010-05-09 09:00:21 +00:00
vga_mod_SOURCES = video/i386/pc/vga.c
vga_mod_CFLAGS = $(COMMON_CFLAGS)
vga_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For aout.mod
aout_mod_SOURCES = loader/aout.c
aout_mod_CFLAGS = $(COMMON_CFLAGS)
aout_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For bsd.mod
bsd_mod_SOURCES = loader/i386/bsd.c loader/i386/bsd32.c loader/i386/bsd64.c loader/i386/bsd_helper.S loader/i386/bsd_trampoline.S
bsd_mod_CFLAGS = $(COMMON_CFLAGS)
bsd_mod_LDFLAGS = $(COMMON_LDFLAGS)
bsd_mod_ASFLAGS = $(COMMON_ASFLAGS)
# For usb.mod
usb_mod_SOURCES = bus/usb/usb.c bus/usb/usbtrans.c bus/usb/usbhub.c
usb_mod_CFLAGS = $(COMMON_CFLAGS)
usb_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For usbtest.mod
usbtest_mod_SOURCES = commands/usbtest.c
usbtest_mod_CFLAGS = $(COMMON_CFLAGS)
usbtest_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For uhci.mod
uhci_mod_SOURCES = bus/usb/uhci.c
uhci_mod_CFLAGS = $(COMMON_CFLAGS)
uhci_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For ohci.mod
ohci_mod_SOURCES = bus/usb/ohci.c
ohci_mod_CFLAGS = $(COMMON_CFLAGS)
ohci_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For usbms.mod
usbms_mod_SOURCES = disk/usbms.c
usbms_mod_CFLAGS = $(COMMON_CFLAGS)
usbms_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For usb_keyboard.mod
usb_keyboard_mod_SOURCES = term/usb_keyboard.c
usb_keyboard_mod_CFLAGS = $(COMMON_CFLAGS)
usb_keyboard_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For pxe.mod
pxe_mod_SOURCES = fs/i386/pc/pxe.c
pxe_mod_CFLAGS = $(COMMON_CFLAGS)
pxe_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For pxecmd.mod
pxecmd_mod_SOURCES = commands/i386/pc/pxecmd.c
pxecmd_mod_CFLAGS = $(COMMON_CFLAGS)
pxecmd_mod_LDFLAGS = $(COMMON_LDFLAGS)
2008-08-15 Bean <bean123ch@gmail.com> * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * kern/env.c (grub_env_insert): Fix a bug in prevp pointer. * commands/date.c: New file. * hook/datehook.c: Likewise. * include/grub/lib/datetime.h: Likewise. * include/grub/i386/cmos.h: Likewise. * lib/datetime.c: Likewise. * lib/i386/datetime.c: Likewise. * lib/efi/datetime.c: Likewise.
2008-08-15 15:39:02 +00:00
# For datetime.mod
2009-12-11 21:14:09 +00:00
datetime_mod_SOURCES = lib/cmos_datetime.c
2008-08-15 Bean <bean123ch@gmail.com> * conf/i386-pc.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-coreboot.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-ieee1275.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/i386-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * conf/x86_64-efi.rmk (pkglib_MODULES): Add datetime.mod, date.mod and datehook.mod. (datetime_mod_SOURCES): New macro. (datetime_mod_CFLAGS): Likewise. (datetime_mod_LDFLAGS): Likewise. (date_mod_SOURCES): Likewise. (date_mod_CFLAGS): Likewise. (date_mod_LDFLAGS): Likewise. (datehook_mod_SOURCES): Likewise. (datehook_mod_CFLAGS): Likewise. (datehook_mod_LDFLAGS): Likewise. * kern/env.c (grub_env_insert): Fix a bug in prevp pointer. * commands/date.c: New file. * hook/datehook.c: Likewise. * include/grub/lib/datetime.h: Likewise. * include/grub/i386/cmos.h: Likewise. * lib/datetime.c: Likewise. * lib/i386/datetime.c: Likewise. * lib/efi/datetime.c: Likewise.
2008-08-15 15:39:02 +00:00
datetime_mod_CFLAGS = $(COMMON_CFLAGS)
datetime_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For ata_pthru.mod.
ata_pthru_mod_SOURCES = disk/ata_pthru.c
ata_pthru_mod_CFLAGS = $(COMMON_CFLAGS)
ata_pthru_mod_LDFLAGS = $(COMMON_LDFLAGS)
# For hdparm.mod.
hdparm_mod_SOURCES = commands/hdparm.c lib/hexdump.c
hdparm_mod_CFLAGS = $(COMMON_CFLAGS)
hdparm_mod_LDFLAGS = $(COMMON_LDFLAGS)
2009-12-11 20:28:27 +00:00
# For cmostest.mod
pkglib_MODULES += cmostest.mod
cmostest_mod_SOURCES = commands/i386/cmostest.c
cmostest_mod_CFLAGS = $(COMMON_CFLAGS)
cmostest_mod_LDFLAGS = $(COMMON_LDFLAGS)
ifeq ($(enable_efiemu), yes)
efiemu32.o: efiemu/runtime/efiemu.c $(TARGET_OBJ2ELF)
-rm -f $@
ifeq ($(TARGET_APPLE_CC), 1)
-rm -f $@.bin
$(TARGET_CC) -c -m32 -DELF32 -DAPPLE_CC -o $@.bin -Wall -Werror $< -nostdlib -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
$(OBJCONV) -felf32 -nu -nd $@.bin $@
-rm -f $@.bin
else
$(TARGET_CC) -c -m32 -DELF32 -o $@ -Wall -Werror $< -nostdlib -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
if test ! -z $(TARGET_OBJ2ELF); then ./$(TARGET_OBJ2ELF) $@ || (rm -f $@; exit 1); fi
endif
efiemu64_c.o: efiemu/runtime/efiemu.c
ifeq ($(TARGET_APPLE_CC), 1)
$(TARGET_CC) -c -m64 -DAPPLE_CC=1 -DELF64 -o $@ -Wall -Werror $< -nostdlib -mno-red-zone -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
else
$(TARGET_CC) -c -m64 -DELF64 -o $@ -Wall -Werror $< -nostdlib -mcmodel=large -mno-red-zone -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
endif
efiemu64_s.o: efiemu/runtime/efiemu.S
-rm -f $@
ifeq ($(TARGET_APPLE_CC), 1)
$(TARGET_CC) -c -m64 -DAPPLE_CC=1 -DELF64 -o $@ -Wall -Werror $< -nostdlib -mno-red-zone -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
else
$(TARGET_CC) -c -m64 -DELF64 -o $@ -Wall -Werror $< -nostdlib -mcmodel=large -mno-red-zone -O2 -I$(srcdir)/efiemu/runtime -I$(srcdir)/include -Iinclude
endif
efiemu64.o: efiemu64_c.o efiemu64_s.o $(TARGET_OBJ2ELF)
-rm -f $@
ifeq ($(TARGET_APPLE_CC), 1)
-rm -f $@.bin
$(TARGET_CC) -m64 -o $@.bin -Wl,-r $^ -nostdlib
$(OBJCONV) -felf64 -nu -nd $@.bin $@
-rm -f $@.bin
else
$(TARGET_CC) -m64 -o $@ -Wl,-r $^ -nostdlib
if test ! -z $(TARGET_OBJ2ELF); then ./$(TARGET_OBJ2ELF) $@ || (rm -f $@; exit 1); fi
endif
CLEANFILES += efiemu32.o efiemu64.o efiemu64_c.o efiemu64_s.o
pkglib_DATA += efiemu32.o efiemu64.o
endif
include $(srcdir)/conf/i386.mk
2005-11-18 Timothy Baldwin <T.E.Baldwin99@members.leeds.ac.uk> * genmk.rb: Fixed list rules moved to Makefile.in. Recognise appending to variables with "+=". (PModule): Use full pathname to generate *.lst filenames. * Makefile.in: Fixed list rules moved from genmk.rb. (.DELETE_ON_ERROR): New special target. (RMKFILES): Add common.rmk and sparc64-ieee1275.rmk. * conf/i386-pc.rmk: Include conf/common.mk. (pkgdata_MODULES): Removed fshelp.mod, fat.mod, ext2.mod, ufs.mod, minux.mod, hfs.mod, jfs.mod, xfs.mod, affs.mod, sfs.mod, hello.mod, boot.mod, terminal.mod, ls.mod, cmp.mod, cat.mod, help.mod, font.mod, terminfo.mod, amiga.mod, apple.mod, pc.mod, sun.mod, acorn.mod, loopback.mod, default.mod, timeout.mod, configfile.mod, search.mod, gzio.mod and test.mod. (symlist.c, grub_script.tab.c, grub_script.tab.h, kernel_syms.lst) (grub_modules_init.lst, grub_modules_init.h, grub_emu_init.c) (fshelp_mod_SOURCES, fshelp_mod_CFLAGS, fshelp_mod_LDFLAGS) (fat_mod_SOURCES, fat_mod_CFLAGS, fat_mod_LDFLAGS) (ext2_mod_SOURCES, ext2_mod_CFLAGS, ext2_mod_LDFLAGS) (ufs_mod_SOURCES, ufs_mod_CFLAGS, ufs_mod_LDFLAGS) (minix_mod_SOURCES, minix_mod_CFLAGS, minix_mod_LDFLAGS) (hfs_mod_SOURCES, hfs_mod_CFLAGS, hfs_mod_LDFLAGS, jfs_mod_SOURCES) (jfs_mod_CFLAGS, jfs_mod_LDFLAGS, iso9660_mod_SOURCES) (iso9660_mod_CFLAGS, iso9660_mod_LDFLAGS, xfs_mod_SOURCES) (xfs_mod_CFLAGS, xfs_mod_LDFLAGS, affs_mod_SOURCES) (affs_mod_CFLAGS, affs_mod_LDFLAGS, sfs_mod_SOURCES) (sfs_mod_CFLAGS, sfs_mod_LDFLAGS, hello_mod_SOURCES) (hello_mod_CFLAGS, hello_mod_LDFLAGS, boot_mod_SOURCES) (boot_mod_CFLAGS, boot_mod_LDFLAGS, terminal_mod_SOURCES) (terminal_mod_CFLAGS, terminal_mod_LDFLAGS, ls_mod_SOURCES) (ls_mod_CFLAGS, ls_mod_LDFLAGS, cmp_mod_SOURCES, cmp_mod_CFLAGS) (cmp_mod_LDFLAGS, cat_mod_SOURCES, cat_mod_CFLAGS, cat_mod_LDFLAGS) (help_mod_SOURCES, help_mod_CFLAGS, help_mod_LDFLAGS) (font_mod_SOURCES, font_mod_CFLAGS, font_mod_LDFLAGS) (terminfo_mod_SOURCES, terminfo_mod_CFLAGS, terminfo_mod_LDFLAGS) (amiga_mod_SOURCES, amiga_mod_CFLAGS, amiga_mod_LDFLAGS) (apple_mod_SOURCES, apple_mod_CFLAGS, apple_mod_LDFLAG): Move from here... * conf/common.rmk: ... to here. New file. * conf/common.mk: New file.
2005-11-18 14:56:55 +00:00
include $(srcdir)/conf/common.mk