mirror of
https://gitlab.freedesktop.org/libbsd/libbsd.git
synced 2025-01-24 02:51:43 +01:00
Conditionalize temporary compatibility inclusions
These inclusions were in place for backward compatibility purposes, when the headers were split so that code using them would not break. Make it possible for applications to disable them by defining LIBBSD_CLEAN_INCLUDES so that buildability can be tested and fixed before they get removed in a subsequent release.
This commit is contained in:
parent
c594192bac
commit
8b6a74775b
4
Makefile
4
Makefile
@ -125,7 +125,9 @@ CFLAGS ?= -g -Wall -Wextra -Wno-unused-variable
|
||||
LDFLAGS ?=
|
||||
|
||||
# Internal makefile variables
|
||||
MK_CPPFLAGS := -Iinclude/bsd/ -Iinclude/ -DLIBBSD_TRANSPARENT -D_GNU_SOURCE -D__REENTRANT
|
||||
MK_CPPFLAGS := -Iinclude/bsd/ -Iinclude/ \
|
||||
-DLIBBSD_TRANSPARENT -DLIBBSD_CLEAN_INCLUDES \
|
||||
-D_GNU_SOURCE -D__REENTRANT
|
||||
MK_CFLAGS :=
|
||||
MK_LDFLAGS :=
|
||||
|
||||
|
@ -47,8 +47,10 @@
|
||||
#endif
|
||||
|
||||
/* FIXME: Temporary inclusions to avoid API breakage, will be removed soon. */
|
||||
#ifndef LIBBSD_CLEAN_INCLUDES
|
||||
#include <bsd/stdio.h>
|
||||
#include <bsd/unistd.h>
|
||||
#endif
|
||||
|
||||
__BEGIN_DECLS
|
||||
u_int32_t arc4random();
|
||||
|
@ -36,8 +36,10 @@
|
||||
#include <string.h>
|
||||
#endif
|
||||
|
||||
#ifndef LIBBSD_CLEAN_INCLUDES
|
||||
/* FIXME: Temporary inclusion to avoid API breakage, will be removed soon. */
|
||||
#include <bsd/stdio.h>
|
||||
#endif
|
||||
|
||||
__BEGIN_DECLS
|
||||
size_t strlcpy(char *dst, const char *src, size_t siz);
|
||||
|
Loading…
x
Reference in New Issue
Block a user