When compiling this error happens:
> Making all in src > make[2]: Entering directory `/opt/local/var/macports/build/nue.de.rsync.macports.org_macports_release_tarballs_ports_devel_gpgme/gpgme/work/gpgme-1.24.1/src' > /opt/local/bin/gcc-mp-14 -DHAVE_CONFIG_H -I. -I../conf -I/opt/local/include -I/opt/local/include -I/opt/local/include -pipe -Os -arch ppc -Wall -Wcast-align -Wshadow -Wstrict-prototypes -Wno-format-y2k -Wno-missing-field-initializers -Wno-sign-compare -Wno-format-zero-length -Wno-format-truncation -Wno-sizeof-pointer-div -MT gpgme-tool.o -MD -MP -MF .deps/gpgme-tool.Tpo -c -o gpgme-tool.o gpgme-tool.c > gpgme-tool.c: In function 'gt_protocol_from_name': > gpgme-tool.c:1325:9: error: implicit declaration of function 'strcasecmp' [-Wimplicit-function-declaration] > 1325 | if (! strcasecmp (name, gpgme_get_protocol_name (GPGME_PROTOCOL_OpenPGP))) > | ^~~~~~~~~~ > gpgme-tool.c: In function 'server_parse_fd': > gpgme-tool.c:1865:9: error: implicit declaration of function 'strncasecmp' [-Wimplicit-function-declaration] > 1865 | if (! strncasecmp (line, "file=", 5)) > | ^~~~~~~~~~~ > gpgme-tool.c:1865:37: warning: 'strncasecmp' argument 3 type is 'int' where 'long unsigned int' is expected in a call to built-in function declared without prototype [-Wbuiltin-declaration-mismatch] > 1865 | if (! strncasecmp (line, "file=", 5)) > | ^ > <built-in>: note: built-in 'strncasecmp' declared here > make[2]: *** [gpgme-tool.o] Error 1
The two functions are declared in:
/usr/include/string.h: 102 #ifndef _POSIX_C_SOURCE 103 char *strnstr(const char *, const char *, size_t); 104 #endif /* !_POSIX_C_SOURCE */ 105 char *strpbrk(const char *, const char *); 106 char *strrchr(const char *, int); 107 size_t strspn(const char *, const char *); 108 char *strstr(const char *, const char *); 109 char *strtok(char *, const char *); 110 size_t strxfrm(char *, const char *, size_t); 111 112 /* Nonstandard routines */ 113 #ifndef _ANSI_SOURCE 114 void *memccpy(void *, const void *, int, size_t); 115 char *strtok_r(char *, const char *, char **); 116 char *strdup(const char *); 117 #ifndef _POSIX_C_SOURCE 118 int bcmp(const void *, const void *, size_t); 119 void bcopy(const void *, void *, size_t); 120 void bzero(void *, size_t); 121 int ffs(int); 122 char *index(const char *, int); 123 char *rindex(const char *, int); 124 int strcasecmp(const char *, const char *); 125 size_t strlcat(char *, const char *, size_t); 126 size_t strlcpy(char *, const char *, size_t); 127 void strmode(int, char *); 128 int strncasecmp(const char *, const char *, size_t); 129 char *strsep(char **, const char *); 130 char *strsignal(int sig); 131 void swab(const void * __restrict, void * __restrict, ssize_t); 132 #endif /* !_POSIX_C_SOURCE */ 133 #endif /* !_ANSI_SOURCE */ /usr/include/strings.h: 58 #if !defined(_XOPEN_SOURCE) && !defined(_POSIX_C_SOURCE) 59 60 #include <string.h> 61 62 #else 63 64 #include <_types.h> 65 66 #ifndef _SIZE_T 67 #define _SIZE_T 68 typedef __darwin_size_t size_t; 69 #endif 70 71 int bcmp(const void *, const void *, size_t); 72 void bcopy(const void *, void *, size_t); 73 void bzero(void *, size_t); 74 int ffs(int); 75 char *index(const char *, int); 76 char *rindex(const char *, int); 77 int strcasecmp(const char *, const char *); 78 int strncasecmp(const char *, const char *, size_t); 79 80 #endif /* _POSIX_C_SOURCE */
When substituting #include <string.h> with #include <strings.h> memcpy() is not found.
Mac OS X 10.4.11 is darwin 8.11.0.