Opened 3 years ago

Closed 3 years ago

#61635 closed defect (fixed)

calc @2.12.6.8: error: expected parameter declarator

Reported by: leuliett (Eric Leuliette) Owned by: pmetzger (Perry E. Metzger)
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: bigsur Cc: mrichmon (Michael Richmond)
Port: calc

Description (last modified by ryandesign (Ryan Carsten Schmidt))

The function declarations for memmove and __builtin___memmove_chk in alloc.h aren't compatible with the include files with Xcode12.2/BigSure: /Library/Developer/CommandLineTools/SDKs/MacOSX11.0.sdk/usr/include/secure/

Attachments (1)

main.log (20.1 KB) - added by leuliett (Eric Leuliette) 3 years ago.
calc/main.log

Download all attachments as: .zip

Change History (8)

Changed 3 years ago by leuliett (Eric Leuliette)

Attachment: main.log added

calc/main.log

comment:1 Changed 3 years ago by leuliett (Eric Leuliette)

Port: calc-2.12.6.8 added

comment:2 Changed 3 years ago by mrichmon (Michael Richmond)

Cc: mrichmon added

comment:3 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: bigsur added; Big Sur removed
Owner: set to pmetzger
Port: calc added; calc-2.12.6.8 removed
Status: newassigned
Summary: calc-2.12.6.8 errors calling __builtin___memmove_chk when building with Big Sur/Xcode 12.2calc @2.12.6.8: error: expected parameter declarator
:info:build ../alloc.h:88:14: error: expected parameter declarator
:info:build E_FUNC void *memmove(void *s1, CONST void *s2, MEMMOVE_SIZE_T n);
:info:build              ^
:info:build /Library/Developer/CommandLineTools/SDKs/MacOSX11.0.sdk/usr/include/secure/_string.h:70:47: note: expanded from macro 'memmove'
:info:build                 __builtin___memmove_chk (dest, __VA_ARGS__, __darwin_obsz0 (dest))
:info:build                                                             ^

It looks like it's trying to redefine the standard memmove function. The project's build system has code that's supposed to determine whether the system has a standard memmove function; that determination might not be working correctly in this case.

If this were a normal autotools project we would look for implicit declaration of function errors in the config.log but this project does not use autotools and does not have a config.log so I'm not sure if the errors are saved anywhere for us to look at.

The determination of memmove availability is made using the source file have_memmv.c. In that file I see that it is trying to use the function memmove but does not have the line #include <string.h> which is where that function is defined. Adding that line to that file may help, but there may be other tests that need similar fixes.

It looks like we could get the build system to disable quiet mode and thus maybe see the results of running these tests by adding Q= to the build args.

A new version of calc is available. We should probably start by updating to that version and see if that improves the situation.

comment:4 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)

comment:5 Changed 3 years ago by mrichmon (Michael Richmond)

Attempted basic compile of current latest calc-2.12.7.1 code. Same memmove type error occurs. Opened issue on calc github repo: https://github.com/lcn2/calc/issues/19

comment:6 Changed 3 years ago by pmetzger (Perry E. Metzger)

FYI, apparently this is all fixed in 2.12.7.5 — if someone wants to submit patches to update to that version, it would be welcome. I will get to it eventually if no one else does.

comment:7 Changed 3 years ago by pmetzger (Perry E. Metzger)

Resolution: fixed
Status: assignedclosed

I've now updated to 2.12.7.5. I haven't tried the build on Apple Silicon but I suspect that will now work as well.

Note: See TracTickets for help on using tickets.