Merge ~mirespace/ubuntu/+source/form:fix-gcc-14-new-standards into ubuntu/+source/form:ubuntu/oracular-devel

Proposed by Miriam España Acebal
Status: Merged
Merge reported by: Miriam España Acebal
Merged at revision: 39d39cbaf88ae32ea4d411d59d3ee46b9b42457f
Proposed branch: ~mirespace/ubuntu/+source/form:fix-gcc-14-new-standards
Merge into: ubuntu/+source/form:ubuntu/oracular-devel
Diff against target: 133 lines (+100/-1)
4 files modified
debian/changelog (+7/-0)
debian/control (+2/-1)
debian/patches/fix-gcc-14-incompatible-pointer-types (+90/-0)
debian/patches/series (+1/-0)
Reviewer Review Type Date Requested Status
Erich Eickmeyer (community) Approve
Daniel Draper Pending
MOTU Pending
Ubuntu Sponsors Pending
Review via email: mp+470565@code.launchpad.net

Description of the change

Hi team,

ppa for this is (all builds OK)

ppa:mirespace/plusone
https://launchpad.net/~mirespace/+archive/ubuntu/plusone

I've forwarded the changes to upstream [2].

The package doesn't have the tests enabled. However:
 - it is possible to make it run but with failures (I suppose that's why they are skipped in Debian). I'll open a bug for it in LP.
 - upstream's tests for the MP in Github are passing [3]

The fix was applied as proposed by [1], making the castings explicitly.

[1] https://gcc.gnu.org/gcc-14/porting_to.html#warnings-as-errors
[2] https://github.com/vermaseren/form/pull/549
[3] https://github.com/vermaseren/form/pull/549/checks

To post a comment you must log in.
Revision history for this message
Erich Eickmeyer (eeickmeyer) :
review: Approve (lgtm)
Revision history for this message
Erich Eickmeyer (eeickmeyer) wrote :

LGTM

review: Approve
Revision history for this message
Miriam España Acebal (mirespace) wrote :

Thanks Erich!

Marking this as Merged, as the packaged was sponsored and uploaded at

https://launchpad.net/ubuntu/oracular/+upload/34075526/+files/form_4.3.1+git20240409+ds-2ubuntu1_source.changes

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/debian/changelog b/debian/changelog
2index 207abd2..26c49d6 100644
3--- a/debian/changelog
4+++ b/debian/changelog
5@@ -1,3 +1,10 @@
6+form (4.3.1+git20240409+ds-2ubuntu1) oracular; urgency=medium
7+
8+ * d/p/fix-gcc-14-incompatible-pointer-types: Adapt code to gcc-14
9+ new standards making explicit castings (LP: #2075550).
10+
11+ -- Miriam España Acebal <miriam.espana@canonical.com> Thu, 01 Aug 2024 15:50:07 +0200
12+
13 form (4.3.1+git20240409+ds-2build1) oracular; urgency=medium
14
15 * No-change rebuild against mpi-defaults 1.17
16diff --git a/debian/control b/debian/control
17index 6a034c9..30ec1e3 100644
18--- a/debian/control
19+++ b/debian/control
20@@ -1,7 +1,8 @@
21 Source: form
22 Section: science
23 Priority: optional
24-Maintainer: Debian Science Team <debian-science-maintainers@lists.alioth.debian.org>
25+Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
26+XSBC-Original-Maintainer: Debian Science Team <debian-science-maintainers@lists.alioth.debian.org>
27 Uploaders: Alex Myczko <tar@debian.org>
28 Build-Depends: debhelper-compat (=13),
29 mpi-default-dev,
30diff --git a/debian/patches/fix-gcc-14-incompatible-pointer-types b/debian/patches/fix-gcc-14-incompatible-pointer-types
31new file mode 100644
32index 0000000..1d80428
33--- /dev/null
34+++ b/debian/patches/fix-gcc-14-incompatible-pointer-types
35@@ -0,0 +1,90 @@
36+Description: Fix incompatible-pointer-types error in GCC-14
37+ GCC no longer allows implicitly casting all pointer types to all
38+ other pointer types.Therefore, this patch make the explicit casting
39+ to the expected type where required.
40+Author: Miriam España Acebal <miriam.espana@canonical.com>
41+Forwarded: https://github.com/vermaseren/form/pull/549
42+Last-Update: 2024-08-01
43+---
44+--- a/sources/compcomm.c
45++++ b/sources/compcomm.c
46+@@ -122,19 +122,19 @@
47+ ,{"threadsortfilesynch",&(AC.ThreadSortFileSynch),1, 0}
48+ ,{"threadstats", &(AC.ThreadStats),1, 0}
49+ ,{"finalstats", &(AC.FinalStats),1, 0}
50+- ,{"fewerstats", &(AC.ShortStatsMax), 10, 0}
51+- ,{"fewerstatistics",&(AC.ShortStatsMax), 10, 0}
52++ ,{"fewerstats", (int *)&(AC.ShortStatsMax), 10, 0}
53++ ,{"fewerstatistics",(int *)&(AC.ShortStatsMax), 10, 0}
54+ ,{"processstats", &(AC.ProcessStats),1, 0}
55+ ,{"oldparallelstats",&(AC.OldParallelStats),1,0}
56+ ,{"parallel", &(AC.parallelflag),PARALLELFLAG,NOPARALLEL_USER}
57+ ,{"nospacesinnumbers",&(AO.NoSpacesInNumbers),1,0}
58+- ,{"indentspace", &(AO.IndentSpace),INDENTSPACE,0}
59++ ,{"indentspace", (int *)&(AO.IndentSpace),INDENTSPACE,0}
60+ ,{"totalsize", &(AM.PrintTotalSize), 1, 0}
61+ ,{"flag", (int *)&(AC.debugFlags), 1, 0}
62+ ,{"oldfactarg", &(AC.OldFactArgFlag), 1, 0}
63+ ,{"memdebugflag", &(AC.MemDebugFlag), 1, 0}
64+ ,{"oldgcd", &(AC.OldGCDflag), 1, 0}
65+- ,{"innertest", &(AC.InnerTest), 1, 0}
66++ ,{"innertest", (int *)&(AC.InnerTest), 1, 0}
67+ ,{"wtimestats", &(AC.WTimeStatsFlag), 1, 0}
68+ };
69+
70+--- a/sources/reshuf.c
71++++ b/sources/reshuf.c
72+@@ -2144,7 +2144,7 @@
73+ passed on.
74+ */
75+ SHback = AN.SHvar;
76+- SH->finishuf = &FinishShuffle;
77++ SH->finishuf = (FINISHUFFLE) &FinishShuffle;
78+ SH->do_uffle = &DoShuffle;
79+ SH->outterm = AT.WorkPointer;
80+ AT.WorkPointer += *term;
81+@@ -2638,7 +2638,7 @@
82+ *AN.RepPoint = 1;
83+
84+ SHback = AN.SHvar;
85+- SH->finishuf = &FinishStuffle;
86++ SH->finishuf = (FINISHUFFLE) &FinishStuffle;
87+ SH->do_uffle = &DoStuffle;
88+ SH->outterm = AT.WorkPointer;
89+ AT.WorkPointer += *term;
90+@@ -2737,9 +2737,9 @@
91+ */
92+ SH->stop1 = SH->ststop1;
93+ SH->stop2 = SH->ststop2;
94+- SH->finishuf = &FinishShuffle;
95++ SH->finishuf = (FINISHUFFLE) &FinishShuffle;
96+ if ( Shuffle(from1,from2,to) ) goto stuffcall;
97+- SH->finishuf = &FinishStuffle;
98++ SH->finishuf = (FINISHUFFLE) &FinishStuffle;
99+ /*
100+ Now we have to select a pair, one from 1 and one from 2.
101+ */
102+--- a/sources/float.c
103++++ b/sources/float.c
104+@@ -2321,15 +2321,15 @@
105+ */
106+ AT.WorkPointer += depth;
107+ if ( first ) {
108+- if ( *t == MZV ) CalculateMZV(aux4,indexes,depth);
109+- else if ( *t == EULER ) CalculateEuler(aux4,indexes,depth);
110+- else if ( *t == MZVHALF ) CalculateMZVhalf(aux4,indexes,depth);
111++ if ( *t == MZV ) CalculateMZV(aux4,(int *)indexes,depth);
112++ else if ( *t == EULER ) CalculateEuler(aux4,(int *)indexes,depth);
113++ else if ( *t == MZVHALF ) CalculateMZVhalf(aux4,(int *)indexes,depth);
114+ first = 0;
115+ }
116+ else {
117+- if ( *t == MZV ) CalculateMZV(aux5,indexes,depth);
118+- else if ( *t == EULER ) CalculateEuler(aux5,indexes,depth);
119+- else if ( *t == MZVHALF ) CalculateMZVhalf(aux5,indexes,depth);
120++ if ( *t == MZV ) CalculateMZV(aux5,(int *)indexes,depth);
121++ else if ( *t == EULER ) CalculateEuler(aux5,(int *)indexes,depth);
122++ else if ( *t == MZVHALF ) CalculateMZVhalf(aux5,(int *)indexes,depth);
123+ mpf_mul(aux4,aux4,aux5);
124+ }
125+ *t = 0;
126diff --git a/debian/patches/series b/debian/patches/series
127index 4c29051..5e82f7d 100644
128--- a/debian/patches/series
129+++ b/debian/patches/series
130@@ -1,2 +1,3 @@
131 #fix-escaping
132 #omit-march
133+fix-gcc-14-incompatible-pointer-types

Subscribers

People subscribed via source and target branches