[MacPorts] #71457: flickcurl: builds failing for macOS 11 and later: implicit function declarations: abort, calloc, malloc, free, atoi

MacPorts noreply at macports.org
Wed Dec 4 18:44:14 UTC 2024


#71457: flickcurl: builds failing for macOS 11 and later: implicit function
declarations: abort, calloc, malloc, free, atoi
---------------------+-----------------------
 Reporter:  mascguy  |      Owner:  (none)
     Type:  defect   |     Status:  new
 Priority:  Normal   |  Milestone:
Component:  ports    |    Version:  2.10.5
 Keywords:           |       Port:  flickcurl
---------------------+-----------------------
 We may simply need to patch the source, to include additional headers like
 `stdlib.h`, etc.

 Details:

 {{{
 blog.c:43:5: error: call to undeclared library function 'free' with type
 'void (void *)'; ISO C99 and later do not support implicit function
 declarations [-Wimplicit-function-declaration]
     free(blog->id);
     ^
 blog.c:43:5: note: include the header <stdlib.h> or explicitly provide a
 declaration for 'free'

 blog.c:94:29: error: call to undeclared library function 'calloc' with
 type 'void *(unsigned long, unsigned long)'; ISO C99 and later do not
 support implicit function declarations [-Wimplicit-function-declaration]
   blogs = (flickcurl_blog**)calloc(sizeof(flickcurl_blog*),
 nodes_count+1);
                             ^
 blog.c:94:29: note: include the header <stdlib.h> or explicitly provide a
 declaration for 'calloc'

 blog.c:114:27: error: call to undeclared library function 'malloc' with
 type 'void *(unsigned long)'; ISO C99 and later do not support implicit
 function declarations [-Wimplicit-function-declaration]
       attr_value = (char*)malloc(attr_len + 1);
                           ^
 blog.c:114:27: note: include the header <stdlib.h> or explicitly provide a
 declaration for 'malloc'

 blog.c:122:29: error: call to undeclared function 'atoi'; ISO C99 and
 later do not support implicit function declarations [-Wimplicit-function-
 declaration]
         b->needs_password = atoi(attr_value);
                             ^
 4 errors generated.
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/71457>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list