1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59
|
# makefile to control installation of CCCC
ifeq "$(CONF)" "w32vc"
CD=cd
CP=../w32bin/cp
RM=../w32bin/rm -f
RMDIR=../w32bin/rm -rf
MV=../w32bin/mv
ECHO=../w32bin/echo
DIFF=../w32bin/diff
MKDIR=../w32bin/mkdir
INSTBIN1=cccc.exe
INSTBIN2=CcccDevStudioAddIn.dll
INSTDIR=C:/Program\ Files/CCCC
else
CD=cd
CP=cp
RM=rm -f
RMDIR=rm -rf
MV=mv
ECHO=echo
DIFF=diff
MKDIR=mkdir
INSTBIN1=cccc
INSTBIN2=
INSTDIR=/usr/local/bin
endif
# The installation is pretty crude
# we just go to the target directory for the machine
# we are on, delete old versions, copy new versions in
# There are lots of nicer things we could do on either
# platform, but this is the lowest common denominator which
# works consistently on both.
ifeq "$(CONF)" "w32vc"
all : install_cccc install_addin report_success
else
all : install_cccc report_success
endif
install_cccc :
-$(MKDIR) $(INSTDIR)
-$(RM) $(INSTDIR)/$(INSTBIN1)
$(CP) ../cccc/$(INSTBIN1) $(INSTDIR)
install_addin :
-$(RM) $(INSTDIR)/$(INSTBIN2)
$(CP) ../vcaddin/$(VARIANT)/$(INSTBIN2) $(INSTDIR)
# There are potential error messages relating to directories which
# already existed, which will be ignored, because we are being conservative
# and attempting creation unconditionally (so we don't have to ship Win32
# bash and test).
# So we finish the process with a message reassuring the user that all went well
report_success :
@$(ECHO) ===========================
@$(ECHO) Installation succeeded!
@$(ECHO) ===========================
|