Summary: | science/mpb: Fails to build with GCC 14: error: implicit declaration of function 'SCM_NEWCELL' [-Wimplicit-function-declaration] | ||||||
---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | Lorenzo Salvadore <salvadore> | ||||
Component: | Individual Port(s) | Assignee: | Rainer Hurling <rhurlin> | ||||
Status: | Closed FIXED | ||||||
Severity: | Affects Only Me | CC: | gerald, rhurlin | ||||
Priority: | --- | Flags: | rhurlin:
maintainer-feedback+
|
||||
Version: | Latest | ||||||
Hardware: | Any | ||||||
OS: | Any | ||||||
URL: | https://pkg-status.freebsd.org/gohan04/data/140amd64-default-foo/2024-08-29_19h57m48s/logs/errors/mpb-1.11.1_8.log | ||||||
Bug Depends on: | |||||||
Bug Blocks: | 281091 | ||||||
Attachments: |
|
Description
Lorenzo Salvadore
![]() ![]() Hi Lorenzo, Thanks for the report. I must confess that with my very limited knowledge of C/C++ I have not yet found a solution. In fact, there was already an issue in the mpb project on Github [1], in which a two patches are suggested. However, these did not eliminate the actual error with SCM_NEWCELL for me. I haven't gotten any further so far, but I could use some help from here on. P.S.: I'm AFK until Sept 27, so I can't help or test until then. [1] https://github.com/NanoComp/mpb/issues/165 Created attachment 256007 [details]
Fix build with GCC 14
This patch adds the -fpermissive flag so that the build works with GCC 14. Does the maintainer approve?
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=abffdd9a18a7aef287ccd21897fdc91c792cbc4d commit abffdd9a18a7aef287ccd21897fdc91c792cbc4d Author: Lorenzo Salvadore <salvadore@freebsd.org> AuthorDate: 2024-12-21 17:46:44 +0000 Commit: Rainer Hurling <rhurlin@FreeBSD.org> CommitDate: 2024-12-21 17:52:22 +0000 science/mpb: Fix build with GCC 14 error: implicit declaration of function 'SCM_NEWCELL' [-Wimplicit-function-declaration] Thanks for the patch to salvadore@ PR: 281245 science/mpb/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Hi Lorenzo, Thanks for the patch! I'm really very sorry, I had lost sight of this bug and didn't bother. With the patch the port can be built very well with gcc14. Also the tests all seem to be ok: # make test [..] Finished solving for bands 1 to 3 after 56 iterations. freqs:, 1, 0.12, 0.34, 0.41, 0.545985, 0.291848, 0.315613, 0.491642 elapsed time for k point: 1 seconds. total elapsed time for run: 1 seconds. done. check-almost-equal: PASSED check-almost-equal: PASSED eigensolver iterations for 84 k-points: 8-9963/10, mean = 89.26369047619048, median = 19.0 mean flops per iteration = 5316807.658155679 mean time per iteration = 0.007735241359535352 s Relative error ranged from 0.0 to 1.9765712311535006e-4, with a mean of 2.0205952373393855e-6 Absolute error ranged to 1.0067210840147833e-4, with a mean of 8.857129426257578e-7 PASSED all tests. Making check in examples Making check in utils I have therefore committed the patch. Thanks again! (In reply to Lorenzo Salvadore from comment #2) > This patch adds the -fpermissive flag so that the build works with > GCC 14. Does the maintainer approve? Adding -fpermissive isn't really a fix, it's a hack to force a build on software not honoring a language standard that's three decades old. IMnsHO any such change should be accompanied by deprecating the respective port, even if with a generous EXPIRATION_DATE of, let's say, four to six months in the future. |