This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


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

PATCH: java install rules


Hi,
A while back I noticed that the java install installs gcj, gcjh jc-scan and
jcf-dump without taking notice of program_transform_name. Although these
programs are for both native and cross compiled java, I think they should be
installed with a program transform. May be they should be installed under both
transforms? This patch changes the install commands so that the
program_transform_name is taken into consideration.

I also changed the uninstall rule, to delete these programs.

I noticed that the invocations of INSTALL_PROGRAM are all of the form
	rm -f <target>
	$(INSTALL_PROGRAM) <src> <target>
	chmod a+x <target>

My understanding of INSTALL_PROGRAM is that it is supposed to do the rm and
chmod itself, the install-sh script does this, so there's no need for them to
be explicitly done in the make files. This is not just a java thing, other
makefile fragments do the same. Am I missing something here?

Enjoy

nathan
-- 
Dr Nathan Sidwell :: Computer Science Department :: Bristol University
      You can up the bandwidth, but you can't up the speed of light      
nathan@acm.org  http://www.cs.bris.ac.uk/~nathan/  nathan@cs.bris.ac.uk
egcs/gcc/java/ChangeLog:
Fri Feb 19 17:42:47 GMT 1999  Nathan Sidwell  <nathan@acm.org>

	* Make-lang.in (java.install-common): Apply
	program_transform_name to target independent tools.
	(java.uninstall): Remove the target independent tools.

Index: egcs/gcc/java/Make-lang.in
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/java/Make-lang.in,v
retrieving revision 1.17
diff -c -3 -p -r1.17 Make-lang.in
*** Make-lang.in	1999/02/03 21:57:59	1.17
--- Make-lang.in	1999/02/19 17:37:50
*************** java.install-common:
*** 170,178 ****
  	fi ; \
          for tool in $(JAVA_TARGET_INDEPENDENT_BIN_TOOLS); do \
            if [ -f $$tool$(exeext) ]; then \
! 	    rm -f $(bindir)/$$tool$(exeext); \
! 	    $(INSTALL_PROGRAM) $$tool$(exeext) $(bindir)/$$tool$(exeext); \
! 	    chmod a+x $(bindir)/$$tool$(exeext); \
            fi ; \
         done
  
--- 170,178 ----
  	fi ; \
          for tool in $(JAVA_TARGET_INDEPENDENT_BIN_TOOLS); do \
            if [ -f $$tool$(exeext) ]; then \
! 	    rm -f $(bindir)/`t='$(program_transform_name)'; echo $$tool | sed -e $$t`$(exeext); \
! 	    $(INSTALL_PROGRAM) $$tool$(exeext) $(bindir)/`t='$(program_transform_name)'; echo $$tool | sed -e $$t`$(exeext); \
! 	    chmod a+x  $(bindir)/`t='$(program_transform_name)'; echo $$tool | sed -e $$t`$(exeext); \
            fi ; \
         done
  
*************** java.install-man:
*** 181,186 ****
--- 181,189 ----
  java.uninstall:
  	-rm -rf $(bindir)/$(JAVA_INSTALL_NAME)$(exeext)
  	-rm -rf $(bindir)/$(JAVA_CROSS_NAME)$(exeext)
+         for tool in $(JAVA_TARGET_INDEPENDENT_BIN_TOOLS); do \
+ 	  rm -f $(bindir)/`t='$(program_transform_name)'; echo $$tool | sed -e $$t`$(exeext); \
+ 	done
  
  java.install-info:
  

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