]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Fix arm build by only using _itoa when building ld-linux, and not 'sln'. Also disable...
authorPaul Pluzhnikov <ppluzhnikov@google.com>
Mon, 24 Nov 2014 02:12:56 +0000 (18:12 -0800)
committerPaul Pluzhnikov <ppluzhnikov@google.com>
Mon, 24 Nov 2014 02:12:56 +0000 (18:12 -0800)
dlfcn/dlopen.c
elf/dl-load.c

index 319ae6ef2eafb005b2e0496bdcbdb1be4de76954..c35a9eb66b2969d89fc29ebc058d96ade00f4036 100644 (file)
@@ -33,13 +33,6 @@ dlopen (const char *file, int mode)
 static_link_warning (dlopen)
 #endif
 
-void *
-dlopen_with_offset (const char *file, off_t offset, int mode)
-{
-  return __dlopen_with_offset (file, offset, mode, RETURN_ADDRESS (0));
-}
-static_link_warning (dlopen_with_offset)
-
 #else
 
 struct dlopen_args
@@ -97,23 +90,13 @@ __dlopen_common (struct dlopen_args *args)
 # endif
 }
 
+# ifdef SHARED
 void *
 __dlopen_with_offset (const char *file, off_t offset, int mode DL_CALLER_DECL)
 {
-# ifdef SHARED
   if (!rtld_active ())
     return _dlfcn_hook->dlopen_with_offset (file, offset, mode, DL_CALLER);
-# endif
-
-  struct dlopen_args oargs;
-  oargs.file = file;
-  oargs.offset = offset;
-  oargs.mode = mode;
-  oargs.caller = DL_CALLER;
-
-  return __dlopen_common (&oargs);
 }
-# ifdef SHARED
 strong_alias (__dlopen_with_offset, __google_dlopen_with_offset)
 # endif
 
index b6c4aa8da025368844094a8d5dfaf1598181a683..3aa581692d93ac16ee8304615a94c052d0c9ecee 100644 (file)
@@ -948,6 +948,9 @@ _dl_map_object_from_fd (const char *name, const char *origname, int fd, off_t of
   else
     assert (r->r_state == RT_ADD);
 
+#ifdef SHARED
+  // This code could be linked into 'sln', which does not have _itoa.
+  // We only care about this when this is linked into ld-linux.
   if (offset != 0)
     {
       /* Google-specific: to help GDB, and for b/18243822, turn realname
@@ -964,6 +967,7 @@ _dl_map_object_from_fd (const char *name, const char *origname, int fd, off_t of
       tmp[19] = '\0';
       strcat(realname, _itoa(offset, &tmp[18], 16, 0));
     }
+#endif
 
   /* Enter the new object in the list of loaded objects.  */
   l = _dl_new_object (realname, (offset ? realname : name), l_type, loader, mode, nsid);