From a7f6219f5a7e6f1edc6ba4380676d7a379fe0604 Mon Sep 17 00:00:00 2001 From: John Dennis Date: Mon, 25 May 2015 11:07:03 -0400 Subject: [PATCH] Eliminate _BSD_SOURCE and _SVID_SOURCE deprecation warning Because all warnings are treated as errors and this warning is emitted: warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" the build fails. The fix is to define _DEFAULT_SOURCE in lasso/xml/tools.c The effect of defining the _DEFAULT_SOURCE macro is equivalent to the effect of explicitly defining three macros in earlier glibc versions: -D_BSD_SOURCE -D_SVID_SOURCE -D_POSIX_C_SOURCE=200809C Signed-off-by: John Dennis License: MIT --- lasso/xml/tools.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lasso/xml/tools.c b/lasso/xml/tools.c index ba707d4a..8c9b21eb 100644 --- a/lasso/xml/tools.c +++ b/lasso/xml/tools.c @@ -21,6 +21,12 @@ * along with this program; if not, see . */ +/* + * The effect of defining the _DEFAULT_SOURCE macro is equivalent to + * the effect of explicitly defining three macros in earlier glibc + * versions: -D_BSD_SOURCE -D_SVID_SOURCE -D_POSIX_C_SOURCE=200809C + */ +#define _DEFAULT_SOURCE /* permit importation of strptime for glibc2 */ #define _XOPEN_SOURCE /* permit importation of timegm for glibc2, wait for people to complain it does not work on their