Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#65169 closed defect (fixed)

mgzip @1.2c_1 fails to build due to implicit declarations

Reported by: jmroot (Joshua Root) Owned by: nerdling (Jeremy Lavergne)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port: mgzip

Description

die.c:20:38: error: implicitly declaring library function 'strerror' with type 'char *(int)' [-Werror,-Wimplicit-function-declaration]
    printf(errno ? " (%s)\n" : "\n", strerror(errno));
                                     ^
die.c:20:38: note: include the header <string.h> or explicitly provide a declaration for 'strerror'
1 error generated.
make: *** [die.o] Error 1
make: *** Waiting for unfinished jobs....
queue.c:129:4: error: implicit declaration of function 'usleep' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
                GIVE_IT_UP;  /* release the rest of our timeslice */
                ^
./mgzip.h:37:20: note: expanded from macro 'GIVE_IT_UP'
#define GIVE_IT_UP usleep(1)
                   ^
queue.c:229:4: error: implicit declaration of function 'usleep' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
                        GIVE_IT_UP;
                        ^
./mgzip.h:37:20: note: expanded from macro 'GIVE_IT_UP'
#define GIVE_IT_UP usleep(1)
                   ^
2 errors generated.

https://build.macports.org/builders/ports-12_x86_64-builder/builds/28627/steps/install-port/logs/stdio

Change History (2)

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

Resolution: fixed
Status: assignedclosed

In d0cfa00da0b3069f2646a54565049e8b7e45c6a9/macports-ports (master):

mgzip: Fix implicit declaration of functions

Closes: #65169

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

Cc: ryandesign added
Note: See TracTickets for help on using tickets.