From: Jan Rękorajski Date: Sun, 10 May 2015 09:19:24 +0000 (+0200) Subject: - fix building on x32 X-Git-Tag: auto/th/dynamips-0.2.8-0.RC2.4 X-Git-Url: http://git.pld-linux.org/?p=packages%2Fdynamips.git;a=commitdiff_plain;h=HEAD;ds=sidebyside - fix building on x32 - rel 4 --- diff --git a/dynamips.spec b/dynamips.spec index ad12498..5b826f8 100644 --- a/dynamips.spec +++ b/dynamips.spec @@ -1,5 +1,5 @@ %define subver RC2 -%define rel 3 +%define rel 4 Summary: Cisco 7200 Simulator Summary(pl.UTF-8): Symulator Cisco 7200 Name: dynamips @@ -11,6 +11,7 @@ Source0: http://www.ipflow.utc.fr/dynamips/%{name}-%{version}-%{subver}.tar.gz # Source0-md5: 8d12d28684d164fe3312a3fe43c84d2e Patch0: %{name}-Makefile.patch Patch1: %{name}-debian.patch +Patch2: x32.patch URL: http://www.ipflow.utc.fr/index.php/Cisco_7200_Simulator BuildRequires: elfutils-devel BuildRequires: flex @@ -27,12 +28,15 @@ Symulator Cisco 7200. %setup -q -n %{name}-%{version}-%{subver} %patch0 -p1 %patch1 -p1 +%ifarch x32 +%patch2 -p1 +%endif %build %ifarch %{x8664} ARCH=amd64 %else -%ifarch %{ix86} +%ifarch %{ix86} x32 ARCH=x86 %else ARCH=nojit diff --git a/x32.patch b/x32.patch new file mode 100644 index 0000000..3f6b4a6 --- /dev/null +++ b/x32.patch @@ -0,0 +1,11 @@ +--- dynamips-0.2.8-RC2/mips64_amd64_trans.h~ 2007-10-14 10:43:08.000000000 +0200 ++++ dynamips-0.2.8-RC2/mips64_amd64_trans.h 2015-05-10 11:14:19.522295847 +0200 +@@ -53,7 +53,7 @@ + return; + } + +- asm volatile ("movq %0,%%r15"::"r"(cpu): ++ asm volatile ("mov %0,%%r15"::"r"(cpu): + "r14","r15","rax","rbx","rcx","rdx","rdi","rsi"); + jit_code(); + }