summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2013-01-28 18:49:01 +0200
committerPanu Matilainen <pmatilai@redhat.com>2013-01-29 08:15:03 +0200
commitfd5e1c5e1919bb741bdede0e6e24ebc0e87f8297 (patch)
treef77c91406b2664af5ec536d3843b22b105a2b28c
parent4c41373547becfd03beba8c449dee7d7d2e67870 (diff)
downloadlibrpm-tizen-fd5e1c5e1919bb741bdede0e6e24ebc0e87f8297.tar.gz
librpm-tizen-fd5e1c5e1919bb741bdede0e6e24ebc0e87f8297.tar.bz2
librpm-tizen-fd5e1c5e1919bb741bdede0e6e24ebc0e87f8297.zip
Acommodate to glibc 2.17 __secure_getenv() renaming
- glibc 2.17 renames __secure_getenv() to secure_getenv() so now we need to test for both. Meh. (cherry picked from commit 49519f2564777fdcfb801088fb3025b3d6f5783a)
-rw-r--r--configure.ac2
-rw-r--r--system.h4
2 files changed, 4 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 6b2f5fe70..8161dc266 100644
--- a/configure.ac
+++ b/configure.ac
@@ -521,7 +521,7 @@ AC_CHECK_FUNCS(fdatasync)
AC_REPLACE_FUNCS(stpcpy stpncpy)
-AC_CHECK_FUNCS(__secure_getenv)
+AC_CHECK_FUNCS([secure_getenv __secure_getenv])
AC_CHECK_FUNCS(
[mkstemp getcwd basename dirname realpath setenv unsetenv regcomp lchown],
diff --git a/system.h b/system.h
index 6f0b76b67..f3b1bab32 100644
--- a/system.h
+++ b/system.h
@@ -35,7 +35,9 @@ char * stpcpy(char * dest, const char * src);
char * stpncpy(char * dest, const char * src, size_t n);
#endif
-#if HAVE___SECURE_GETENV
+#if HAVE_SECURE_GETENV
+#define getenv(_s) secure_getenv(_s)
+#elif HAVE___SECURE_GETENV
#define getenv(_s) __secure_getenv(_s)
#endif