From 6ea90ae2a774711530b80e0abb002fa8c1f1b418 Mon Sep 17 00:00:00 2001
From: jengelh <>
Date: Nov 02 2024 17:28:11 +0000
Subject: Update cm to version 0.4.3 / rev 7 via SR 1220178


https://build.opensuse.org/request/show/1220178
by user jengelh + dimstar_suse
- Add 0001-Include-standard-header-file.patch to resolve FTBFS

---

diff --git a/.files b/.files
index 17cc537..d2995ac 100644
Binary files a/.files and b/.files differ
diff --git a/.rev b/.rev
index 1fd7f07..b5b6eaa 100644
--- a/.rev
+++ b/.rev
@@ -47,4 +47,12 @@
     <comment>- Update to release 0.4.3</comment>
     <requestid>1166925</requestid>
   </revision>
+  <revision rev="7" vrev="2">
+    <srcmd5>f405a56de52d0577ea25471e135647da</srcmd5>
+    <version>0.4.3</version>
+    <time>1730560338</time>
+    <user>dimstar_suse</user>
+    <comment>- Add 0001-Include-standard-header-file.patch to resolve FTBFS</comment>
+    <requestid>1220178</requestid>
+  </revision>
 </revisionlist>
diff --git a/0001-Include-standard-header-file.patch b/0001-Include-standard-header-file.patch
new file mode 100644
index 0000000..9d3d1b3
--- /dev/null
+++ b/0001-Include-standard-header-file.patch
@@ -0,0 +1,58 @@
+From cf3e9ceaaaacd9f2a92c8087a23dc8fd8efd5519 Mon Sep 17 00:00:00 2001
+From: Andreas Enge <andreas.enge@inria.fr>
+Date: Wed, 21 Aug 2024 16:23:04 +0200
+Subject: [PATCH] Include standard header file.
+
+* tests/tecpp.c, tests/ttwist.c: Include stdio.h.
+---
+ tests/tecpp.c  | 3 ++-
+ tests/ttwist.c | 5 +++--
+ 2 files changed, 5 insertions(+), 3 deletions(-)
+
+diff --git a/tests/tecpp.c b/tests/tecpp.c
+index 6cb4802..c20c582 100644
+--- a/tests/tecpp.c
++++ b/tests/tecpp.c
+@@ -2,7 +2,7 @@
+ 
+ tecpp.c - test of ECPP
+ 
+-Copyright (C) 2021, 2022 Andreas Enge
++Copyright (C) 2021, 2022, 2024 Andreas Enge
+ 
+ This file is part of CM.
+ 
+@@ -21,6 +21,7 @@ with CM; see the file COPYING. If not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+ 
++#include <stdio.h>
+ #include "cm.h"
+ 
+ /*****************************************************************************/
+diff --git a/tests/ttwist.c b/tests/ttwist.c
+index 5f1fcdf..9cbea8c 100644
+--- a/tests/ttwist.c
++++ b/tests/ttwist.c
+@@ -1,8 +1,8 @@
+ /*
+ 
+-tcm.c - tests with twisted curves
++ttwist.c - tests with twisted curves
+ 
+-Copyright (C) 2021 Andreas Enge
++Copyright (C) 2021, 2024 Andreas Enge
+ 
+ This file is part of CM.
+ 
+@@ -21,6 +21,7 @@ with CM; see the file COPYING. If not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+ 
++#include <stdio.h>
+ #include "cm.h"
+ 
+ /*****************************************************************************/
+-- 
+2.47.0
+
diff --git a/_scmsync.obsinfo b/_scmsync.obsinfo
new file mode 100644
index 0000000..c72c8cf
--- /dev/null
+++ b/_scmsync.obsinfo
@@ -0,0 +1,4 @@
+mtime: 1730545671
+commit: 243ba751397bb46021ad90db314ce7be0336bac3bb724a7c3c0ce06665e6cb89
+url: https://src.opensuse.org/jengelh/cm
+revision: master
diff --git a/build.specials.obscpio b/build.specials.obscpio
new file mode 120000
index 0000000..f32bcae
--- /dev/null
+++ b/build.specials.obscpio
@@ -0,0 +1 @@
+/ipfs/bafkreihbqvbpy34h2efni7wyaxna3jy6batg37ailkoqhomlle7jqepjpq
\ No newline at end of file
diff --git a/cm.changes b/cm.changes
index 905a462..e124383 100644
--- a/cm.changes
+++ b/cm.changes
@@ -1,4 +1,11 @@
 -------------------------------------------------------------------
+Sat Nov  2 11:06:32 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
+
+- Add 0001-Include-standard-header-file.patch to resolve
+  gcc>=14 FTBFS (preprocessor result of gmp.h changes depending
+  on stdio.h being included before or not)
+
+-------------------------------------------------------------------
 Thu Apr 11 17:59:40 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
 
 - Update to release 0.4.3
diff --git a/cm.spec b/cm.spec
index 7a87da4..d512cf6 100644
--- a/cm.spec
+++ b/cm.spec
@@ -27,6 +27,7 @@ URL:            https://www.multiprecision.org/cm/
 Source:         http://www.multiprecision.org/downloads/%name-%version.tar.gz
 Source2:        http://www.multiprecision.org/downloads/%name-%version.tar.gz.asc
 Source3:        %name.keyring
+Patch1:         0001-Include-standard-header-file.patch
 BuildRequires:  flint-devel >= 3
 BuildRequires:  gmp-devel >= 4.3.2
 BuildRequires:  libtool
@@ -86,8 +87,7 @@ if ! %make_build check; then
 	exit 1
 fi
 
-%post   -n libcm1 -p /sbin/ldconfig
-%postun -n libcm1 -p /sbin/ldconfig
+%ldconfig_scriptlets -n libcm1
 
 %post
 %install_info --info-dir="%_infodir" "%_infodir/cm.info.gz"