summaryrefslogtreecommitdiff
path: root/string
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2014-11-14 13:48:39 +0000
committerJoseph Myers <joseph@codesourcery.com>2014-11-14 13:48:39 +0000
commitc1b0aadcdfd1b4b56588856cdc3197f4f145677d (patch)
treec40216176f216cce95e072cedc8a34bc7b705be9 /string
parentbf438382bd8ffcc614b01e9a273a577b3ed54f9f (diff)
downloadglibc-c1b0aadcdfd1b4b56588856cdc3197f4f145677d.tar.gz
Fix build of C mempcpy and stpcpy.
This patch fixes the build of C mempcpy and stpcpy by disabling the redirection to __mempcpy and __stpcpy asm names if NO_MEMPCPY_STPCPY_REDIRECT is defined, and defining that macro in the relevant source files. Tested for powerpc32 that the build is fixed. * include/string.h [NO_MEMPCPY_STPCPY_REDIRECT] (mempcpy): Do not redeclare with asm name. [NO_MEMPCPY_STPCPY_REDIRECT] (stpcpy): Likewise. * string/mempcpy.c (NO_MEMPCPY_STPCPY_REDIRECT): Define before including <string.h>. * string/stpcpy.c (NO_MEMPCPY_STPCPY_REDIRECT): Likewise. * sysdeps/powerpc/powerpc32/power4/multiarch/mempcpy.c [!NOT_IN_libc] (NO_MEMPCPY_STPCPY_REDIRECT): Likewise. * sysdeps/powerpc/powerpc64/multiarch/mempcpy.c [!NOT_IN_libc] (NO_MEMPCPY_STPCPY_REDIRECT): Likewise. * sysdeps/powerpc/powerpc64/multiarch/stpcpy.c [SHARED && !NOT_IN_libc] (NO_MEMPCPY_STPCPY_REDIRECT): Likewise.
Diffstat (limited to 'string')
-rw-r--r--string/mempcpy.c1
-rw-r--r--string/stpcpy.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/string/mempcpy.c b/string/mempcpy.c
index 9749863eaf..aab1bed986 100644
--- a/string/mempcpy.c
+++ b/string/mempcpy.c
@@ -19,6 +19,7 @@
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
+#define NO_MEMPCPY_STPCPY_REDIRECT
#include <string.h>
#undef mempcpy
diff --git a/string/stpcpy.c b/string/stpcpy.c
index fc5ae5534f..9185acc034 100644
--- a/string/stpcpy.c
+++ b/string/stpcpy.c
@@ -19,6 +19,7 @@
# include <config.h>
#endif
+#define NO_MEMPCPY_STPCPY_REDIRECT
#include <string.h>
#undef __stpcpy