[PATCH] Fixes accidental renaming of gdb.py file (i.e. libstdc++.so.6.0.22-gdb.py)

Michael Darling darlingm@gmail.com
Fri Jul 17 00:57:00 GMT 2015


Ping.  I don't have write access.

The attached patch still works with current trunk source, only failing
on the ChangeLog due to submissions since then.

On Fri, Jul 3, 2015 at 9:50 PM, Michael Darling <darlingm@gmail.com> wrote:
> The addition of libstdc++fs broke an inexact and fragile method in the
> libstdc++-v3/python makefile, so it mis-names a python script after
> libstdc++fs rather than libstdc++.
>
> With DESTDIR /usr/lib, toolexeclibdir ../lib, and the .so version of
> 6.0.21, this makefile used to install the python script to
> /usr/lib/libstdc++.so.6.0.21-gdb.py.
>
> Once libstdc++fs was added, this makefile installs the python script
> to /usr/lib/libstdc++fs.a-gdb.py.
>
> This makefile examines files named libstdc++* in
> DESTDIR/toolexeclibdir, excluding: symlinks; *.la files; and previous
> *-gdb.py files.  Its comments report it is done this way because
> "libtool hides the real names from us".
>
> This patch changes the makefile so it examines files named libstdc++.*
> (notice the addition of the dot.)  Although this is still not an
> optimum method, it at least puts the makefile on the right track
> again.  Adding the dot is more future-proof than excluding files
> starting with libstdc++fs, because of the possibility of future
> additions of similarly named libraries.
>
> The patch below is also an attachment to this email.
>
>
>
> Index: libstdc++-v3/ChangeLog
> ===================================================================
> --- libstdc++-v3/ChangeLog    (revision 225409)
> +++ libstdc++-v3/ChangeLog    (working copy)
> @@ -1,3 +1,9 @@
> +2015-07-03  Michael Darling  <darlingm@gmail.com>
> +
> +    * python/Makefile.am: python script name based off libstdc++.* rather
> +    than libstdc++*, to avoid being mis-named after libstdc++fs.
> +    * python/Makefile.in: Regenerate.
> +
>  2015-07-03  Jonathan Wakely  <jwakely@redhat.com>
>
>      * doc/xml/manual/status_cxx2017.xml: Update status table.
> Index: libstdc++-v3/python/Makefile.am
> ===================================================================
> --- libstdc++-v3/python/Makefile.am    (revision 225409)
> +++ libstdc++-v3/python/Makefile.am    (working copy)
> @@ -45,11 +45,11 @@
>      @$(mkdir_p) $(DESTDIR)$(toolexeclibdir)
>  ## We want to install gdb.py as SOMETHING-gdb.py.  SOMETHING is the
>  ## full name of the final library.  We want to ignore symlinks, the
> -## .la file, and any previous -gdb.py file.  This is inherently
> -## fragile, but there does not seem to be a better option, because
> -## libtool hides the real names from us.
> +## .la file, any previous -gdb.py file, and libstdc++fs*.  This is
> +## inherently fragile, but there does not seem to be a better option,
> +## because libtool hides the real names from us.
>      @here=`pwd`; cd $(DESTDIR)$(toolexeclibdir); \
> -      for file in libstdc++*; do \
> +      for file in libstdc++.*; do \
>          case $$file in \
>            *-gdb.py) ;; \
>            *.la) ;; \
> Index: libstdc++-v3/python/Makefile.in
> ===================================================================
> --- libstdc++-v3/python/Makefile.in    (revision 225409)
> +++ libstdc++-v3/python/Makefile.in    (working copy)
> @@ -547,7 +547,7 @@
>  install-data-local: gdb.py
>      @$(mkdir_p) $(DESTDIR)$(toolexeclibdir)
>      @here=`pwd`; cd $(DESTDIR)$(toolexeclibdir); \
> -      for file in libstdc++*; do \
> +      for file in libstdc++.*; do \
>          case $$file in \
>            *-gdb.py) ;; \
>            *.la) ;; \
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc.libstdc++-v3.python.dot.fix.patch
Type: application/octet-stream
Size: 1980 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20150717/6dc2fcd0/attachment.obj>


More information about the Gcc-patches mailing list