2N/A# -*- makefile -*-
2N/A
2N/ACFLAGS_PLATFORM=
2N/A
2N/Aexport LC_COLLATE := C
2N/Aexport LC_CTYPE := C
2N/Aunexport LC_ALL
2N/A
2N/A# Platform specific options
2N/Aif COND_i386_pc
2N/A CFLAGS_PLATFORM += -mrtd -mregparm=3
2N/Aendif
2N/Aif COND_i386_efi
2N/A LDFLAGS_PLATFORM = -melf_i386
2N/Aendif
2N/Aif COND_x86_64_efi
2N/A LDFLAGS_PLATFORM = -melf_x86_64
2N/Aendif
2N/Aif COND_i386_qemu
2N/A CFLAGS_PLATFORM += -mrtd -mregparm=3
2N/Aendif
2N/Aif COND_i386_coreboot
2N/A CFLAGS_PLATFORM += -mrtd -mregparm=3
2N/Aendif
2N/Aif COND_i386_ieee1275
2N/A CFLAGS_PLATFORM += -mrtd -mregparm=3
2N/Aendif
2N/Aif COND_mips_loongson
2N/A CFLAGS_PLATFORM += -mexplicit-relocs
2N/A CPPFLAGS_PLATFORM = -DUSE_ASCII_FAILBACK
2N/Aendif
2N/Aif COND_mips
2N/A CFLAGS_PLATFORM += -mflush-func=grub_cpu_flush_cache
2N/A CCASFLAGS_PLATFORM = -march=mips3
2N/Aendif
2N/Aif COND_sparc64_ieee1275
2N/A CFLAGS_PLATFORM += -mno-app-regs
2N/A LDFLAGS_PLATFORM = -melf64_sparc -mno-relax
2N/Aendif
2N/A
2N/A# Other options
2N/A
2N/ACPPFLAGS_DEFAULT = -DGRUB_FILE=\"$(subst $(srcdir)/,,$<)\"
2N/ACPPFLAGS_DEFAULT += -I$(builddir)
2N/ACPPFLAGS_DEFAULT += -I$(srcdir)
2N/ACPPFLAGS_DEFAULT += -I$(top_builddir)
2N/ACPPFLAGS_DEFAULT += -I$(top_srcdir)
2N/ACPPFLAGS_DEFAULT += -I$(top_srcdir)/include
2N/ACPPFLAGS_DEFAULT += -I$(top_builddir)/include
2N/ACCASFLAGS_DEFAULT = -DASM_FILE=1
2N/A
2N/ALDADD_KERNEL =
2N/A
2N/Aif ! COND_i386_pc
2N/Aif ! COND_i386_efi
2N/Aif ! COND_i386_qemu
2N/Aif ! COND_i386_coreboot
2N/Aif ! COND_i386_multiboot
2N/Aif ! COND_i386_ieee1275
2N/Aif ! COND_x86_64_efi
2N/ALDADD_KERNEL += -lgcc
2N/Aendif
2N/Aendif
2N/Aendif
2N/Aendif
2N/Aendif
2N/Aendif
2N/Aendif
2N/A
2N/Aif COND_ld_Solaris
2N/ACFLAGS_KERNEL = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding -fno-common
2N/ALDFLAGS_KERNEL = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -static-libgcc $(LDFLAGS_BASE_ADDRESS_$(GRUB_KERNEL_MACHINE_LINK_ADDR))
2N/A# GNU strip crashes when processing the static kernel.img on Solaris (even binutils 2.10.1)
2N/A# So, use Solaris's utilities
2N/AMCS_KERNEL = /usr/ccs/bin/mcs -d -n .note -n .comment -n .note.gnu.build-id -n .reginfo -n .rel.dyn
2N/AMCS_MODULE = /usr/ccs/bin/mcs -d -n .note -n .comment
2N/ASTRIPFLAGS_KERNEL =
2N/Aelse
2N/ACFLAGS_KERNEL = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
2N/ALDFLAGS_KERNEL = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N -static-libgcc
2N/ASTRIPFLAGS_KERNEL = -R .rel.dyn -R .reginfo -R .note -R .comment
2N/APRE_POUND = pre\#
2N/AMCS_KERNEL = $(PRE_POUND:pre\%=%)
2N/Aendif
2N/ACPPFLAGS_KERNEL = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
2N/ACCASFLAGS_KERNEL = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
2N/Aif COND_CYGWIN
2N/ASTRIPFLAGS_KERNEL = -F elf32-i386 -R .rel.dyn -R .reginfo -R .note -R .comment -R .drectve
2N/Aelse
2N/ASTRIPFLAGS_KERNEL = -R .rel.dyn -R .reginfo -R .note -R .comment
2N/Aendif
2N/A
2N/Aif COND_ld_Solaris
2N/ACFLAGS_MODULE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding -fno-common
2N/ALDFLAGS_MODULE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-r
2N/Aelse
2N/ACFLAGS_MODULE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
2N/ALDFLAGS_MODULE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-r,-d
2N/Aendif
2N/ACPPFLAGS_MODULE = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
2N/ACCASFLAGS_MODULE = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
2N/A
2N/Aif COND_ld_Solaris
2N/ACFLAGS_IMAGE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -fno-builtin -fno-common
2N/ALDFLAGS_IMAGE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib
2N/Aelse
2N/ACFLAGS_IMAGE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -fno-builtin
2N/ALDFLAGS_IMAGE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-S
2N/Aendif
2N/ACPPFLAGS_IMAGE = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
2N/ACCASFLAGS_IMAGE = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
2N/A
2N/ACFLAGS_PROGRAM =
2N/ALDFLAGS_PROGRAM =
2N/ACPPFLAGS_PROGRAM =
2N/ACCASFLAGS_PROGRAM =
2N/A
2N/ACFLAGS_LIBRARY =
2N/ACPPFLAGS_LIBRARY =
2N/ACCASFLAGS_LIBRARY =
2N/A
2N/Aif COND_ld_Solaris
2N/ALDFLAGS_EMU = -Wl,-r
2N/ALDFLAGS_X86_EFI = -Wl,-r
2N/ALDFLAGS_PACKDATA = -Wl,-dn
2N/ALDFLAGS_BASE_ADDRESS_0x0 = -Wl,-M,$(top_srcdir)/conf/mapfile-0.map
2N/ALDFLAGS_BASE_ADDRESS_0x7C00 = -Wl,-M,$(top_srcdir)/conf/mapfile-7c00.map
2N/ALDFLAGS_BASE_ADDRESS_0x8000 = -Wl,-M,$(top_srcdir)/conf/mapfile-8000.map
2N/ALDFLAGS_BASE_ADDRESS_0x8200 = -Wl,-M,$(top_srcdir)/conf/mapfile-8200.map
2N/ALDFLAGS_BASE_ADDRESS_0x6000 = -Wl,-M,$(top_srcdir)/conf/mapfile-6000.map
2N/ALDFLAGS_BASE_ADDRESS_0x9000 = -Wl,-M,$(top_srcdir)/conf/mapfile-9000.map
2N/ALDFLAGS_BASE_ADDRESS_0x100000 = -Wl,-M,$(top_srcdir)/conf/mapfile-100000.map
2N/Aelse
2N/ALDFLAGS_EMU = -Wl,-r,-d
2N/ALDFLAGS_X86_EFI = -Wl,-r,-d
2N/ALDFLAGS_PACKDATA = -Wl,-N
2N/ALDFLAGS_BASE_ADDRESS_0x0 = $(TARGET_IMG_BASE_LDOPT),0
2N/ALDFLAGS_BASE_ADDRESS_0x6000 = $(TARGET_IMG_BASE_LDOPT),0x6000
2N/ALDFLAGS_BASE_ADDRESS_0x7C00 = $(TARGET_IMG_BASE_LDOPT),0x7c00
2N/ALDFLAGS_BASE_ADDRESS_0x8000 = $(TARGET_IMG_BASE_LDOPT),0x8000
2N/ALDFLAGS_BASE_ADDRESS_0x8200 = $(TARGET_IMG_BASE_LDOPT),0x8200
2N/ALDFLAGS_BASE_ADDRESS_0x9000 = $(TARGET_IMG_BASE_LDOPT),0x9000
2N/ALDFLAGS_BASE_ADDRESS_0x100000 = $(TARGET_IMG_BASE_LDOPT),0x100000
2N/Aendif
2N/A
2N/A# Other variables
2N/A
2N/Agrubconfdir = $(sysconfdir)/grub.d
2N/Agrubdatadir = $(datadir)/`echo @PACKAGE_TARNAME@ | sed '$(transform)'`
2N/Aplatformdir = $(pkglibrootdir)/$(target_cpu)-$(platform)
2N/A
2N/ACFLAGS_GCRY = -Wno-error -Wno-missing-field-initializers
2N/ACPPFLAGS_GCRY = -I$(top_srcdir)/grub-core/lib/libgcrypt_wrap
2N/A
2N/ACFLAGS_GNULIB = -Wno-undef -Wno-sign-compare -Wno-unused -Wno-unused-parameter
2N/ACPPFLAGS_GNULIB = -I$(top_builddir)/grub-core/gnulib -I$(top_srcdir)/grub-core/gnulib
2N/A
2N/ACFLAGS_POSIX = -fno-builtin
2N/ACPPFLAGS_POSIX = -I$(top_srcdir)/grub-core/lib/posix_wrap
2N/A
2N/ACPPFLAGS_EFIEMU = -I$(top_srcdir)/grub-core/efiemu/runtime
2N/A
2N/A# List file macros for recognizing /interesting/ modules
2N/ACPPFLAGS_FS_LIST = -Dgrub_fs_register=FS_LIST_MARKER
2N/ACPPFLAGS_VIDEO_LIST= -Dgrub_video_register=VIDEO_LIST_MARKER
2N/ACPPFLAGS_PARTMAP_LIST = -Dgrub_partition_map_register=PARTMAP_LIST_MARKER
2N/ACPPFLAGS_PARTTOOL_LIST = -Dgrub_parttool_register=PARTTOOL_LIST_MARKER
2N/ACPPFLAGS_TERMINAL_LIST = '-Dgrub_term_register_input(...)=INPUT_TERMINAL_LIST_MARKER(__VA_ARGS__)'
2N/ACPPFLAGS_TERMINAL_LIST += '-Dgrub_term_register_output(...)=OUTPUT_TERMINAL_LIST_MARKER(__VA_ARGS__)'
2N/ACPPFLAGS_COMMAND_LIST = '-Dgrub_register_command(...)=COMMAND_LIST_MARKER(__VA_ARGS__)'
2N/ACPPFLAGS_COMMAND_LIST += '-Dgrub_register_extcmd(...)=EXTCOMMAND_LIST_MARKER(__VA_ARGS__)'
2N/ACPPFLAGS_COMMAND_LIST += '-Dgrub_register_command_p1(...)=P1COMMAND_LIST_MARKER(__VA_ARGS__)'
2N/ACPPFLAGS_MARKER = $(CPPFLAGS_FS_LIST) $(CPPFLAGS_VIDEO_LIST) \
2N/A $(CPPFLAGS_PARTTOOL_LIST) $(CPPFLAGS_PARTMAP_LIST) \
2N/A $(CPPFLAGS_TERMINAL_LIST) $(CPPFLAGS_COMMAND_LIST)
2N/A
2N/A# Define these variables to calm down automake
2N/A
2N/AIMG_FILES =
2N/AMOD_FILES =
2N/AMODULE_FILES =
2N/AMARKER_FILES =
2N/AKERNEL_HEADER_FILES =
2N/A
2N/Aman_MANS =
2N/Anoinst_DATA =
2N/Apkglib_DATA =
2N/Abin_SCRIPTS =
2N/Asbin_SCRIPTS =
2N/Abin_PROGRAMS =
2N/Aplatform_DATA =
2N/Asbin_PROGRAMS =
2N/Acheck_SCRIPTS =
2N/Agrubconf_DATA =
2N/Acheck_PROGRAMS =
2N/Anoinst_SCRIPTS =
2N/Apkglib_SCRIPTS =
2N/Anoinst_PROGRAMS =
2N/Agrubconf_SCRIPTS =
2N/Anoinst_LIBRARIES =
2N/Adist_noinst_DATA =
2N/A
2N/ATESTS =
2N/AEXTRA_DIST =
2N/ACLEANFILES =
2N/ABUILT_SOURCES =
2N/A