mirror of
https://gitlab.freedesktop.org/dbus/dbus.git
synced 2026-02-03 10:10:31 +01:00
add missing HAVE_ macros to cmake
This commit is contained in:
parent
48801c87df
commit
9e034bd5b3
2 changed files with 27 additions and 3 deletions
|
|
@ -24,11 +24,16 @@ check_symbol_exists(getpeerucred "ucred.h" HAVE_GETPEERUCRED) #
|
|||
check_symbol_exists(nanosleep "time.h" HAVE_NANOSLEEP) # dbus-sysdeps.c
|
||||
check_symbol_exists(getpwnam_r "errno.h pwd.h" HAVE_POSIX_GETPWNAM_R) # dbus-sysdeps-util-unix.c
|
||||
check_symbol_exists(setenv "stdlib.h" HAVE_SETENV) # dbus-sysdeps.c
|
||||
check_symbol_exists(socketpair "sys/socket.h" HAVE_SOCKETPAIR) # dbus-sysdeps.c
|
||||
check_symbol_exists(unsetenv "stdlib.h" HAVE_UNSETENV) # dbus-sysdeps.c
|
||||
check_symbol_exists(clearenv "stdlib.h" HAVE_CLEARENV) # dbus-sysdeps.c
|
||||
check_symbol_exists(writev "sys/uio.h" HAVE_WRITEV) # dbus-sysdeps.c, dbus-sysdeps-win.c
|
||||
check_symbol_exists(setrlimit "sys/resource.h" HAVE_SETRLIMIT) # dbus-sysdeps.c, dbus-sysdeps-win.c, test/test-segfault.c
|
||||
check_symbol_exists(socketpair "sys/socket.h" HAVE_SOCKETPAIR) # dbus-sysdeps.c
|
||||
check_symbol_exists(socklen_t "sys/socket.h" HAVE_SOCKLEN_T) # dbus-sysdeps-unix.c
|
||||
check_symbol_exists(setlocale "locale.h" HAVE_SETLOCALE) # dbus-test-main.c
|
||||
check_symbol_exists(localeconv "locale.h" HAVE_LOCALECONV) # dbus-sysdeps.c
|
||||
check_symbol_exists(strtoll "stdlib.h" HAVE_STRTOLL) # dbus-send.c
|
||||
check_symbol_exists(strtoull "stdlib.h" HAVE_STRTOULL) # dbus-send.c
|
||||
|
||||
check_struct_member(cmsgcred cmcred_pid "sys/types.h sys/socket.h" HAVE_CMSGCRED) # dbus-sysdeps.c
|
||||
|
||||
|
|
|
|||
|
|
@ -163,12 +163,27 @@
|
|||
/* Define to 1 if you have unsetenv */
|
||||
#cmakedefine HAVE_UNSETENV 1
|
||||
|
||||
/* Define to 1 if you have clearenv */
|
||||
#cmakedefine HAVE_CLEARENV 1
|
||||
|
||||
/* Define to 1 if you have writev */
|
||||
#cmakedefine HAVE_WRITEV 1
|
||||
|
||||
/* Define to 1 if you have socklen_t */
|
||||
#cmakedefine HAVE_SOCKLEN_T 1
|
||||
|
||||
/* Define to 1 if you have setlocale */
|
||||
#cmakedefine HAVE_SETLOCALE 1
|
||||
|
||||
/* Define to 1 if you have localeconv */
|
||||
#cmakedefine HAVE_LOCALECONV 1
|
||||
|
||||
/* Define to 1 if you have strtoll */
|
||||
#cmakedefine HAVE_STRTOLL 1
|
||||
|
||||
/* Define to 1 if you have strtoull */
|
||||
#cmakedefine HAVE_STRTOULL 1
|
||||
|
||||
// structs
|
||||
/* Define to 1 if you have struct cmsgred */
|
||||
#cmakedefine HAVE_CMSGCRED 1
|
||||
|
|
@ -196,9 +211,13 @@
|
|||
# define gid_t int
|
||||
# else
|
||||
# define snprintf _snprintf
|
||||
# define strtoll _strtoi64
|
||||
# define strtoull _strtoui64
|
||||
typedef int mode_t;
|
||||
# if !defined(_WIN32_WCE)
|
||||
# define strtoll _strtoi64
|
||||
# define strtoull _strtoui64
|
||||
# define HAVE_STRTOLL 1
|
||||
# define HAVE_STRTOULL 1
|
||||
# endif
|
||||
# endif
|
||||
#endif // defined(_WIN32) || defined(_WIN64)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue