From: Jie Zhang <jie@codesourcery.com>
To: Doug Evans <dje@google.com>
Cc: Pedro Alves <pedro@codesourcery.com>, gdb-patches@sourceware.org
Subject: Re: Fix Makefile.in in data-directory
Date: Thu, 21 Oct 2010 05:11:00 -0000 [thread overview]
Message-ID: <4CBFCB92.5020204@codesourcery.com> (raw)
In-Reply-To: <AANLkTikV52p=SYgg2BA59mXVixWPtSL7dhqmzrJv6AN0@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 994 bytes --]
On 10/21/2010 10:29 AM, Doug Evans wrote:
> On Wed, Oct 20, 2010 at 7:15 PM, Jie Zhang<jie@codesourcery.com> wrote:
>> I don't think it's really necessary to fix that. binutils and gcc also don't
>> allow "make -j4 install" to directly after "configure". "make -j4 all
>> install" also fails for binutils and gcc. I think it's already an convention
>> that those software are built with
>>
>> ./configure
>> make
>> make install
>>
>> Do we really need the effort to fix GDB?
>
> fwiw, I think the answer is yes.
>
> Note that we don't need to consider ./configure ; make -j4 install.
>
> The issue arises with a simple "$EDITOR foo.c ; make -j4 install".
Reasonable although I never used it before. This is an updated patch
which does that. It fixes it by passing FLAGS_TO_PASS when recursively
make install-only. It fixes my issue. I also tested by touching a source
file and do "make -j4 install" in gdb directory. It behaves as expected.
OK now?
Regards,
--
Jie Zhang
CodeSourcery
[-- Attachment #2: gdb-fix-install-only.diff --]
[-- Type: text/x-patch, Size: 4396 bytes --]
* Makefile.in (install): Remove dependency of install-only and
recursively invoke make for install-only.
* data-directory/Makefile.in: Add FLAGS_TO_PASS variable.
(install): Pass FLAGS_TO_PASS when recursively make install-only.
gdbserver/
* Makefile.in: Add FLAGS_TO_PASS variable.
(install): Remove dependency of install-only and recursively
invoke make for install-only.
Index: Makefile.in
===================================================================
RCS file: /cvs/src/src/gdb/Makefile.in,v
retrieving revision 1.1136
diff -u -p -r1.1136 Makefile.in
--- Makefile.in 6 Oct 2010 16:46:12 -0000 1.1136
+++ Makefile.in 21 Oct 2010 04:22:12 -0000
@@ -970,7 +970,8 @@ gdb.z:gdb.1
# source file and doesn't care about rebuilding or just wants to save the
# time it takes for make to check that all is up to date.
# install-only is intended to address that need.
-install: all install-only
+install: all
+ @$(MAKE) $(FLAGS_TO_PASS) install-only
install-only: $(CONFIG_INSTALL)
transformed_name=`t='$(program_transform_name)'; \
Index: data-directory/Makefile.in
===================================================================
RCS file: /cvs/src/src/gdb/data-directory/Makefile.in,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile.in
--- data-directory/Makefile.in 13 Oct 2010 20:08:44 -0000 1.3
+++ data-directory/Makefile.in 21 Oct 2010 04:22:12 -0000
@@ -54,6 +54,38 @@ PYTHON_FILES = \
gdb/__init__.py \
gdb/types.py
+FLAGS_TO_PASS = \
+ "prefix=$(prefix)" \
+ "exec_prefix=$(exec_prefix)" \
+ "infodir=$(infodir)" \
+ "datarootdir=$(datarootdir)" \
+ "docdir=$(docdir)" \
+ "htmldir=$(htmldir)" \
+ "pdfdir=$(pdfdir)" \
+ "libdir=$(libdir)" \
+ "mandir=$(mandir)" \
+ "datadir=$(datadir)" \
+ "includedir=$(includedir)" \
+ "against=$(against)" \
+ "DESTDIR=$(DESTDIR)" \
+ "AR=$(AR)" \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CC=$(CC)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXX=$(CXX)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "DLLTOOL=$(DLLTOOL)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "RANLIB=$(RANLIB)" \
+ "MAKEINFO=$(MAKEINFO)" \
+ "MAKEHTML=$(MAKEHTML)" \
+ "MAKEHTMLFLAGS=$(MAKEHTMLFLAGS)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "RUNTEST=$(RUNTEST)" \
+ "RUNTESTFLAGS=$(RUNTESTFLAGS)"
+
.PHONY: all
all: stamp-syscalls stamp-python
@@ -146,7 +178,7 @@ uninstall-python:
# install-only is intended to address that need.
.PHONY: install
install: all
- $(MAKE) install-only
+ @$(MAKE) $(FLAGS_TO_PASS) install-only
.PHONY: install-only
install-only: install-syscalls install-python
Index: gdbserver/Makefile.in
===================================================================
RCS file: /cvs/src/src/gdb/gdbserver/Makefile.in,v
retrieving revision 1.98
diff -u -p -r1.98 Makefile.in
--- gdbserver/Makefile.in 4 Oct 2010 23:32:40 -0000 1.98
+++ gdbserver/Makefile.in 21 Oct 2010 04:22:12 -0000
@@ -151,6 +151,38 @@ XML_BUILTIN = @srv_xmlbuiltin@
IPA_DEPFILES = @IPA_DEPFILES@
extra_libraries = @extra_libraries@
+FLAGS_TO_PASS = \
+ "prefix=$(prefix)" \
+ "exec_prefix=$(exec_prefix)" \
+ "infodir=$(infodir)" \
+ "datarootdir=$(datarootdir)" \
+ "docdir=$(docdir)" \
+ "htmldir=$(htmldir)" \
+ "pdfdir=$(pdfdir)" \
+ "libdir=$(libdir)" \
+ "mandir=$(mandir)" \
+ "datadir=$(datadir)" \
+ "includedir=$(includedir)" \
+ "against=$(against)" \
+ "DESTDIR=$(DESTDIR)" \
+ "AR=$(AR)" \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CC=$(CC)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXX=$(CXX)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "DLLTOOL=$(DLLTOOL)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "RANLIB=$(RANLIB)" \
+ "MAKEINFO=$(MAKEINFO)" \
+ "MAKEHTML=$(MAKEHTML)" \
+ "MAKEHTMLFLAGS=$(MAKEHTMLFLAGS)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "RUNTEST=$(RUNTEST)" \
+ "RUNTESTFLAGS=$(RUNTESTFLAGS)"
+
# Prevent Sun make from putting in the machine type. Setting
# TARGET_ARCH to nothing works for SunOS 3, 4.0, but not for 4.1.
.c.o:
@@ -163,7 +195,9 @@ all: gdbserver$(EXEEXT) gdbreplay$(EXEEX
# source file and doesn't care about rebuilding or just wants to save the
# time it takes for make to check that all is up to date.
# install-only is intended to address that need.
-install: all install-only
+install: all
+ @$(MAKE) $(FLAGS_TO_PASS) install-only
+
install-only:
n=`echo gdbserver | sed '$(program_transform_name)'`; \
if [ x$$n = x ]; then n=gdbserver; else true; fi; \
next prev parent reply other threads:[~2010-10-21 5:11 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-20 12:09 Jie Zhang
2010-10-20 20:13 ` Doug Evans
2010-10-21 0:10 ` Jie Zhang
2010-10-21 0:14 ` Pedro Alves
2010-10-21 0:17 ` Jie Zhang
2010-10-21 0:29 ` Pedro Alves
2010-10-21 2:15 ` Jie Zhang
2010-10-21 2:30 ` Doug Evans
2010-10-21 5:11 ` Jie Zhang [this message]
2010-10-21 21:06 ` Doug Evans
2010-10-21 23:52 ` Jie Zhang
2010-10-21 10:07 ` Pedro Alves
2010-10-21 14:46 ` Joel Brobecker
2010-10-22 1:14 ` Tom Tromey
2010-10-21 21:08 ` Doug Evans
2010-10-22 1:11 ` Tom Tromey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4CBFCB92.5020204@codesourcery.com \
--to=jie@codesourcery.com \
--cc=dje@google.com \
--cc=gdb-patches@sourceware.org \
--cc=pedro@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox