[packages/grub] - updated gcc4 patch - fixed build with latest automake - -fPIC and SSP prevent grub from building,
baggins
baggins at pld-linux.org
Sun Jan 26 20:34:39 CET 2014
commit 3798578fabb8a37d8bf09a5f6c24dd337eb491a6
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Sun Jan 26 20:26:01 2014 +0100
- updated gcc4 patch
- fixed build with latest automake
- -fPIC and SSP prevent grub from building, disabled
grub-am.patch | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
grub-gcc4.patch | 20 ++++++++++++++++++++
grub-pxe.patch | 2 +-
grub.spec | 6 ++++++
4 files changed, 75 insertions(+), 1 deletion(-)
---
diff --git a/grub.spec b/grub.spec
index 6dc932c..d1145be 100644
--- a/grub.spec
+++ b/grub.spec
@@ -40,6 +40,7 @@ Patch11: %{name}-useless.patch
Patch12: %{name}-ac.patch
Patch13: %{name}-i2o.patch
Patch14: %{name}-pxe.patch
+Patch15: %{name}-am.patch
URL: https://www.gnu.org/software/grub/grub-legacy.html
BuildRequires: autoconf
BuildRequires: automake
@@ -50,6 +51,7 @@ BuildRequires: glibc-static
BuildRequires: ncurses-static
%endif
%ifarch %{x8664}
+BuildRequires: gcc-multilib
BuildRequires: /usr/lib/libc.a
%endif
# needed for 'cmp' program
@@ -59,6 +61,9 @@ Obsoletes: fedora-logos
ExclusiveArch: %{ix86} %{x8664}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+%define _ssp_cflags %{nil}
+%define filterout -fPIC
+
%define _sbindir /sbin
%define _libdir /boot
@@ -174,6 +179,7 @@ Wsparcie gruba dla rc-boot.
%patch12 -p1
%patch13 -p1
%patch14 -p0
+%patch15 -p1
rm -rf doc/*info*
diff --git a/grub-am.patch b/grub-am.patch
new file mode 100644
index 0000000..d1527b5
--- /dev/null
+++ b/grub-am.patch
@@ -0,0 +1,48 @@
+--- grub-0.97/stage1/Makefile.am~ 2004-07-16 13:44:56.000000000 +0200
++++ grub-0.97/stage1/Makefile.am 2014-01-26 19:30:31.468165604 +0100
+@@ -1,7 +1,7 @@
+-pkglibdir = $(libdir)/$(PACKAGE)/$(host_cpu)-$(host_vendor)
+-nodist_pkglib_DATA = stage1
++pkgdatadir = $(libdir)/$(PACKAGE)/$(host_cpu)-$(host_vendor)
++nodist_pkgdata_DATA = stage1
+
+-CLEANFILES = $(nodist_pkglib_DATA)
++CLEANFILES = $(nodist_pkgdata_DATA)
+
+ # We can't use builtins or standard includes.
+ AM_CCASFLAGS = $(STAGE1_CFLAGS) -fno-builtin -nostdinc
+--- grub-0.97/stage2/Makefile.am~ 2014-01-26 19:29:48.000000000 +0100
++++ grub-0.97/stage2/Makefile.am 2014-01-26 19:32:24.694831451 +0100
+@@ -28,12 +28,12 @@
+ -fno-strict-aliasing
+
+ # Stage 2 and Stage 1.5's.
+-pkglibdir = $(libdir)/$(PACKAGE)/$(host_cpu)-$(host_vendor)
++pkgdatadir = $(libdir)/$(PACKAGE)/$(host_cpu)-$(host_vendor)
+
+ EXTRA_PROGRAMS = nbloader.exec pxeloader.exec diskless.exec
+
+ if DISKLESS_SUPPORT
+-pkglib_DATA = stage2 stage2_eltorito e2fs_stage1_5 fat_stage1_5 \
++pkgdata_DATA = stage2 stage2_eltorito e2fs_stage1_5 fat_stage1_5 \
+ ffs_stage1_5 iso9660_stage1_5 jfs_stage1_5 minix_stage1_5 \
+ reiserfs_stage1_5 ufs2_stage1_5 vstafs_stage1_5 xfs_stage1_5 \
+ nbgrub pxegrub
+@@ -44,7 +44,7 @@
+ reiserfs_stage1_5.exec ufs2_stage1_5.exec vstafs_stage1_5.exec \
+ xfs_stage1_5.exec nbloader.exec pxeloader.exec diskless.exec
+ else
+-pkglib_DATA = stage2 stage2_eltorito e2fs_stage1_5 fat_stage1_5 \
++pkgdata_DATA = stage2 stage2_eltorito e2fs_stage1_5 fat_stage1_5 \
+ ffs_stage1_5 iso9660_stage1_5 jfs_stage1_5 minix_stage1_5 \
+ reiserfs_stage1_5 ufs2_stage1_5 vstafs_stage1_5 xfs_stage1_5
+ noinst_DATA = pre_stage2 start start_eltorito
+@@ -108,7 +108,7 @@
+ BUILT_SOURCES = stage2_size.h
+ endif
+
+-CLEANFILES = $(pkglib_DATA) $(noinst_DATA) $(BUILT_SOURCES)
++CLEANFILES = $(pkgdata_DATA) $(noinst_DATA) $(BUILT_SOURCES)
+
+ stage2_size.h: pre_stage2
+ -rm -f stage2_size.h
diff --git a/grub-gcc4.patch b/grub-gcc4.patch
index cc9933b..adc2156 100644
--- a/grub-gcc4.patch
+++ b/grub-gcc4.patch
@@ -40,3 +40,23 @@
/* wait */ ;
if (currticks() >= to) {
+--- grub-0.97/netboot/sis900.c~ 2014-01-26 20:00:16.000000000 +0100
++++ grub-0.97/netboot/sis900.c 2014-01-26 20:01:57.941485281 +0100
+@@ -901,7 +901,7 @@
+ const char *p) /* Packet */
+ {
+ u32 status, to, nstype;
+- u32 tx_status;
++ volatile u32 tx_status;
+
+ /* Stop the transmitter */
+ outl(TxDIS, ioaddr + cr);
+@@ -940,7 +940,7 @@
+
+ to = currticks() + TX_TIMEOUT;
+
+- while ((((volatile u32) tx_status=txd.cmdsts) & OWN) && (currticks() < to))
++ while (((tx_status=txd.cmdsts) & OWN) && (currticks() < to))
+ /* wait */ ;
+
+ if (currticks() >= to) {
diff --git a/grub-pxe.patch b/grub-pxe.patch
index 779569e..ec34a84 100644
--- a/grub-pxe.patch
+++ b/grub-pxe.patch
@@ -48747,7 +48747,7 @@ Index: netboot/sis900.c
{
- u32 status, to, nstype;
+ u32 to, nstype;
- u32 tx_status;
+ volatile u32 tx_status;
/* Stop the transmitter */
- outl(TxDIS, ioaddr + cr);
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/grub.git/commitdiff/3798578fabb8a37d8bf09a5f6c24dd337eb491a6
More information about the pld-cvs-commit
mailing list