llvm.org GIT mirror llvm / 4a0aaea
For PR528: * Consolidate all "install" usage to the install program/script found by autoconf which includes the autoconf/install-sh script if necessary * Change Makefile.rules to not use the -D flag to install but use the MKDIR command as necessary. * Change Makefile.rules to differentiate between installation of executable files and regular data files to get the permission modes correct. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20294 91177308-0d34-0410-b5e6-96231b3b80d8 Reid Spencer 14 years ago
2 changed file(s) with 16 addition(s) and 15 deletion(s). Raw diff Collapse all Expand all
127127 FLEX := @LEX@
128128 GREP := @GREP@
129129 INSTALL := @INSTALL@
130 INSTALL_SH := $(LLVM_SRC_ROOT)/autoconf/install-sh
131 INSTALL_PROGRAM = @INSTALL_PROGRAM@
132 INSTALL_SCRIPT = @INSTALL_SCRIPT@
133 INSTALL_DATA = @INSTALL_DATA@
134130 MKDIR := $(LLVM_SRC_ROOT)/autoconf/mkinstalldirs
135131 MV := @MV@
136132 RANLIB := @RANLIB@
304304 C.Flags += -v
305305 CXX.Flags += -v
306306 LD.Flags += -v
307 Install.Flags += -v
308307 VERBOSE := 1
309308 endif
310309
362361 $(CompileCommonOpts)
363362 LTInstall = $(LIBTOOL) $(LibTool.Flags) --mode=install $(INSTALL) \
364363 $(Install.Flags)
365 Install = $(INSTALL) $(Install.Flags)
364 ProgInstall = $(INSTALL) $(Install.Flags) -m 0755
365 DataInstall = $(INSTALL) $(Install.Flags) -m 0644
366366 Burg = $(BURG) -I $(PROJ_SRC_DIR)
367367 TableGen = $(TBLGEN) -I $(PROJ_SRC_DIR)
368368 Archive = $(AR) $(AR.Flags)
529529 $(Echo) Installing Configuration Files To $(PROJ_etcdir)
530530 $(Verb)for file in $(CONFIG_FILES); do \
531531 if test -f $(PROJ_OBJ_DIR)/$${file} ; then \
532 $(Install) -m 0644 $(PROJ_OBJ_DIR)/$${file} $(PROJ_etcdir) ; \
532 $(DataInstall) $(PROJ_OBJ_DIR)/$${file} $(PROJ_etcdir) ; \
533533 elif test -f $(PROJ_SRC_DIR)/$${file} ; then \
534 $(Install) -m 0644 $(PROJ_SRC_DIR)/$${file} $(PROJ_etcdir) ; \
534 $(DataInstall) $(PROJ_SRC_DIR)/$${file} $(PROJ_etcdir) ; \
535535 else \
536536 $(ECHO) Error: cannot find config file $${file}. ; \
537537 fi \
593593
594594 $(DestModule): $(ModuleDestDir) $(Module)
595595 $(Echo) Installing $(BuildMode) Bytecode Module $(DestModule)
596 $(Verb) $(Install) -D $(Module) $@
596 $(Verb) $(ProgInstall) $(Module) $(DestModule)
597597
598598 uninstall-local::
599599 $(Echo) Uninstalling $(BuildMode) Bytecode Module $(DestModule)
707707
708708 $(DestBytecodeLib): $(BytecodeDestDir) $(LibName.BCA)
709709 $(Echo) Installing $(BuildMode) Bytecode Archive $(DestBytecodeLib)
710 $(Verb) $(Install) -D $(LibName.BCA) $@
710 $(Verb) $(ProgInstall) $(LibName.BCA) $(DestBytecodeLib)
711711
712712 uninstall-local::
713713 $(Echo) Uninstalling $(BuildMode) Bytecode Archive $(DestBytecodeLib)
901901
902902 $(DestTool): $(PROJ_bindir) $(ToolBuildPath)
903903 $(Echo) Installing $(BuildMode) $(DestTool)
904 $(Verb) $(Install) -D $(ToolBuildPath) $(DestTool)
904 $(Verb) $(ProgInstall) $(ToolBuildPath) $(DestTool)
905905
906906 uninstall-local::
907907 $(Echo) Uninstalling $(BuildMode) $(DestTool)
14641464 install-local::
14651465 $(Echo) Installing include files
14661466 $(Verb) $(MKDIR) $(PROJ_includedir)
1467 $(Verb) if [ -d "$(PROJ_SRC_ROOT)/include" ] ; then \
1467 $(Verb) if test -d "$(PROJ_SRC_ROOT)/include" ; then \
14681468 cd $(PROJ_SRC_ROOT)/include && \
14691469 for hdr in `find . -type f '!' '(' -name '*~' -o -name '.cvsignore' \
14701470 -o -name '.#*' -o -name '*.in' ')' -print | grep -v CVS ` ; do \
1471 $(Install) -D -m 0644 $$hdr $(PROJ_includedir)/$$hdr ; \
1471 instdir=`dirname "$(PROJ_includedir)/$$hdr"` ; \
1472 if test \! -d "$$instdir" ; then \
1473 $(EchoCmd) Making install directory $$instdir ; \
1474 $(MKDIR) $$instdir ;\
1475 fi ; \
1476 $(DataInstall) $$hdr $(PROJ_includedir)/$$hdr ; \
14721477 done ; \
14731478 fi
1474 $(Verb) if [ -d "$(PROJ_OBJ_ROOT)/include" ] ; then \
1479 $(Verb) if test -d "$(PROJ_OBJ_ROOT)/include" ; then \
14751480 cd $(PROJ_OBJ_ROOT)/include && \
14761481 for hdr in `find . -type f -print` ; do \
1477 $(Install) -D -m 0644 $$hdr $(PROJ_includedir)/$$hdr ; \
1482 $(DataInstall) $$hdr $(PROJ_includedir)/$$hdr ; \
14781483 done ; \
14791484 fi
14801485