From: Andrey Borzenkov <arvidjaar@gmail.com>
To: grub-devel@gnu.org
Subject: [PATCH] define rs_decoder.S and sm712_start.S as nodist header files
Date: Thu, 2 May 2013 15:52:33 +0400 [thread overview]
Message-ID: <1367495553-19655-1-git-send-email-arvidjaar@gmail.com> (raw)
The first fixes "make dist" on 64 bit EFI:
make[2]: Entering directory `/home/bor/build/grub/grub-core'
gcc -Wall -W -I../include -I../include -DGRUB_MACHINE_EFI=1 -DGRUB_MACHINE=X86_64_EFI -DGRUB_TARGET_CPU_X86_64=1 -m64 ... -Wtrampolines -DUSE_ASCII_FAILBACK=1 -DHAVE_UNIFONT_WIDTHSPEC=1 -Os -I.. -S -DSTANDALONE -o rs_decoder.S lib/reed_solomon.c -g0 -mregparm=3 -ffreestanding
lib/reed_solomon.c:1:0: error: -mregparm is ignored in 64-bit mode [-Werror]
cc1: all warnings being treated as errors
make[2]: *** [rs_decoder.S] Error 1
make[2]: Leaving directory `/home/bor/build/grub/grub-core'
make[1]: *** [distdir] Error 1
make[1]: Leaving directory `/home/bor/build/grub'
make: *** [dist] Error 2
Add rs_decoder.S as NODIST header to kernel to avoid triggering rebuild
on "make dist". As it should not be compiled on its own, but included,
rename it into rs_decoder.h, so automake does the right thing.
For consistency do the same with sm712_start.S which is not required during
"make dist" as well.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
---
grub-core/Makefile.am | 9 +++------
grub-core/Makefile.core.def | 2 ++
grub-core/boot/i386/pc/startup_raw.S | 2 +-
grub-core/boot/mips/loongson/fwstart.S | 2 +-
4 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/grub-core/Makefile.am b/grub-core/Makefile.am
index fa6afcf..6d810e9 100644
--- a/grub-core/Makefile.am
+++ b/grub-core/Makefile.am
@@ -45,9 +45,9 @@ gensm712: video/sm712.c
CLEANFILES += gensm712
# trigtables.c
-sm712_start.S: gensm712 video/sm712.c $(top_srcdir)/configure.ac
+sm712_start.h: gensm712 video/sm712.c $(top_srcdir)/configure.ac
$(builddir)/gensm712 > $@
-CLEANFILES += sm712_start.S
+CLEANFILES += sm712_start.h
# XXX Use Automake's LEX & YACC support
grub_script.tab.h: script/parser.y
@@ -60,12 +60,9 @@ grub_script.yy.h: script/yylex.l
$(LEX) -o grub_script.yy.c --header-file=grub_script.yy.h $<
grub_script.yy.c: grub_script.yy.h
-rs_decoder.S: $(srcdir)/lib/reed_solomon.c
+rs_decoder.h: $(srcdir)/lib/reed_solomon.c
$(TARGET_CC) $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) -Os -I$(top_builddir) -S -DSTANDALONE -o $@ $< -g0 -mregparm=3 -ffreestanding
-boot/i386/pc/startup_raw.S: $(builddir)/rs_decoder.S
-boot/mips/loongson/fwstart.S: $(builddir)/sm712_start.S
-
CLEANFILES += grub_script.yy.c grub_script.yy.h
include $(srcdir)/Makefile.core.am
diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def
index 7e19acb..0715971 100644
--- a/grub-core/Makefile.core.def
+++ b/grub-core/Makefile.core.def
@@ -396,6 +396,7 @@ image = {
image = {
name = lzma_decompress;
i386_pc = boot/i386/pc/startup_raw.S;
+ i386_pc_nodist = rs_decoder.h;
objcopyflags = '-O binary';
ldflags = '$(TARGET_IMG_LDFLAGS) $(TARGET_IMG_BASE_LDOPT),0x8200';
@@ -405,6 +406,7 @@ image = {
image = {
name = fwstart;
mips_loongson = boot/mips/loongson/fwstart.S;
+ mips_loongson_nodist = sm712_start.h;
objcopyflags = '-O binary';
ldflags = '-static-libgcc -lgcc -Wl,-N,-S,-Ttext,0xbfc00000,-Bstatic';
enable = mips_loongson;
diff --git a/grub-core/boot/i386/pc/startup_raw.S b/grub-core/boot/i386/pc/startup_raw.S
index 81c0bc4..06dec8c 100644
--- a/grub-core/boot/i386/pc/startup_raw.S
+++ b/grub-core/boot/i386/pc/startup_raw.S
@@ -119,7 +119,7 @@ LOCAL (codestart):
#include "../../../kern/i386/realmode.S"
-#include <rs_decoder.S>
+#include <rs_decoder.h>
.text
diff --git a/grub-core/boot/mips/loongson/fwstart.S b/grub-core/boot/mips/loongson/fwstart.S
index ec57be6..11ad1c9 100644
--- a/grub-core/boot/mips/loongson/fwstart.S
+++ b/grub-core/boot/mips/loongson/fwstart.S
@@ -886,7 +886,7 @@ table_cont:
b init_end
nop
init_table:
-#include "sm712_start.S"
+#include "sm712_start.h"
init_table_end:
.align 4
init_end:
--
tg: (93daf86..) u/startup_raw_nodist (depends on: master)
next reply other threads:[~2013-05-02 11:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-02 11:52 Andrey Borzenkov [this message]
2013-05-02 12:06 ` [PATCH] define rs_decoder.S and sm712_start.S as nodist header files Vladimir 'φ-coder/phcoder' Serbinenko
2013-05-02 12:20 ` Andrey Borzenkov
2013-05-31 17:14 ` Andrey Borzenkov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1367495553-19655-1-git-send-email-arvidjaar@gmail.com \
--to=arvidjaar@gmail.com \
--cc=grub-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.