[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: powerpc/sparc problems
From: |
Vladimir 'phcoder' Serbinenko |
Subject: |
Re: powerpc/sparc problems |
Date: |
Mon, 12 Oct 2009 11:26:38 +0200 |
User-agent: |
Mozilla-Thunderbird 2.0.0.22 (X11/20090701) |
Felix Zielcke wrote:
> David are you still there?
> And also anyone who has access to a powerpc machine (and experience)?
>
> In Debian we the problem that the `__ashldi3' and `__bswapsi2' symbols
> can't be found in the grub-ieee1275 build on powerpc and also sparc.
>
>
I've come across the same problem when porting grub2 to MIPS. The
solution is the attached patch. I'll test it today on my imac g3
> Jordi already noticed this with the 1.96+20090721-4 IIRC and now other
> people noticed this with 1.97~beta3
> AFAICS there wasn't anything relevant changed on our side, so seems to
> be a gcc issue.
>
> `__ashldi3' is listed in include/grub/powerpc/libgcc.h and `__bswapsi2'
> in the sparc64 header.
> But something has now changed that this isn't enough anymore, at least
> in Debian.
>
> We used gcc 4.3.3 at the time Jordi noticed this and now switched to
> gcc-4.4.1.
>
> And David we still have this sparc bug open, which I forwared to
> grub-devel:
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=538030
>
>
>
--
Regards
Vladimir 'phcoder' Serbinenko
Personal git repository: http://repo.or.cz/w/grub2/phcoder.git
diff --git a/include/grub/powerpc/libgcc.h b/include/grub/powerpc/libgcc.h
index ea4b073..0ff8964 100644
--- a/include/grub/powerpc/libgcc.h
+++ b/include/grub/powerpc/libgcc.h
@@ -16,9 +16,9 @@
* along with GRUB. If not, see <http://www.gnu.org/licenses/>.
*/
-void EXPORT_FUNC (memset) (void) __attribute__ ((weak));
-void EXPORT_FUNC (__ashldi3) (void) __attribute__ ((weak));
-void EXPORT_FUNC (__ashrdi3) (void) __attribute__ ((weak));
-void EXPORT_FUNC (__lshrdi3) (void) __attribute__ ((weak));
-void EXPORT_FUNC (__trampoline_setup) (void) __attribute__ ((weak));
-void EXPORT_FUNC (__ucmpdi2) (void) __attribute__ ((weak));
+void EXPORT_FUNC (memset) (void);
+void EXPORT_FUNC (__ashldi3) (void);
+void EXPORT_FUNC (__ashrdi3) (void);
+void EXPORT_FUNC (__lshrdi3) (void);
+void EXPORT_FUNC (__trampoline_setup) (void);
+void EXPORT_FUNC (__ucmpdi2) (void);
diff --git a/include/grub/sparc64/libgcc.h b/include/grub/sparc64/libgcc.h
index 5d18c5c..6a3d804 100644
--- a/include/grub/sparc64/libgcc.h
+++ b/include/grub/sparc64/libgcc.h
@@ -21,7 +21,7 @@
void EXPORT_FUNC (memset) (void);
typedef int SItype __attribute__ ((mode (SI)));
-SItype EXPORT_FUNC (__bswapsi2) (SItype) __attribute__ ((weak));
+SItype EXPORT_FUNC (__bswapsi2) (SItype);
typedef int DItype __attribute__ ((mode (DI)));
-DItype EXPORT_FUNC (__bswapdi2) (DItype) __attribute__ ((weak));
+DItype EXPORT_FUNC (__bswapdi2) (DItype);