2001-10-02 Geert Bosch <bosch@gnat.com>
* misc.c (insert_default_attributes): Add dummy version.
+2003-01-27 Christian Cornelssen <ccorn@cs.tu-berlin.de>
+
+ * Make-lang.in (ada.install-common): Let $(DESTDIR)$(bindir)
+ be created if necessary. Remove erroneous and redundant
+ gnatchop installation commands. Test for gnatdll before
+ attempting to install it. Use initial tab instead of spaces
+ in continuation lines.
+ (ada.uninstall): Uninstall gnat instead of gnatcmd.
+ Also uninstall gnatfind, gnatxref, gnatlbr, and gnatdll
+ from all plausible locations.
+
fi ; \
fi
-if [ -f gnat1$(exeext) ] ; \
+ then \
+ if [ -f gnatchop-cross$(shext) ] ; \
+ then \
+ $(RM) $(DESTDIR)$(bindir)/$(target_alias)-gnatchop$(shext); \
+ $(INSTALL_PROGRAM) $(srcdir)/ada/gnatchop$(shext) $(DESTDIR)$(bindir)/$(target_alias)-gnatchop$(shext); \
+ if [ -d $(DESTDIR)$(tooldir)/bin/. ] ; then \
+ rm -f $(DESTDIR)$(tooldir)/bin/gnatchop$(shext); \
+ $(INSTALL_PROGRAM) gnatchop$(shext) $(DESTDIR)$(tooldir)/bin/gnatchop$(exeext); \
+ fi; \
+ else \
+ $(RM) $(DESTDIR)$(bindir)/gnatchop$(shext); \
+ $(INSTALL_PROGRAM) $(srcdir)/ada/gnatchop$(shext) $(DESTDIR)$(bindir)/gnatchop$(shext); \
+ fi ; \
+ fi
+ -if [ -f gnat1$(exeext) ] ; \
then \
if [ -f gnatchop-cross$(exeext) ] ; \
then \
$(RM) $(DESTDIR)$(bindir)/gnatdll$(exeext); \
$(INSTALL_PROGRAM) gnatdll$(exeext) $(DESTDIR)$(bindir)/gnatdll$(exeext); \
fi
+ -if [ -f gnat1$(exeext) ] ; \
+ then \
+ if [ -f gnatchop$(exeext) ] ; \
+ then \
+ $(RM) $(DESTDIR)$(bindir)/gnatchop$(exeext); \
+ $(INSTALL_PROGRAM) gnatchop$(exeext) $(DESTDIR)$(bindir)/gnatchop$(exeext); \
+ fi ; \
#
# Finally, install the library
#
# Create the directory before deleting it, in case the directory is
# a list of directories (as it may be on VMS). This ensures we are
# deleting the right one.
- -$(MKDIR) $(ADA_RTL_OBJ_DIR)
- -$(MKDIR) $(ADA_INCLUDE_DIR)
- $(RMDIR) $(ADA_RTL_OBJ_DIR)
- $(RMDIR) $(ADA_INCLUDE_DIR)
- -$(MKDIR) $(ADA_RTL_OBJ_DIR)
- -$(MKDIR) $(ADA_INCLUDE_DIR)
- -$(INSTALL_DATA) ada/rts/Makefile.adalib $(ADA_RTL_OBJ_DIR)
+ -$(MKDIR) $(DESTDIR)$(ADA_RTL_OBJ_DIR)
+ -$(MKDIR) $(DESTDIR)$(ADA_INCLUDE_DIR)
+ $(RMDIR) $(DESTDIR)$(ADA_RTL_OBJ_DIR)
+ $(RMDIR) $(DESTDIR)$(ADA_INCLUDE_DIR)
+ -$(MKDIR) $(DESTDIR)$(ADA_RTL_OBJ_DIR)
+ -$(MKDIR) $(DESTDIR)$(ADA_INCLUDE_DIR)
+ -$(INSTALL_DATA) ada/rts/Makefile.adalib $(DESTDIR)$(ADA_RTL_OBJ_DIR)
for file in ada/rts/*.ali; do \
- $(INSTALL_DATA) $$file $(ADA_RTL_OBJ_DIR); \
+ $(INSTALL_DATA) $$file $(DESTDIR)$(ADA_RTL_OBJ_DIR); \
done
-for file in ada/rts/*$(arext);do \
- $(INSTALL_DATA) $$file $(ADA_RTL_OBJ_DIR); \
+ $(INSTALL_DATA) $$file $(DESTDIR)$(ADA_RTL_OBJ_DIR); \
done
ifeq ($(strip $(filter-out alpha% dec vms%,$(targ))),)
-for file in ada/rts/lib*$(soext);do \
- $(INSTALL_DATA) $$file $(ADA_RTL_OBJ_DIR); \
+ $(INSTALL_DATA) $$file $(DESTDIR)$(ADA_RTL_OBJ_DIR); \
done
else
-for file in ada/rts/lib*-**$(soext);do \
- $(INSTALL_DATA) $$file $(ADA_RTL_OBJ_DIR); \
+ $(INSTALL_DATA) $$file $(DESTDIR)$(ADA_RTL_OBJ_DIR); \
done
endif
- -$(LN) $(ADA_RTL_OBJ_DIR)/libgnat-*$(soext) \
- $(ADA_RTL_OBJ_DIR)/libgnat$(soext)
- -$(LN) $(ADA_RTL_OBJ_DIR)/libgnarl-*$(soext) \
- $(ADA_RTL_OBJ_DIR)/libgnarl$(soext)
+ -( cd $(DESTDIR)$(ADA_RTL_OBJ_DIR) && \
+ $(LN) libgnat-*$(soext) libgnat$(soext) )
+ -( cd $(DESTDIR)$(ADA_RTL_OBJ_DIR) && \
+ $(LN) libgnarl-*$(soext) libgnarl$(soext) )
# This copy must be done preserving the date on the original file.
for file in ada/rts/*.adb ada/rts/*.ads; do \
- $(INSTALL_DATA_DATE) $$file $(ADA_INCLUDE_DIR); \
+ $(INSTALL_DATA_DATE) $$file $(DESTDIR)$(ADA_INCLUDE_DIR); \
done
- cd $(ADA_INCLUDE_DIR); $(CHMOD) a-wx *.adb
- cd $(ADA_INCLUDE_DIR); $(CHMOD) a-wx *.ads
+ cd $(DESTDIR)$(ADA_INCLUDE_DIR); $(CHMOD) a-wx *.adb
+ cd $(DESTDIR)$(ADA_INCLUDE_DIR); $(CHMOD) a-wx *.ads
../stamp-gnatlib2:
$(RM) rts/s-*.ali