[packages/pnet] - fix building on x32

baggins baggins at pld-linux.org
Mon Apr 27 09:52:09 CEST 2020


commit c47be90d5b170cab994a97bb9c0d33427d832082
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Mon Apr 27 09:49:34 2020 +0200

    - fix building on x32

 pnet.spec |  2 ++
 x32.patch | 20 ++++++++++++++++++++
 2 files changed, 22 insertions(+)
---
diff --git a/pnet.spec b/pnet.spec
index 3efafad..5f65046 100644
--- a/pnet.spec
+++ b/pnet.spec
@@ -19,6 +19,7 @@ Patch3:		no-regex_syntax.patch
 Patch4:		%{name}-info.patch
 Patch5:		%{name}-link.patch
 Patch6:		%{name}-opt.patch
+Patch7:		x32.patch
 URL:		http://www.gnu.org/software/dotgnu/pnet.html
 BuildRequires:	autoconf
 BuildRequires:	automake
@@ -304,6 +305,7 @@ Header de desenvolviemnto da Portable .NET.
 %ifarch %{ix86}
 %patch6 -p1
 %endif
+%patch7 -p1
 
 %{__rm} ilasm/ilasm_grammar.c
 
diff --git a/x32.patch b/x32.patch
new file mode 100644
index 0000000..b65c1e1
--- /dev/null
+++ b/x32.patch
@@ -0,0 +1,20 @@
+--- pnet-0.8.0/support/interlocked_x86.h.orig	2020-04-27 09:47:43.129859127 +0200
++++ pnet-0.8.0/support/interlocked_x86.h	2020-04-27 09:48:05.713191727 +0200
+@@ -114,7 +114,7 @@
+ 	__asm__ __volatile__
+ 	(
+ 		"lock;"
+-#if defined(__x86_64__)
++#if defined(__x86_64__) && !defined(__ILP32__)
+ 		"cmpxchgq %2, %0;"
+ #else
+ 		"cmpxchgl %2, %0;"
+@@ -137,7 +137,7 @@
+ 	(
+ 		"1:;"
+ 		"lock;"
+-#if defined(__x86_64__)
++#if defined(__x86_64__) && !defined(__ILP32__)
+ 		"cmpxchgq %2, %0;"
+ #else
+ 		"cmpxchgl %2, %0;"
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/pnet.git/commitdiff/c47be90d5b170cab994a97bb9c0d33427d832082



More information about the pld-cvs-commit mailing list