This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.21-527-geea3dc5


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  eea3dc5bf2813b77ee9819d1b9ec893140db1491 (commit)
      from  6f874bd4d4063cacd9edd7f7607fb929f0db218f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=eea3dc5bf2813b77ee9819d1b9ec893140db1491

commit eea3dc5bf2813b77ee9819d1b9ec893140db1491
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jun 24 03:21:29 2015 -0700

    Don't issue errors on GDB Python files
    
    Many packages, including GCC, install Python files for GDB in library
    diretory. ldconfig reads them and issue errors since they aren't ELF
    files:
    
    ldconfig: /usr/gcc-5.1.1/lib/libstdc++.so.6.0.21-gdb.py is not an ELF file - it has the wrong magic bytes at the start.
    
    ldconfig: /usr/gcc-5.1.1/libx32/libstdc++.so.6.0.21-gdb.py is not an ELF file - it has the wrong magic bytes at the start.
    
    ldconfig: /usr/gcc-5.1.1/lib64/libstdc++.so.6.0.21-gdb.py is not an ELF file - it has the wrong magic bytes at the start.
    
    This patch silences ldconfig on GDB Python files by checking filenames
    with -gdb.py suffix.
    
    	[BZ #18585]
    	* elf/readlib.c (is_gdb_python_file): New.
    	(process_file): Don't issue errors on filenames with -gdb.py
    	suffix.

diff --git a/ChangeLog b/ChangeLog
index aca044b..8cde91e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2015-06-24  H.J. Lu  <hongjiu.lu@intel.com>
+
+	[BZ #18585]
+	* elf/readlib.c (is_gdb_python_file): New.
+	(process_file): Don't issue errors on filenames with -gdb.py
+	suffix.
+
 2015-06-24  Joseph Myers  <joseph@codesourcery.com>
 
 	* math/auto-libm-test-in: Add more tests of csin and csinh.
diff --git a/NEWS b/NEWS
index 4646dcd..9fb0060 100644
--- a/NEWS
+++ b/NEWS
@@ -24,7 +24,7 @@ Version 2.22
   18444, 18468, 18469, 18470, 18479, 18483, 18495, 18496, 18497, 18498,
   18507, 18512, 18513, 18519, 18520, 18522, 18527, 18528, 18529, 18530,
   18532, 18533, 18534, 18536, 18539, 18540, 18542, 18544, 18545, 18546,
-  18547, 18553, 18558, 18569, 18583, 18586, 18593.
+  18547, 18553, 18558, 18569, 18583, 18585, 18586, 18593.
 
 * Cache information can be queried via sysconf() function on s390 e.g. with
   _SC_LEVEL1_ICACHE_SIZE as argument.
diff --git a/elf/readlib.c b/elf/readlib.c
index 5c14a42..7fd5b8a 100644
--- a/elf/readlib.c
+++ b/elf/readlib.c
@@ -63,6 +63,13 @@ static struct known_names known_libs[] =
 };
 
 
+/* Check if string corresponds to a GDB Python file.  */
+static bool
+is_gdb_python_file (const char *name)
+{
+  size_t len = strlen (name);
+  return len > 7 && strcmp (name + len - 7, "-gdb.py") == 0;
+}
 
 /* Returns 0 if everything is ok, != 0 in case of error.  */
 int
@@ -157,7 +164,8 @@ process_file (const char *real_file_name, const char *file_name,
 	 beginning of the file.  */
       size_t len = MIN (statbuf.st_size, 512);
       if (memmem (file_contents, len, "GROUP", 5) == NULL
-	  && memmem (file_contents, len, "GNU ld script", 13) == NULL)
+	  && memmem (file_contents, len, "GNU ld script", 13) == NULL
+	  && !is_gdb_python_file (file_name))
 	error (0, 0, _("%s is not an ELF file - it has the wrong magic bytes at the start.\n"),
 	       file_name);
       ret = 1;

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog     |    7 +++++++
 NEWS          |    2 +-
 elf/readlib.c |   10 +++++++++-
 3 files changed, 17 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]