Opened 4 years ago

Last modified 4 years ago

#61759 closed defect

scale2x @2.4_2: implicit declared function strcmp — at Initial Version

Reported by: MaddTheSane (C.W. Betts) Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.6.4
Keywords: bigsur catalina Cc:
Port: scale2x

Description

This is another case of a file not including the right header:

:info:build scalex.c:149:9: error: implicitly declaring library function 'strcmp' with type 'int (const char *, const char *)' [-Werror,-Wimplicit-function-declaration]
:info:build                                 if (strcmp(optarg, "2") == 0) {
:info:build                                     ^
:info:build scalex.c:149:9: note: include the header <string.h> or explicitly provide a declaration for 'strcmp'
:info:build 1 error generated.
:info:build make[1]: *** [scalex.o] Error 1
:info:build make[1]: *** Waiting for unfinished jobs....
:info:build scalerx.c:606:9: error: implicitly declaring library function 'strcmp' with type 'int (const char *, const char *)' [-Werror,-Wimplicit-function-declaration]
:info:build                                 if (strcmp(optarg, "2") == 0) {
:info:build                                     ^
:info:build scalerx.c:606:9: note: include the header <string.h> or explicitly provide a declaration for 'strcmp'
:info:build 1 error generated.
:info:build make[1]: *** [scalerx.o] Error 1

It looks like a simple patch will make it compile fine.

Change History (0)

Note: See TracTickets for help on using tickets.