f21993
commit 36f6e408845c8c539128f3fb9cb132bf1845a2c8
f21993
Author: Florian Weimer <fweimer@redhat.com>
f21993
Date:   Tue Mar 9 21:07:24 2021 +0100
f21993
f21993
    <shlib-compat.h>: Support compat_symbol_reference for _ISOMAC
f21993
    
f21993
    This is helpful for testing compat symbols in cases where _ISOMAC
f21993
    is activated implicitly due to -DMODULE_NAME=testsuite and cannot
f21993
    be disabled easily.
f21993
f21993
diff --git a/include/libc-symbols.h b/include/libc-symbols.h
f21993
index 41436050d060b89f..44e12b63d40cc572 100644
f21993
--- a/include/libc-symbols.h
f21993
+++ b/include/libc-symbols.h
f21993
@@ -59,6 +59,19 @@
f21993
 # define IN_MODULE (-1)
f21993
 #endif
f21993
 
f21993
+/* Use symbol_version_reference to specify the version a symbol
f21993
+   reference should link to.  Use symbol_version or
f21993
+   default_symbol_version for the definition of a versioned symbol.
f21993
+   The difference is that the latter is a no-op in non-shared
f21993
+   builds.  */
f21993
+#ifdef __ASSEMBLER__
f21993
+# define symbol_version_reference(real, name, version) \
f21993
+     .symver real, name##@##version
f21993
+#else  /* !__ASSEMBLER__ */
f21993
+# define symbol_version_reference(real, name, version) \
f21993
+  __asm__ (".symver " #real "," #name "@" #version)
f21993
+#endif
f21993
+
f21993
 #ifndef _ISOMAC
f21993
 
f21993
 /* This is defined for the compilation of all C library code.  features.h
f21993
@@ -388,19 +401,6 @@ for linking")
f21993
    past the last element in SET.  */
f21993
 #define symbol_set_end_p(set, ptr) ((ptr) >= (void *const *) &__stop_##set)
f21993
 
f21993
-/* Use symbol_version_reference to specify the version a symbol
f21993
-   reference should link to.  Use symbol_version or
f21993
-   default_symbol_version for the definition of a versioned symbol.
f21993
-   The difference is that the latter is a no-op in non-shared
f21993
-   builds.  */
f21993
-#ifdef __ASSEMBLER__
f21993
-# define symbol_version_reference(real, name, version) \
f21993
-     .symver real, name##@##version
f21993
-#else  /* !__ASSEMBLER__ */
f21993
-# define symbol_version_reference(real, name, version) \
f21993
-  __asm__ (".symver " #real "," #name "@" #version)
f21993
-#endif
f21993
-
f21993
 #ifdef SHARED
f21993
 # define symbol_version(real, name, version) \
f21993
   symbol_version_reference(real, name, version)