added conf/Makefile.common and conf/Makefile.extra-dist
This commit is contained in:
parent
34980574fc
commit
a5a3bccd54
6 changed files with 227 additions and 267 deletions
105
Makefile.am
105
Makefile.am
|
@ -2,104 +2,19 @@ AUTOMAKE_OPTIONS = subdir-objects
|
|||
|
||||
DEPDIR = .deps-util
|
||||
SUBDIRS = . grub-core po docs
|
||||
EXTRA_DIST = autogen.sh gentpl.py Makefile.tpl modules.def geninit.sh
|
||||
EXTRA_DIST += include conf/i386-pc-cygwin-img-ld.sc
|
||||
|
||||
grubconfdir = $(sysconfdir)/grub.d
|
||||
platformdir = $(pkglibrootdir)/$(target_cpu)-$(platform)
|
||||
include $(top_srcdir)/conf/Makefile.common
|
||||
include $(top_srcdir)/conf/Makefile.extra-dist
|
||||
|
||||
# Platform specific options
|
||||
if COND_i386_pc
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_efi
|
||||
LDFLAGS_PLATFORM = -melf_i386
|
||||
endif
|
||||
if COND_x86_64_efi
|
||||
LDFLAGS_PLATFORM = -melf_x86_64
|
||||
endif
|
||||
if COND_i386_qemu
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_coreboot
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_ieee1275
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_mips_yeeloong
|
||||
CFLAGS_PLATFORM = -march=mips3 -mexplicit-relocs -mflush-func=grub_cpu_flush_cache
|
||||
CCASFLAGS_PLATFORM = -march=mips3
|
||||
endif
|
||||
if COND_sparc64_ieee1275
|
||||
CFLAGS_PLATFORM = -mno-app-regs
|
||||
LDFLAGS_PLATFORM = -melf64_sparc -mno-relax
|
||||
endif
|
||||
AM_CFLAGS = $(HOST_CFLAGS)
|
||||
AM_LDFLAGS = $(HOST_LDFLAGS)
|
||||
AM_CPPFLAGS = $(HOST_CPPFLAGS) $(CPPFLAGS_DEFAULT)
|
||||
AM_CCASFLAGS = $(HOST_CCASFLAGS) $(CCASFLAGS_DEFAULT)
|
||||
|
||||
CPPFLAGS_GRUB = -DGRUB_FILE=\"`basename $<`\"
|
||||
CPPFLAGS_GRUB += -I$(builddir) -I$(srcdir) -I$(top_builddir) -I$(top_srcdir)
|
||||
CPPFLAGS_GRUB += -I$(top_srcdir)/include
|
||||
CPPFLAGS_GRUB += -I$(top_builddir)/include
|
||||
CCASFLAGS_GRUB = -DASM_FILE=1
|
||||
|
||||
CFLAGS_GCRY = -Wno-error -Wno-missing-field-initializers
|
||||
CPPFLAGS_GCRY = -I$(top_srcdir)/grub-core/lib/libgcrypt_wrap
|
||||
|
||||
CFLAGS_GNULIB = -Wno-undef -Wno-sign-compare -Wno-unused -D_GL_UNUSED="__attribute__ ((unused))"
|
||||
CPPFLAGS_GNULIB = -I$(top_srcdir)/grub-core/gnulib
|
||||
|
||||
CFLAGS_MKISOFS = -Wno-all -Werror
|
||||
CPPFLAGS_MKISOFS = -D_FILE_OFFSET_BITS=64 -I$(top_srcdir)/util/mkisofs/include
|
||||
|
||||
CFLAGS_POSIX = -fno-builtin
|
||||
CPPFLAGS_POSIX = -I$(top_srcdir)/grub-core/lib/posix_wrap
|
||||
|
||||
CPPFLAGS_EFIEMU = -I$(top_srcdir)/grub-core/efiemu/runtime
|
||||
|
||||
# to calm down automake
|
||||
BUILT_SOURCES =
|
||||
CLEANFILES =
|
||||
COMMAND_FILES =
|
||||
DEF_FILES =
|
||||
FS_FILES =
|
||||
HANDLER_FILES =
|
||||
IMG_FILES =
|
||||
MOD_FILES =
|
||||
MODULE_FILES =
|
||||
PARTMAP_FILES =
|
||||
PARTTOOL_FILES =
|
||||
TERMINAL_FILES =
|
||||
TESTS =
|
||||
UND_FILES =
|
||||
VIDEO_FILES =
|
||||
bin_PROGRAMS =
|
||||
bin_SCRIPTS =
|
||||
check_PROGRAMS =
|
||||
check_SCRIPTS =
|
||||
grubconf_DATA =
|
||||
grubconf_SCRIPTS =
|
||||
man_MANS =
|
||||
noinst_DATA =
|
||||
noinst_LIBRARIES =
|
||||
noinst_PROGRAMS =
|
||||
pkglib_SCRIPTS =
|
||||
platform_DATA =
|
||||
sbin_PROGRAMS =
|
||||
sbin_SCRIPTS =
|
||||
|
||||
CFLAGS_PROGRAM = $(HOST_CFLAGS) $(CFLAGS_GNULIB)
|
||||
LDFLAGS_PROGRAM = $(HOST_LDFLAGS) $(LDFLAGS_GNULIB)
|
||||
CPPFLAGS_PROGRAM = $(HOST_CPPFLAGS) $(CPPFLAGS_GNULIB)
|
||||
CCASFLAGS_PROGRAM = $(HOST_CCASFLAGS) $(CCASFLAGS_GNULIB)
|
||||
|
||||
CFLAGS_LIBRARY = $(CFLAGS_PROGRAM)
|
||||
CPPFLAGS_LIBRARY = $(CPPFLAGS_PROGRAM)
|
||||
CCASFLAGS_LIBRARY = $(CCASFLAGS_PROGRAM)
|
||||
|
||||
AM_CFLAGS =
|
||||
AM_LDFLAGS =
|
||||
AM_CPPFLAGS = $(CPPFLAGS_GRUB)
|
||||
AM_CCASFLAGS = $(CCASFLAGS_GRUB)
|
||||
CFLAGS_PROGRAM += $(CFLAGS_GNULIB)
|
||||
LDFLAGS_PROGRAM += $(LDFLAGS_GNULIB)
|
||||
CPPFLAGS_PROGRAM += $(CPPFLAGS_GNULIB)
|
||||
CCASFLAGS_PROGRAM += $(CCASFLAGS_GNULIB)
|
||||
|
||||
include $(srcdir)/modules.am
|
||||
|
||||
|
|
118
conf/Makefile.common
Normal file
118
conf/Makefile.common
Normal file
|
@ -0,0 +1,118 @@
|
|||
# Platform specific options
|
||||
if COND_i386_pc
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_efi
|
||||
LDFLAGS_PLATFORM = -melf_i386
|
||||
endif
|
||||
if COND_x86_64_efi
|
||||
LDFLAGS_PLATFORM = -melf_x86_64
|
||||
endif
|
||||
if COND_i386_qemu
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_coreboot
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_ieee1275
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_mips_yeeloong
|
||||
CFLAGS_PLATFORM = -march=mips3 -mexplicit-relocs -mflush-func=grub_cpu_flush_cache
|
||||
CCASFLAGS_PLATFORM = -march=mips3
|
||||
endif
|
||||
if COND_sparc64_ieee1275
|
||||
CFLAGS_PLATFORM = -mno-app-regs
|
||||
LDFLAGS_PLATFORM = -melf64_sparc -mno-relax
|
||||
endif
|
||||
|
||||
# Other options
|
||||
|
||||
CPPFLAGS_DEFAULT = -DGRUB_FILE=\"`basename $<`\"
|
||||
CPPFLAGS_DEFAULT += -I$(builddir)
|
||||
CPPFLAGS_DEFAULT += -I$(srcdir)
|
||||
CPPFLAGS_DEFAULT += -I$(top_builddir)
|
||||
CPPFLAGS_DEFAULT += -I$(top_srcdir)
|
||||
CPPFLAGS_DEFAULT += -I$(top_srcdir)/include
|
||||
CPPFLAGS_DEFAULT += -I$(top_builddir)/include
|
||||
CCASFLAGS_DEFAULT = -DASM_FILE=1
|
||||
|
||||
LDADD_KERNEL = -lgcc
|
||||
CFLAGS_KERNEL = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
|
||||
LDFLAGS_KERNEL = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N -static-libgcc
|
||||
CPPFLAGS_KERNEL = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_KERNEL = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_MODULE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
|
||||
LDFLAGS_MODULE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-r,-d
|
||||
CPPFLAGS_MODULE = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_MODULE = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_IMAGE = $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -fno-builtin
|
||||
LDFLAGS_IMAGE = $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-S
|
||||
CPPFLAGS_IMAGE = $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_IMAGE = $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_PROGRAM =
|
||||
LDFLAGS_PROGRAM =
|
||||
CPPFLAGS_PROGRAM =
|
||||
CCASFLAGS_PROGRAM =
|
||||
|
||||
CFLAGS_LIBRARY = $(CFLAGS_PROGRAM)
|
||||
CPPFLAGS_LIBRARY = $(CPPFLAGS_PROGRAM)
|
||||
CCASFLAGS_LIBRARY = $(CCASFLAGS_PROGRAM)
|
||||
|
||||
# Other variables
|
||||
|
||||
grubconfdir = $(sysconfdir)/grub.d
|
||||
platformdir = $(pkglibrootdir)/$(target_cpu)-$(platform)
|
||||
|
||||
CFLAGS_GCRY = -Wno-error -Wno-missing-field-initializers
|
||||
CPPFLAGS_GCRY = -I$(top_srcdir)/grub-core/lib/libgcrypt_wrap
|
||||
|
||||
CFLAGS_GNULIB = -Wno-undef -Wno-sign-compare -Wno-unused -D_GL_UNUSED="__attribute__ ((unused))"
|
||||
CPPFLAGS_GNULIB = -I$(top_srcdir)/grub-core/gnulib
|
||||
|
||||
CFLAGS_MKISOFS = -Wno-all -Werror
|
||||
CPPFLAGS_MKISOFS = -D_FILE_OFFSET_BITS=64 -I$(top_srcdir)/util/mkisofs/include
|
||||
|
||||
CFLAGS_POSIX = -fno-builtin
|
||||
CPPFLAGS_POSIX = -I$(top_srcdir)/grub-core/lib/posix_wrap
|
||||
|
||||
CPPFLAGS_EFIEMU = -I$(top_srcdir)/grub-core/efiemu/runtime
|
||||
|
||||
# Define these variables to calm down automake
|
||||
|
||||
FS_FILES =
|
||||
DEF_FILES =
|
||||
UND_FILES =
|
||||
IMG_FILES =
|
||||
MOD_FILES =
|
||||
VIDEO_FILES =
|
||||
MODULE_FILES =
|
||||
HANDLER_FILES =
|
||||
PARTMAP_FILES =
|
||||
COMMAND_FILES =
|
||||
PARTTOOL_FILES =
|
||||
TERMINAL_FILES =
|
||||
KERNEL_HEADER_FILES =
|
||||
|
||||
man_MANS =
|
||||
noinst_DATA =
|
||||
bin_SCRIPTS =
|
||||
sbin_SCRIPTS =
|
||||
bin_PROGRAMS =
|
||||
platform_DATA =
|
||||
sbin_PROGRAMS =
|
||||
check_SCRIPTS =
|
||||
grubconf_DATA =
|
||||
check_PROGRAMS =
|
||||
pkglib_SCRIPTS =
|
||||
noinst_PROGRAMS =
|
||||
grubconf_SCRIPTS =
|
||||
noinst_LIBRARIES =
|
||||
|
||||
TESTS =
|
||||
EXTRA_DIST =
|
||||
CLEANFILES =
|
||||
BUILT_SOURCES =
|
75
conf/Makefile.extra-dist
Normal file
75
conf/Makefile.extra-dist
Normal file
|
@ -0,0 +1,75 @@
|
|||
EXTRA_DIST += include
|
||||
|
||||
EXTRA_DIST += autogen.sh
|
||||
EXTRA_DIST += geninit.sh
|
||||
|
||||
EXTRA_DIST += gentpl.py
|
||||
EXTRA_DIST += modules.def
|
||||
EXTRA_DIST += Makefile.tpl
|
||||
|
||||
EXTRA_DIST += docs/man
|
||||
EXTRA_DIST += docs/grub.cfg
|
||||
|
||||
EXTRA_DIST += conf/i386-pc-cygwin-img-ld.sc
|
||||
|
||||
EXTRA_DIST += grub-core/modules.def
|
||||
EXTRA_DIST += grub-core/genmoddep.awk
|
||||
EXTRA_DIST += grub-core/genmodsrc.sh
|
||||
EXTRA_DIST += grub-core/genfslist.sh
|
||||
EXTRA_DIST += grub-core/gencmdlist.sh
|
||||
EXTRA_DIST += grub-core/gensymlist.sh
|
||||
EXTRA_DIST += grub-core/genemuinit.sh
|
||||
EXTRA_DIST += grub-core/genvideolist.sh
|
||||
EXTRA_DIST += grub-core/genhandlerlist.sh
|
||||
EXTRA_DIST += grub-core/genpartmaplist.sh
|
||||
EXTRA_DIST += grub-core/genterminallist.sh
|
||||
EXTRA_DIST += grub-core/genparttoollist.sh
|
||||
EXTRA_DIST += grub-core/genemuinitheader.sh
|
||||
|
||||
EXTRA_DIST += grub-core/gnulib/getopt.h
|
||||
EXTRA_DIST += grub-core/gnulib/argp-version-etc.h
|
||||
EXTRA_DIST += grub-core/gnulib/fnmatch.h
|
||||
EXTRA_DIST += grub-core/gnulib/error.h
|
||||
EXTRA_DIST += grub-core/gnulib/argp-namefrob.h
|
||||
EXTRA_DIST += grub-core/gnulib/argp.h
|
||||
EXTRA_DIST += grub-core/gnulib/argp-fmtstream.h
|
||||
EXTRA_DIST += grub-core/gnulib/gettext.h
|
||||
EXTRA_DIST += grub-core/gnulib/regex_internal.h
|
||||
EXTRA_DIST += grub-core/gnulib/progname.h
|
||||
EXTRA_DIST += grub-core/gnulib/regex.h
|
||||
EXTRA_DIST += grub-core/gnulib/alloca.h
|
||||
EXTRA_DIST += grub-core/gnulib/getopt_int.h
|
||||
EXTRA_DIST += grub-core/efiemu/runtime/config.h
|
||||
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/localcharset.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/ctype.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/limits.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/stdio.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/sys/types.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/unistd.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/locale.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/wchar.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/string.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/langinfo.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/wctype.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/stdint.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/stdlib.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/assert.h
|
||||
EXTRA_DIST += grub-core/lib/posix_wrap/errno.h
|
||||
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt_wrap/cipher_wrap.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt/cipher/rijndael-tables.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt/cipher/bithelp.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt/cipher/rmd.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt/cipher/hash-common.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt/cipher/camellia.h
|
||||
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/types.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/cipher.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/rijndael-tables.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/memory.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/bithelp.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/g10lib.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/rmd.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/hash-common.h
|
||||
EXTRA_DIST += grub-core/lib/libgcrypt-grub/cipher/camellia.h
|
|
@ -1,7 +1,5 @@
|
|||
AUTOMAKE_OPTIONS = subdir-objects
|
||||
|
||||
EXTRA_DIST = grub.cfg man
|
||||
|
||||
AM_MAKEINFOFLAGS = --force --no-split --no-validate
|
||||
info_TEXINFOS = grub.texi
|
||||
grub_TEXINFOS = fdl.texi
|
||||
|
|
|
@ -226,15 +226,15 @@ mod-[+ name +].c: [+ name +].module$(EXEEXT) moddep.lst genmodsrc.sh
|
|||
sh $(srcdir)/genmodsrc.sh [+ name +] moddep.lst > $@ || (rm -f $@; exit 1)
|
||||
|
||||
mod-[+ name +].o: mod-[+ name +].c
|
||||
$(TARGET_CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(CPPFLAGS_MODULE) $(CPPFLAGS) $(CFLAGS_MODULE) $(CFLAGS) -c -o $@ $<
|
||||
$(TARGET_CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(""" + cname() + """_CPPFLAGS) $(CPPFLAGS) $(""" + cname() + """_CFLAGS) $(CFLAGS) -c -o $@ $<
|
||||
|
||||
[+ name +].mod: [+ name +].module$(EXEEXT) mod-[+ name +].o
|
||||
if test x$(USE_APPLE_CC_FIXES) = xyes; then \
|
||||
$(CCLD) $(LDFLAGS_MODULE) $(LDFLAGS) -o $@.bin $^; \
|
||||
$(CCLD) $(""" + cname() + """_LDFLAGS) $(LDFLAGS) -o $@.bin $^; \
|
||||
$(OBJCONV) -f$(TARGET_MODULE_FORMAT) -nr:_grub_mod_init:grub_mod_init -nr:_grub_mod_fini:grub_mod_fini -wd1106 -nu -nd $@.bin $@; \
|
||||
rm -f $@.bin; \
|
||||
else \
|
||||
$(CCLD) -o $@ $(LDFLAGS_MODULE) $(LDFLAGS) $^; \
|
||||
$(CCLD) -o $@ $(""" + cname() + """_LDFLAGS) $(LDFLAGS) $^; \
|
||||
if test ! -z '$(TARGET_OBJ2ELF)'; then $(TARGET_OBJ2ELF) $@ || (rm -f $@; exit 1); fi; \
|
||||
$(STRIP) --strip-unneeded -K grub_mod_init -K grub_mod_fini -K _grub_mod_init -K _grub_mod_fini -R .note -R .comment $@; \
|
||||
fi
|
||||
|
|
|
@ -1,172 +1,26 @@
|
|||
AUTOMAKE_OPTIONS = subdir-objects
|
||||
|
||||
DEPDIR=.deps-core
|
||||
|
||||
include $(top_srcdir)/conf/Makefile.common
|
||||
|
||||
CC=$(TARGET_CC)
|
||||
CPP=$(TARGET_CC)
|
||||
CCAS=$(TARGET_CC)
|
||||
DEPDIR=.deps-core
|
||||
|
||||
EXTRA_DIST =
|
||||
EXTRA_DIST += modules.def genmoddep.awk
|
||||
EXTRA_DIST += genmodsrc.sh gensymlist.sh genemuinit.sh genemuinitheader.sh
|
||||
EXTRA_DIST += genfslist.sh gencmdlist.sh genvideolist.sh genhandlerlist.sh
|
||||
EXTRA_DIST += genpartmaplist.sh genparttoollist.sh genterminallist.sh
|
||||
EXTRA_DIST += lib/libgcrypt_wrap/cipher_wrap.h
|
||||
EXTRA_DIST += lib/libgcrypt/cipher/rijndael-tables.h
|
||||
EXTRA_DIST += lib/libgcrypt/cipher/bithelp.h
|
||||
EXTRA_DIST += lib/libgcrypt/cipher/rmd.h
|
||||
EXTRA_DIST += lib/libgcrypt/cipher/hash-common.h
|
||||
EXTRA_DIST += lib/libgcrypt/cipher/camellia.h
|
||||
EXTRA_DIST += lib/posix_wrap/localcharset.h
|
||||
EXTRA_DIST += lib/posix_wrap/ctype.h
|
||||
EXTRA_DIST += lib/posix_wrap/limits.h
|
||||
EXTRA_DIST += lib/posix_wrap/stdio.h
|
||||
EXTRA_DIST += lib/posix_wrap/sys/types.h
|
||||
EXTRA_DIST += lib/posix_wrap/unistd.h
|
||||
EXTRA_DIST += lib/posix_wrap/locale.h
|
||||
EXTRA_DIST += lib/posix_wrap/wchar.h
|
||||
EXTRA_DIST += lib/posix_wrap/string.h
|
||||
EXTRA_DIST += lib/posix_wrap/langinfo.h
|
||||
EXTRA_DIST += lib/posix_wrap/wctype.h
|
||||
EXTRA_DIST += lib/posix_wrap/stdint.h
|
||||
EXTRA_DIST += lib/posix_wrap/stdlib.h
|
||||
EXTRA_DIST += lib/posix_wrap/assert.h
|
||||
EXTRA_DIST += lib/posix_wrap/errno.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/types.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/cipher.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/rijndael-tables.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/memory.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/bithelp.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/g10lib.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/rmd.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/hash-common.h
|
||||
EXTRA_DIST += lib/libgcrypt-grub/cipher/camellia.h
|
||||
EXTRA_DIST += efiemu/runtime/config.h
|
||||
EXTRA_DIST += gnulib/getopt.h
|
||||
EXTRA_DIST += gnulib/argp-version-etc.h
|
||||
EXTRA_DIST += gnulib/fnmatch.h
|
||||
EXTRA_DIST += gnulib/error.h
|
||||
EXTRA_DIST += gnulib/argp-namefrob.h
|
||||
EXTRA_DIST += gnulib/argp.h
|
||||
EXTRA_DIST += gnulib/argp-fmtstream.h
|
||||
EXTRA_DIST += gnulib/gettext.h
|
||||
EXTRA_DIST += gnulib/regex_internal.h
|
||||
EXTRA_DIST += gnulib/progname.h
|
||||
EXTRA_DIST += gnulib/regex.h
|
||||
EXTRA_DIST += gnulib/alloca.h
|
||||
EXTRA_DIST += gnulib/getopt_int.h
|
||||
AM_CFLAGS = $(TARGET_CFLAGS)
|
||||
AM_LDFLAGS = $(TARGET_LDFLAGS)
|
||||
AM_CPPFLAGS = $(TARGET_CPPFLAGS) $(CPPFLAGS_DEFAULT)
|
||||
AM_CCASFLAGS = $(TARGET_CCASFLAGS) $(CCASFLAGS_DEFAULT)
|
||||
|
||||
grubconfdir = $(sysconfdir)/grub.d
|
||||
platformdir = $(pkglibrootdir)/$(target_cpu)-$(platform)
|
||||
CFLAGS_PROGRAM += $(CFLAGS_PLATFORM)
|
||||
LDFLAGS_PROGRAM += $(LDFLAGS_PLATFORM)
|
||||
CPPFLAGS_PROGRAM += $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_PROGRAM += $(CCASFLAGS_PLATFORM)
|
||||
|
||||
# to calm down automake
|
||||
BUILT_SOURCES =
|
||||
CLEANFILES =
|
||||
COMMAND_FILES =
|
||||
DEF_FILES =
|
||||
FS_FILES =
|
||||
HANDLER_FILES =
|
||||
IMG_FILES =
|
||||
MOD_FILES =
|
||||
MODULE_FILES =
|
||||
PARTMAP_FILES =
|
||||
PARTTOOL_FILES =
|
||||
TERMINAL_FILES =
|
||||
TESTS =
|
||||
UND_FILES =
|
||||
VIDEO_FILES =
|
||||
bin_PROGRAMS =
|
||||
bin_SCRIPTS =
|
||||
check_PROGRAMS =
|
||||
check_SCRIPTS =
|
||||
grubconf_DATA =
|
||||
grubconf_SCRIPTS =
|
||||
man_MANS =
|
||||
noinst_DATA =
|
||||
noinst_LIBRARIES =
|
||||
noinst_PROGRAMS =
|
||||
pkglib_SCRIPTS =
|
||||
platform_DATA =
|
||||
sbin_PROGRAMS =
|
||||
sbin_SCRIPTS =
|
||||
KERNEL_HEADER_FILES =
|
||||
|
||||
# Platform specific options
|
||||
if COND_i386_pc
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_efi
|
||||
LDFLAGS_PLATFORM = -melf_i386
|
||||
endif
|
||||
if COND_x86_64_efi
|
||||
LDFLAGS_PLATFORM = -melf_x86_64
|
||||
endif
|
||||
if COND_i386_qemu
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_coreboot
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_i386_ieee1275
|
||||
CFLAGS_PLATFORM = -mrtd -mregparm=3
|
||||
endif
|
||||
if COND_mips_yeeloong
|
||||
CFLAGS_PLATFORM = -march=mips3 -mexplicit-relocs -mflush-func=grub_cpu_flush_cache
|
||||
CCASFLAGS_PLATFORM = -march=mips3
|
||||
endif
|
||||
if COND_sparc64_ieee1275
|
||||
CFLAGS_PLATFORM = -mno-app-regs
|
||||
LDFLAGS_PLATFORM = -melf64_sparc -mno-relax
|
||||
endif
|
||||
|
||||
CPPFLAGS_GRUB = -DGRUB_FILE=\"`basename $<`\"
|
||||
CPPFLAGS_GRUB += -I$(builddir) -I$(srcdir) -I$(top_builddir) -I$(top_srcdir)
|
||||
CPPFLAGS_GRUB += -I$(top_srcdir)/include
|
||||
CPPFLAGS_GRUB += -I$(top_builddir)/include
|
||||
CCASFLAGS_GRUB = -DASM_FILE=1
|
||||
|
||||
CFLAGS_GCRY = -Wno-error -Wno-missing-field-initializers
|
||||
CPPFLAGS_GCRY = -I$(top_srcdir)/grub-core/lib/libgcrypt_wrap
|
||||
|
||||
CFLAGS_GNULIB = -Wno-undef -Wno-sign-compare -Wno-unused -D_GL_UNUSED="__attribute__ ((unused))"
|
||||
CPPFLAGS_GNULIB = -I$(top_srcdir)/grub-core/gnulib
|
||||
|
||||
CFLAGS_MKISOFS = -Wno-all -Werror
|
||||
CPPFLAGS_MKISOFS = -D_FILE_OFFSET_BITS=64 -I$(top_srcdir)/util/mkisofs/include
|
||||
|
||||
CFLAGS_POSIX = -fno-builtin
|
||||
CPPFLAGS_POSIX = -I$(top_srcdir)/grub-core/lib/posix_wrap
|
||||
|
||||
CPPFLAGS_EFIEMU = -I$(top_srcdir)/grub-core/efiemu/runtime
|
||||
|
||||
LDADD_KERNEL = -lgcc
|
||||
CFLAGS_KERNEL = $(TARGET_CFLAGS) $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
|
||||
LDFLAGS_KERNEL = $(TARGET_LDFLAGS) $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N -static-libgcc
|
||||
CPPFLAGS_KERNEL = $(TARGET_CPPFLAGS) $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_KERNEL = $(TARGET_CCASFLAGS) $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_MODULE = $(TARGET_CFLAGS) $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -ffreestanding
|
||||
LDFLAGS_MODULE = $(TARGET_LDFLAGS) $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-r,-d
|
||||
CPPFLAGS_MODULE = $(TARGET_CPPFLAGS) $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_MODULE = $(TARGET_CCASFLAGS) $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_IMAGE = $(TARGET_CFLAGS) $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -fno-builtin
|
||||
LDFLAGS_IMAGE = $(TARGET_LDFLAGS) $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM) -nostdlib -Wl,-N,-S
|
||||
CPPFLAGS_IMAGE = $(TARGET_CPPFLAGS) $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_IMAGE = $(TARGET_CCASFLAGS) $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_LIBRARY = $(TARGET_CFLAGS) $(CFLAGS_CPU) $(CFLAGS_PLATFORM) -fno-builtin
|
||||
CPPFLAGS_LIBRARY = $(TARGET_CPPFLAGS) $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_LIBRARY = $(TARGET_CCASFLAGS) $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
CFLAGS_PROGRAM = $(TARGET_CFLAGS) $(CFLAGS_CPU) $(CFLAGS_PLATFORM)
|
||||
LDFLAGS_PROGRAM = $(TARGET_LDFLAGS) $(LDFLAGS_CPU) $(LDFLAGS_PLATFORM)
|
||||
CPPFLAGS_PROGRAM = $(TARGET_CPPFLAGS) $(CPPFLAGS_CPU) $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_PROGRAM = $(TARGET_CCASFLAGS) $(CCASFLAGS_CPU) $(CCASFLAGS_PLATFORM)
|
||||
|
||||
AM_CFLAGS =
|
||||
AM_LDFLAGS =
|
||||
AM_CPPFLAGS = $(CPPFLAGS_GRUB)
|
||||
AM_CCASFLAGS = $(CCASFLAGS_GRUB)
|
||||
CFLAGS_LIBRARY += $(CFLAGS_PLATFORM) -fno-builtin
|
||||
CPPFLAGS_LIBRARY += $(CPPFLAGS_PLATFORM)
|
||||
CCASFLAGS_LIBRARY += $(CCASFLAGS_PLATFORM)
|
||||
|
||||
# gentrigtables
|
||||
gentrigtables: gentrigtables.c
|
||||
|
@ -456,27 +310,27 @@ if COND_ENABLE_EFIEMU
|
|||
efiemu32.o: efiemu/runtime/efiemu.c $(TARGET_OBJ2ELF)
|
||||
-rm -f $@; \
|
||||
if test "x$(TARGET_APPLE_CC)" = x1; then \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF32 -DAPPLE_CC -m32 -Wall -Werror -nostdlib -O2 -c -o $@.bin $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF32 -DAPPLE_CC -m32 -Wall -Werror -nostdlib -O2 -c -o $@.bin $< || exit 1; \
|
||||
$(OBJCONV) -felf32 -nu -nd $@.bin $@ || exit 1; \
|
||||
rm -f $@.bin; \
|
||||
else \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF32 -m32 -Wall -Werror -nostdlib -O2 -c -o $@ $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF32 -m32 -Wall -Werror -nostdlib -O2 -c -o $@ $< || exit 1; \
|
||||
if test ! -z "$(TARGET_OBJ2ELF)"; then $(TARGET_OBJ2ELF) $@ || (rm -f $@; exit 1); fi; \
|
||||
fi
|
||||
|
||||
efiemu64_c.o: efiemu/runtime/efiemu.c
|
||||
if test "x$(TARGET_APPLE_CC)" = x1; then \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF64 -DAPPLE_CC=1 -m64 -nostdlib -Wall -Werror -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF64 -DAPPLE_CC=1 -m64 -nostdlib -Wall -Werror -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
else \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF64 -m64 -nostdlib -Wall -Werror -O2 -mcmodel=large -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF64 -m64 -nostdlib -Wall -Werror -O2 -mcmodel=large -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
fi
|
||||
|
||||
efiemu64_s.o: efiemu/runtime/efiemu.S
|
||||
-rm -f $@
|
||||
if test "x$(TARGET_APPLE_CC)" = x1; then \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF64 -DAPPLE_CC=1 -m64 -Wall -Werror -nostdlib -O2 -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF64 -DAPPLE_CC=1 -m64 -Wall -Werror -nostdlib -O2 -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
else \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_GRUB) -DELF64 -m64 -Wall -Werror -nostdlib -O2 -mcmodel=large -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
$(TARGET_CC) $(DEFS) $(INCLUDES) $(CPPFLAGS_EFIEMU) $(CPPFLAGS_DEFAULT) -DELF64 -m64 -Wall -Werror -nostdlib -O2 -mcmodel=large -mno-red-zone -c -o $@ $< || exit 1; \
|
||||
fi
|
||||
|
||||
efiemu64.o: efiemu64_c.o efiemu64_s.o $(TARGET_OBJ2ELEF)
|
||||
|
|
Loading…
Reference in a new issue