From 870f5bdfe70002cc2c2bf2f8a73f4878d6289396 Mon Sep 17 00:00:00 2001 From: Jitesh Shah Date: Fri, 14 Aug 2009 11:43:42 +0200 Subject: [PATCH] Pre-processor fix for ARM Signed-off-by: Jitesh Shah --- cln-arm-preprocessor-fix.patch | 68 ++++++++++++++++++++++++++++++++++++++++ cln.spec | 7 +++- 2 files changed, 74 insertions(+), 1 deletions(-) create mode 100644 cln-arm-preprocessor-fix.patch diff --git a/cln-arm-preprocessor-fix.patch b/cln-arm-preprocessor-fix.patch new file mode 100644 index 0000000..6446b56 --- /dev/null +++ b/cln-arm-preprocessor-fix.patch @@ -0,0 +1,68 @@ +diff -dur cln-1.2.2.backup/src/base/digitseq/cl_asm_arm_.cc cln-1.2.2/src/base/digitseq/cl_asm_arm_.cc +--- cln-1.2.2.backup/src/base/digitseq/cl_asm_arm_.cc 2001-05-25 16:00:18.000000000 -0400 ++++ cln-1.2.2/src/base/digitseq/cl_asm_arm_.cc 2009-08-18 12:21:20.000000000 -0400 +@@ -42,6 +42,7 @@ + + #define C(x) _##x + #define EXPORT(x) EXPORT x ++#define DECLARE_WORD(x) x + #define DECLARE_FUNCTION(x) + #define GLABEL(x) _##x + #define LABEL(x) _##x +@@ -70,15 +71,33 @@ + lr .req r14 + pc .req r15 + ++ ++ ++#ifdef ASM_UNDERSCORE + #define C(x) _##x + #define EXPORT(x) .global _##x ++#define DECLARE_WORD(x) .word _##x + #if defined(__NetBSD__) + #define DECLARE_FUNCTION(x) .type _##x,%function + #else + #define DECLARE_FUNCTION(x) + #endif +-#define GLABEL(x) _##x##: +-#define LABEL(x) x##: ++#define GLABEL(x) _##x: ++ ++#else ++#define C(x) x ++#define EXPORT(x) .global x ++#define DECLARE_WORD(x) .word x ++#if defined(__NetBSD__) ++#define DECLARE_FUNCTION(x) .type x,%function ++#else ++#define DECLARE_FUNCTION(x) ++#endif ++#define GLABEL(x) x: ++ ++#endif ++ ++#define LABEL(x) x: + #define RRX rrx + #define END + +@@ -128,17 +147,17 @@ + + #ifdef MULU32_HIGH + ptr_mulu32_high: +- .word _mulu32_high ++ DECLARE_WORD(mulu32_high) + .align 0 + #endif + #ifdef DIVU_16_REST + ptr_divu_16_rest: +- .word _divu_16_rest ++ DECLARE_WORD(divu_16_rest) + .align 0 + #endif + #ifdef DIVU_32_REST + ptr_divu_32_rest: +- .word _divu_32_rest ++ DECLARE_WORD(divu_32_rest) + .align 0 + #endif + diff --git a/cln.spec b/cln.spec index 1e49697..92ca38b 100644 --- a/cln.spec +++ b/cln.spec @@ -1,6 +1,6 @@ Name: cln Version: 1.3.0 -Release: 2%{?dist} +Release: 2%{?dist}.fa1 Summary: Class Library for Numbers Group: System Environment/Libraries @@ -8,6 +8,7 @@ License: GPLv2+ URL: http://www.ginac.de/CLN/ Source0: http://www.ginac.de/CLN/%{name}-%{version}.tar.bz2 Patch0: cln-1.2.2-s390x.patch +Patch1: cln-arm-preprocessor-fix.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires(post): /sbin/install-info @@ -36,6 +37,7 @@ the CLN library. %prep %setup -q %patch0 -p1 -b .s390x +%patch1 -p1 -b .arm %build %configure --disable-static @@ -86,6 +88,9 @@ fi %{_docdir}/%{name}-devel-%{version} %changelog +* Fri Oct 21 2009 Jitesh Shah - 1.3.0-2.fa1 +- Add pre-processor fix for building on ARM (for building with GNU tools) + * Fri Jul 24 2009 Fedora Release Engineering - 1.3.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild -- 1.5.5.6