ObjFW  Check-in [c74cbb9d07]

Overview
Comment:Use -Werror=deprecated for the readdir_r check

Otherwise, we'll just get the deprecation warning and use it anyway,
which then fails during build due to -Werror.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: c74cbb9d079c1b9c9ec7c1643811dfad1facd6627d9f8fcfd3140648daaf3f1f
User & Date: js on 2016-12-25 00:53:54
Other Links: manifest | tags
Context
2017-01-06
23:42
Several minor style fixes check-in: ae340607fd user: js tags: trunk
2016-12-25
00:53
Use -Werror=deprecated for the readdir_r check check-in: c74cbb9d07 user: js tags: trunk
2016-12-21
16:22
Make the readdir_r check an AC_TRY_COMPILE check check-in: 26971c2ea9 user: js tags: trunk
Changes

Modified configure.ac from [e8faf65212] to [a772299926].

846
847
848
849
850
851
852


853
854
855
856
857
858
859
860
861
862
863
864
865
866

867
868
869
870
871
872
873
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876







+
+














+







		AC_DEFINE(OF_HAVE_SYMLINK, 1, [Whether we have symlink()])
	])
	AC_CHECK_FUNC(readlink, [
		AC_DEFINE(OF_HAVE_READLINK, 1, [Whether we have readlink()])
	])
	AC_CHECK_FUNCS([lstat])

	old_OBJCFLAGS="$OBJCFLAGS"
	OBJCFLAGS="$OBJCFLAGS -Werror=deprecated"
	AC_MSG_CHECKING(for readdir_r)
	AC_TRY_COMPILE([
		#include <dirent.h>
	], [
		DIR *dir = 0;
		struct dirent entry, *result;

		readdir_r(dir, &entry, &result);
	], [
		AC_MSG_RESULT(yes)
		AC_DEFINE(HAVE_READDIR_R, 1, [Whether we have readdir_r()])
	], [
		AC_MSG_RESULT(no)
	])
	OBJCFLAGS="$old_OBJCFLAGS"
])

AC_CHECK_FUNCS([sysconf gmtime_r localtime_r nanosleep fcntl])

AC_CHECK_FUNC(pipe, [
	AC_DEFINE(OF_HAVE_PIPE, 1, [Whether we have pipe()])
])