Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "H. J. Lu" <hjl@lucon.org>
To: Andrew Cagney <ac131313@redhat.com>
Cc: GDB <gdb-patches@sources.redhat.com>
Subject: Re: PATCH: Support DESTDIR
Date: Thu, 07 Aug 2003 22:53:00 -0000	[thread overview]
Message-ID: <20030807225314.GA27827@lucon.org> (raw)
In-Reply-To: <3F2E6A53.70207@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 622 bytes --]

On Mon, Aug 04, 2003 at 10:14:43AM -0400, Andrew Cagney wrote:
> Hmm, which of these is correct:
> 
> >-	$(SHELL) $(srcdir)/../../mkinstalldirs $(infodir)
> >+	$(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)/$(infodir)
> 
> >-		$(INSTALL_DATA) $$i $(htmldir)/$$i ; \
> >+		$(INSTALL_DATA) $$i $(DESTDIR)$(htmldir)/$$i ; \
> 
> (the slash)?
> 
> > +	$(mkinstalldirs) $(DESTDIR)$(infodir)
> 
> Please keep the mkinstalldirs consistent with the rest of GDB vis:
> 	$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$infodir)
> The addition of mkinstalldirs should be mentioned in the ChangeLog.
> 

Here is the new one.


H.J.

[-- Attachment #2: gdb-install-2.patch --]
[-- Type: text/plain, Size: 5548 bytes --]

gdb/

2003-08-07  H.J. Lu  <hongjiu.lu@intel.com>

	* Makefile.in (FLAGS_TO_PASS): Add DESTDIR.
	(install-only): Support DESTDIR.
	(uninstall): Likewise.
	(install-gdbtk): Likewise.

gdb/doc/

2003-08-07  H.J. Lu  <hongjiu.lu@intel.com>

	* Makefile.in (install-info): Support DESTDIR.
	(install-html): Likewise.

gdb/gdbserver/

2003-08-07  H.J. Lu  <hongjiu.lu@intel.com>

	* Makefile.in (install-only): Create dest dir. Support DESTDIR.
	(uninstall): Support DESTDIR.

mmalloc/

2003-07-31  H.J. Lu  <hongjiu.lu@intel.com>

	* Makefile.in (install-info): Create dest dir. Support DESTDIR.
	(install): Likewise.

--- gdb/gdb/Makefile.in.install	2003-08-06 19:59:38.000000000 -0700
+++ gdb/gdb/Makefile.in	2003-08-06 20:42:32.000000000 -0700
@@ -430,6 +430,7 @@ FLAGS_TO_PASS = \
 	"datadir=$(datadir)" \
 	"includedir=$(includedir)" \
 	"against=$(against)" \
+	"DESTDIR=$(DESTDIR)" \
 	"AR=$(AR)" \
 	"AR_FLAGS=$(AR_FLAGS)" \
 	"CC=$(CC)" \
@@ -963,7 +964,7 @@ install-only: $(CONFIG_INSTALL)
 		else \
 		  true ; \
 		fi ; \
-		$(SHELL) $(srcdir)/../mkinstalldirs $(bindir) ; \
+		$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(bindir) ; \
 		$(INSTALL_PROGRAM) gdb$(EXEEXT) \
 			$(DESTDIR)$(bindir)/$$transformed_name$(EXEEXT) ; \
 		$(SHELL) $(srcdir)/../mkinstalldirs \
@@ -980,7 +981,8 @@ uninstall: force $(CONFIG_UNINSTALL)
 		else \
 		  true ; \
 		fi ; \
-		rm -f $(bindir)/$$transformed_name$(EXEEXT) $(man1dir)/$$transformed_name.1
+		rm -f $(DESTDIR)$(bindir)/$$transformed_name$(EXEEXT) \
+		      $(DESTDIR)$(man1dir)/$$transformed_name.1
 	@$(MAKE) DO=uninstall "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do 
 
 # We do this by grepping through sources.  If that turns out to be too slow,
@@ -2471,7 +2473,7 @@ install-gdbtk:
 	else \
 	  true ; \
 	fi ; \
-	$(SHELL) $(srcdir)/../mkinstalldirs $(bindir); \
+	$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(bindir); \
 	$(INSTALL_PROGRAM) insight$(EXEEXT) \
 		$(DESTDIR)$(bindir)/$$transformed_name$(EXEEXT) ; \
 	$(SHELL) $(srcdir)/../mkinstalldirs \
--- gdb/gdb/doc/Makefile.in.install	2003-08-06 19:59:40.000000000 -0700
+++ gdb/gdb/doc/Makefile.in	2003-08-06 20:07:00.000000000 -0700
@@ -156,14 +156,14 @@ all-doc: info dvi ps # pdf
 diststuff: info
 
 install-info: $(INFO_DEPS)
-	$(SHELL) $(srcdir)/../../mkinstalldirs $(infodir)
+	$(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(infodir)
 	@list='$(INFO_DEPS)'; \
 	for file in $$list; do \
 	  if test -f $$file; then d=.; else d=$(srcdir); fi; \
 	  for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \
 	    if test -f $$d/$$ifile; then \
-	      echo " $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile"; \
-	      $(INSTALL_DATA) $$d/$$ifile $(infodir)/$$ifile; \
+	      echo " $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile"; \
+	      $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile; \
 	    else : ; fi; \
 	  done; \
 	done
@@ -171,8 +171,8 @@ install-info: $(INFO_DEPS)
 	@if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
 	  list='$(INFO_DEPS)'; \
 	  for file in $$list; do \
-	    echo " install-info --info-dir=$(infodir) $(infodir)/$$file";\
-	    install-info --info-dir=$(infodir) $(infodir)/$$file || :;\
+	    echo " install-info --info-dir=$(infodir) $(DESTDIR)$(infodir)/$$file";\
+	    install-info --info-dir=$(infodir) $(DESTDIR)$(infodir)/$$file || :;\
 	  done; \
 	else : ; fi
 
@@ -194,7 +194,7 @@ uninstall-info:
 
 install-html: html
 	for i in *.html ; do \
-		$(INSTALL_DATA) $$i $(htmldir)/$$i ; \
+		$(INSTALL_DATA) $$i $(DESTDIR)$(htmldir)/$$i ; \
 	done
 
 STAGESTUFF = *.info* gdb-all.texi GDBvn.texi *.ps *.dvi *.pdf
--- gdb/gdb/gdbserver/Makefile.in.install	2003-07-08 13:09:11.000000000 -0700
+++ gdb/gdb/gdbserver/Makefile.in	2003-08-06 20:06:21.000000000 -0700
@@ -151,13 +151,15 @@ install: all install-only
 install-only: 
 	n=`echo gdbserver | sed '$(program_transform_name)'`; \
 	if [ x$$n = x ]; then n=gdbserver; else true; fi; \
-	$(INSTALL_PROGRAM) gdbserver $(bindir)/$$n; \
-	$(INSTALL_DATA) $(srcdir)/gdbserver.1 $(man1dir)/$$n.1
+	$(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(bindir); \
+	$(INSTALL_PROGRAM) gdbserver $(DESTDIR)$(bindir)/$$n; \
+	$(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(man1dir); \
+	$(INSTALL_DATA) $(srcdir)/gdbserver.1 $(DESTDIR)$(man1dir)/$$n.1
 
 uninstall: force
 	n=`echo gdbserver | sed '$(program_transform_name)'`; \
 	if [ x$$n = x ]; then n=gdbserver; else true; fi; \
-	rm -f $(bindir)/$$n $(man1dir)/$$n.1
+	rm -f $(bindir)/$$n $(DESTDIR)$(man1dir)/$$n.1
 
 installcheck:
 check:
--- gdb/mmalloc/Makefile.in.install	2002-11-28 08:46:31.000000000 -0800
+++ gdb/mmalloc/Makefile.in	2003-08-06 20:47:07.000000000 -0700
@@ -113,6 +113,7 @@ mmalloc.dvi: mmalloc.texi
 	rm -f mmalloc.?? mmalloc.??s mmalloc.log mmalloc.aux mmalloc.toc
 
 install-info: info
+	$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(infodir)
 	@list='$(INFO_DEPS)'; \
 	for file in $$list; do \
 	  if test -f $$file; then d=.; else d=$(srcdir); fi; \
@@ -156,9 +157,10 @@ check: test1.c
 #	./a.out
 
 install:	all install-info
-		$(INSTALL_DATA) $(TARGETLIB) $(libdir)/$(TARGETLIB)n
-		$(RANLIB) $(libdir)/$(TARGETLIB)n
-		mv -f $(libdir)/$(TARGETLIB)n $(libdir)/$(TARGETLIB)
+		$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(libdir)
+		$(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(libdir)/$(TARGETLIB)n
+		$(RANLIB) $(DESTDIR)$(libdir)/$(TARGETLIB)n
+		mv -f $(DESTDIR)$(libdir)/$(TARGETLIB)n $(DESTDIR)$(libdir)/$(TARGETLIB)
 
 uninstall:	uninstall-info
 

  reply	other threads:[~2003-08-07 22:53 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-31 22:09 H. J. Lu
2003-08-04 14:14 ` Andrew Cagney
2003-08-07 22:53   ` H. J. Lu [this message]
2003-08-08  2:10     ` Andrew Cagney

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=20030807225314.GA27827@lucon.org \
    --to=hjl@lucon.org \
    --cc=ac131313@redhat.com \
    --cc=gdb-patches@sources.redhat.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