mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-27 13:53:31 +01:00
Fix compilation errors for FreeBSD
Signed-off-by: David Goulet <dgoulet@torproject.org>
This commit is contained in:
parent
554d840742
commit
c3bc04e355
3
changes/ticket40825
Normal file
3
changes/ticket40825
Normal file
@ -0,0 +1,3 @@
|
||||
o Minor bugfix (FreeBSD, compilation):
|
||||
- Fix compilation issue on FreeBSD by properly importing sys/param.h. Fixes
|
||||
bug 40825; bugfix on 0.4.8.1-alpha.
|
@ -26,6 +26,10 @@
|
||||
#define STR_IMPL(x) #x
|
||||
#define STR(x) STR_IMPL(x)
|
||||
|
||||
#if defined(__BSD_VISIBLE) || defined(__NETBSD_SOURCE)
|
||||
#include <sys/param.h>
|
||||
#endif /* defined(__BSD_VISIBLE) || defined(__NETBSD_SOURCE) */
|
||||
|
||||
/** Return the name of the compile time libc. Returns NULL if we
|
||||
* cannot identify the libc. */
|
||||
const char *
|
||||
@ -46,8 +50,6 @@ tor_libc_get_name(void)
|
||||
const char *
|
||||
tor_libc_get_version_str(void)
|
||||
{
|
||||
#if defined(__BSD_VISIBLE) || defined(__NETBSD_SOURCE)
|
||||
#include <sys/param.h>
|
||||
#ifdef __DragonFly_version
|
||||
return STR(__DragonFly_version);
|
||||
#endif
|
||||
@ -60,7 +62,6 @@ tor_libc_get_version_str(void)
|
||||
#ifdef OpenBSD
|
||||
return STR(OpenBSD);
|
||||
#endif
|
||||
#endif /* defined(__BSD_VISIBLE) || defined(__NETBSD_SOURCE) */
|
||||
#ifdef CHECK_LIBC_VERSION
|
||||
const char *version = gnu_get_libc_version();
|
||||
if (version == NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user