[MacPorts] #61670: netpipes: error: implicitly declaring library function 'strcmp'

MacPorts noreply at macports.org
Wed Dec 2 13:12:32 UTC 2020


#61670: netpipes: error: implicitly declaring library function 'strcmp'
--------------------------+-----------------------------
  Reporter:  alex1platon  |      Owner:  (none)
      Type:  defect       |     Status:  new
  Priority:  Normal       |  Milestone:
 Component:  ports        |    Version:  2.6.4
Resolution:               |   Keywords:  bigsur catalina
      Port:  netpipes     |
--------------------------+-----------------------------

Comment (by pessaux-f):

 The same occurs for enscript. I do not open a duplicate ticket I guess.


 {{{
 :info:build make[2]: Entering directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_print_enscript/enscript/work/enscript-1.6.6/compat'
 :info:build /usr/bin/clang -DHAVE_CONFIG_H -I. -I.. -I./../intl -I../intl
 -I/opt/local/include
 -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
 -pipe -Os
 -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
 -arch x86_64 -c getopt.c
 :info:build getopt.c:527:30: error: implicitly declaring library function
 'strcmp' with type 'int (const char *, const char *)' [-Werror,-Wimplicit-
 function-declaration]
 :info:build       if (optind != argc && !strcmp (argv[optind], "--"))
 :info:build                              ^
 :info:build getopt.c:527:30: note: include the header <string.h> or
 explicitly provide a declaration for 'strcmp'
 :info:build getopt.c:603:7: error: implicitly declaring library function
 'strncmp' with type 'int (const char *, const char *, unsigned long)'
 [-Werror,-Wimplicit-function-declaration]
 :info:build         if (!strncmp (p->name, nextchar, nameend - nextchar))
 :info:build              ^
 :info:build getopt.c:603:7: note: include the header <string.h> or
 explicitly provide a declaration for 'strncmp'
 :info:build getopt.c:606:21: error: implicitly declaring library function
 'strlen' with type 'unsigned long (const char *)' [-Werror,-Wimplicit-
 function-declaration]
 :info:build                 == (unsigned int) strlen (p->name))
 :info:build                                   ^
 :info:build getopt.c:606:21: note: include the header <string.h> or
 explicitly provide a declaration for 'strlen'
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/61670#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list