cc -pthread -Wall -Wextra -Werror -Wno-error=deprecated -Wno-error=deprecated-declarations pthread/pthread_barrier_init.c -o pthread/pthread_barrier_init -D_POSIX_C_SOURCE=202405L -lm -lpthread -liconv pthread/pthread_barrier_init.c:5:12: error: unknown type name 'pthread_barrier_t'; did you mean 'pthread_attr_t'? int (*foo)(pthread_barrier_t *restrict, const pthread_barrierattr_t *restrict, unsigned) = pthread_barrier_init; ^~~~~~~~~~~~~~~~~ pthread_attr_t /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_attr_t.h:31:33: note: 'pthread_attr_t' declared here typedef __darwin_pthread_attr_t pthread_attr_t; ^ pthread/pthread_barrier_init.c:5:47: error: unknown type name 'pthread_barrierattr_t'; did you mean 'pthread_mutexattr_t'? int (*foo)(pthread_barrier_t *restrict, const pthread_barrierattr_t *restrict, unsigned) = pthread_barrier_init; ^~~~~~~~~~~~~~~~~~~~~ pthread_mutexattr_t /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_pthread/_pthread_mutexattr_t.h:31:38: note: 'pthread_mutexattr_t' declared here typedef __darwin_pthread_mutexattr_t pthread_mutexattr_t; ^ pthread/pthread_barrier_init.c:5:92: error: use of undeclared identifier 'pthread_barrier_init'; did you mean 'pthread_attr_init'? int (*foo)(pthread_barrier_t *restrict, const pthread_barrierattr_t *restrict, unsigned) = pthread_barrier_init; ^~~~~~~~~~~~~~~~~~~~ pthread_attr_init /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/pthread.h:263:5: note: 'pthread_attr_init' declared here int pthread_attr_init(pthread_attr_t *); ^ pthread/pthread_barrier_init.c:5:7: error: incompatible function pointer types initializing 'int (*)(pthread_attr_t *restrict, const pthread_mutexattr_t *restrict, unsigned int)' (aka 'int (*)(struct _opaque_pthread_attr_t *restrict, const struct _opaque_pthread_mutexattr_t *restrict, unsigned int)') with an expression of type 'int (pthread_attr_t * _Nonnull)' (aka 'int (struct _opaque_pthread_attr_t * _Nonnull)') [-Werror,-Wincompatible-function-pointer-types] int (*foo)(pthread_barrier_t *restrict, const pthread_barrierattr_t *restrict, unsigned) = pthread_barrier_init; ^ ~~~~~~~~~~~~~~~~~~~~ 4 errors generated.