Fix gcc compile error: redundant redeclaration of ‘environ’ [-Werror=redundant-decls]

Cherry picked from dbus/dbus!227
This commit is contained in:
Ralf Habacker 2021-11-30 10:14:05 +01:00
parent 05cc895444
commit e8b34b419e

View file

@ -545,6 +545,11 @@ set(DBUS_DAEMON_NAME "dbus-daemon" CACHE STRING "The name of the dbus daemon exe
#include(ConfigureChecks.cmake)
# only defined but expected as boolean
if(DEFINED HAVE_DECL_ENVIRON)
set(HAVE_DECL_ENVIRON 1)
endif()
# compiler definitions
add_definitions(-DHAVE_CONFIG_H)
add_definitions(${DBUS_BUS_CFLAGS})