]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
alpha: Fix static gettimeofday symbol
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Thu, 13 Feb 2020 11:27:27 +0000 (08:27 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Thu, 13 Feb 2020 11:27:27 +0000 (08:27 -0300)
By undef strong_alias on alpha implementation, the
default_symbol_version macro becomes an empty macro on static build.
It fixes the issue introduced at c953219420.

Checked on alpha-linux-gnu with a 'make check run-built-tests=no'.

sysdeps/unix/sysv/linux/alpha/gettimeofday.c
time/gettimeofday.c

index 7ad3c6a4120d9e06598d238e9ca9efcebd9a802c..25e86410fd69634b26233b8a6d43f85615fb68f7 100644 (file)
 
 /* We can use the generic implementation, but we have to override its
    default symbol version.  */
-#undef weak_alias
-#define weak_alias(a,b)
-#undef strong_alias
-#define strong_alias(a, b)
+#define SET_VERSION
 #include <time/gettimeofday.c>
 
-_weak_alias (___gettimeofday, __wgettimeofday);
+weak_alias (___gettimeofday, __wgettimeofday);
 default_symbol_version (___gettimeofday, __gettimeofday, GLIBC_2.1);
 default_symbol_version (__wgettimeofday,   gettimeofday, GLIBC_2.1);
index 07c6e10d12d76e20e160c262505c1af1407a25af..e4671edd13b554153011df3401bd3162b124c78c 100644 (file)
@@ -35,6 +35,8 @@ ___gettimeofday (struct timeval *restrict tv, void *restrict tz)
   TIMESPEC_TO_TIMEVAL (tv, &ts);
   return 0;
 }
-
+/* Define to override default symbol version.  */
+#ifndef SET_VERSION
 strong_alias (___gettimeofday, __gettimeofday)
 weak_alias (___gettimeofday, gettimeofday)
+#endif