diff --git a/headers/build/BeOSBuildCompatibility.h b/headers/build/BeOSBuildCompatibility.h index 6a84253644..7dda8b56e2 100644 --- a/headers/build/BeOSBuildCompatibility.h +++ b/headers/build/BeOSBuildCompatibility.h @@ -16,6 +16,10 @@ extern "C" { extern size_t strlcpy(char *dest, const char *source, size_t length); extern size_t strlcat(char *dest, const char *source, size_t length); +#ifdef HAIKU_HOST_PLATFORM_FREEBSD +extern size_t strnlen(const char *string, size_t length); +#endif + // BeOS only extern ssize_t read_pos(int fd, off_t pos, void *buffer, size_t count); extern ssize_t write_pos(int fd, off_t pos, const void *buffer,size_t count); diff --git a/src/build/libroot/Jamfile b/src/build/libroot/Jamfile index addee044ca..f1df1e9b14 100644 --- a/src/build/libroot/Jamfile +++ b/src/build/libroot/Jamfile @@ -32,10 +32,11 @@ BuildPlatformSharedLibrary libroot_build.so : strlcpy.c strlcat.c + strnlen.c : $(HOST_LIBSTDC++) ; -SEARCH on [ FGristFiles strlcat.c strlcpy.c ] +SEARCH on [ FGristFiles strlcat.c strlcpy.c strnlen.c ] = [ FDirName $(HAIKU_TOP) src system libroot posix string ] ;