20 #ifndef __PORT_HACKS_H
21 #define __PORT_HACKS_H
24 #define ETIME ETIMEDOUT
27 #include <sys/types.h>
30 #if __FreeBSD__ || __FreeBSD_kernel__
31 # include <sys/syslimits.h>
37 # ifdef THREADING_SUPPORT
38 static inline int pthread_tryjoin_np ( pthread_t thread,
void **retval )
40 struct timespec abstime;
44 extern int pthread_timedjoin_np ( pthread_t thread,
void **value_ptr,
const struct timespec * abstime );
45 rc = pthread_timedjoin_np ( thread, retval, &abstime );
47 if ( rc == ETIMEDOUT )
54 # ifndef __USE_LARGEFILE64
56 static inline int lstat64 (
const char *pathname,
struct stat *buf )
58 return lstat ( pathname, buf );
70 # warning O_PATH is not set
75 #endif // __PORT_HACKS_H