From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32190 invoked by alias); 27 Jun 2018 19:00:47 -0000 Mailing-List: contact gdb-testers-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-testers-owner@sourceware.org Received: (qmail 31901 invoked by uid 89); 27 Jun 2018 19:00:27 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,SPF_PASS autolearn=ham version=3.3.2 spammy=cleaning, Hx-languages-length:1562 X-HELO: kwanyin.sergiodj.net Received: from kwanyin.sergiodj.net (HELO kwanyin.sergiodj.net) (158.69.185.54) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 27 Jun 2018 19:00:25 +0000 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [binutils-gdb] Copy gdb-gdb.py to build dir From: sergiodj+buildbot@sergiodj.net To: gdb-testers@sourceware.org Message-Id: <141ec9f67f11a34bae5953b2923bb71fc74dd52f@gdb-build> Date: Wed, 27 Jun 2018 19:03:00 -0000 X-SW-Source: 2018-q2/txt/msg07219.txt.bz2 *** TEST RESULTS FOR COMMIT 141ec9f67f11a34bae5953b2923bb71fc74dd52f *** Author: Simon Marchi Branch: master Commit: 141ec9f67f11a34bae5953b2923bb71fc74dd52f Copy gdb-gdb.py to build dir I have thought for a long time how nice it would be to have cool pretty printers for GDB's internal types. Well, turns out there are few already in gdb-gdb.py! Unfortunately, if you build GDB outside of the source directory, that file never gets loaded. top-gdb will look for a file called ../path/to/build/gdb/gdb-gdb.py but that file is in the source directory at ../path/to/src/gdb/gdb-gdb.py This patch makes it so we copy it to the build directory, just like we do for gdb-gdb.gdb. With this, I can at least see the file getting automatically loaded: (top-gdb) info pretty-printer global pretty-printers: builtin mpx_bound128 objfile /home/emaisin/build/binutils-gdb/gdb/gdb pretty-printers: type_lookup_function I noticed that running "make" didn't re-generate gdb-gdb.py from gdb-gdb.py.in. That's because it's copied when running the configure script and that's it. I added a rule in the Makefile for that (and for gdb-gdb.gdb too) and added them as a dependency to the "all" target. gdb/ChangeLog: * gdb-gdb.py: Move to... * gdb-gdb.py.in: ... here. * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py. * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as dependencies. (distclean): Remove gdb-gdb.py when cleaning. (gdb-gdb.py, gdb-gdb.gdb): New rules. * configure: Re-generate.