mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-14 17:24:01 +00:00
ICU-10123 add check for elf.h before using (note, had to add U_HAVE_ELF_H)
X-SVN-Rev: 34154
This commit is contained in:
parent
45a374dc3f
commit
cfa973f062
4 changed files with 24 additions and 3 deletions
16
icu4c/source/configure
vendored
16
icu4c/source/configure
vendored
|
@ -5420,6 +5420,22 @@ fi
|
|||
$as_echo "$enabled" >&6; }
|
||||
|
||||
|
||||
# check if elf.h is present.
|
||||
for ac_header in elf.h
|
||||
do :
|
||||
ac_fn_c_check_header_mongrel "$LINENO" "elf.h" "ac_cv_header_elf_h" "$ac_includes_default"
|
||||
if test "x$ac_cv_header_elf_h" = xyes; then :
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define HAVE_ELF_H 1
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
done
|
||||
|
||||
if test "x$ac_cv_header_elf_h" = "xyes"; then
|
||||
CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_HAVE_ELF_H=1";
|
||||
fi
|
||||
|
||||
U_ENABLE_DYLOAD=1
|
||||
enable=yes
|
||||
|
|
|
@ -398,6 +398,11 @@ AC_ARG_ENABLE(tracing,
|
|||
AC_MSG_RESULT($enabled)
|
||||
AC_SUBST(U_ENABLE_TRACING)
|
||||
|
||||
# check if elf.h is present.
|
||||
AC_CHECK_HEADERS([elf.h])
|
||||
if test "x$ac_cv_header_elf_h" = "xyes"; then
|
||||
CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_HAVE_ELF_H=1";
|
||||
fi
|
||||
|
||||
U_ENABLE_DYLOAD=1
|
||||
enable=yes
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
*******************************************************************************
|
||||
* Copyright (C) 1999-2011, International Business Machines
|
||||
* Copyright (C) 1999-2013, International Business Machines
|
||||
* Corporation and others. All Rights Reserved.
|
||||
*******************************************************************************
|
||||
* file name: gennames.c
|
||||
|
@ -30,7 +30,7 @@
|
|||
#include <time.h>
|
||||
#endif
|
||||
|
||||
#if U_PLATFORM_IS_LINUX_BASED
|
||||
#if U_PLATFORM_IS_LINUX_BASED && U_HAVE_ELF_H
|
||||
# define U_ELF
|
||||
#endif
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
# endif
|
||||
#endif
|
||||
|
||||
#if U_PLATFORM_IS_LINUX_BASED
|
||||
#if U_PLATFORM_IS_LINUX_BASED && U_HAVE_ELF_H
|
||||
# define U_ELF
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue