Skip to content

Commit

Permalink
Backport of Eric Le Lay's patch (bug report #2078) from v8.2 branch
Browse files Browse the repository at this point in the history
(r12063) for smooth compilation/installation under Solaris (/bin/sh ->
/bin/bash, -or -> -o in find, echo -n -> printf, ! in test rather than
in if).



git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@12065 85f007b7-540e-0410-9357-904b9bb8a0f7
  • Loading branch information
herbelin committed Apr 8, 2009
1 parent aa40ae5 commit 0cf5414
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 23 deletions.
32 changes: 16 additions & 16 deletions Makefile
@@ -1,6 +1,6 @@
#######################################################################
# v # The Coq Proof Assistant / The Coq Development Team #
# <O___,, # INRIA-Rocquencourt & LRI-CNRS-Orsay #
# <O___,, # INRIA-Rocquencourt & LRI-CNRS-osay #
# \VV/ #############################################################
# // # This file is distributed under the terms of the #
# # GNU Lesser General Public License Version 2.1 #
Expand Down Expand Up @@ -66,21 +66,21 @@
# but doesn't care if this build fails. This can be quite surprising,
# see in particular the -include in Makefile.stage*


export SHELL:=/bin/bash

# !! Before using FIND_VCS_CLAUSE, please read how you should in the !!
# !! FIND_VCS_CLAUSE section of dev/doc/build-system.dev.txt !!
export FIND_VCS_CLAUSE:='(' \
-name '{arch}' -or \
-name '.svn' -or \
-name '_darcs' -or \
-name '.git' -or \
-name '.bzr' -or \
-name 'debian' -or \
-name "$${GIT_DIR}" -or \
-name '{arch}' -o \
-name '.svn' -o \
-name '_darcs' -o \
-name '.git' -o \
-name '.bzr' -o \
-name 'debian' -o \
-name "$${GIT_DIR}" -o \
-name '_build' \
')' -prune -or
export PRUNE_CHECKER := -wholename ./checker/\* -prune -or
')' -prune -o
export PRUNE_CHECKER := -wholename ./checker/\* -prune -o

FIND_PRINTF_P:=-print | sed 's|^\./||'

Expand Down Expand Up @@ -189,16 +189,16 @@ clean: objclean cruftclean depclean docclean devdocclean
objclean: archclean indepclean

cruftclean: ml4clean
find . -name '*~' -or -name '*.annot' | xargs rm -f
find . -name '*~' -o -name '*.annot' | xargs rm -f
rm -f gmon.out core

indepclean:
rm -f $(GENFILES)
rm -f $(COQTOPBYTE) $(COQMKTOPBYTE) $(COQCBYTE) $(CHICKENBYTE)
rm -f bin/coq-interface$(EXE) bin/coq-parser$(EXE)
find . -name '*~' -or -name '*.cm[ioa]' | xargs rm -f
find . -name '*~' -o -name '*.cm[ioa]' | xargs rm -f
find . -name '*_mod.ml' | xargs rm -f
find plugins test-suite -name '*.vo' -or -name '*.glob' | xargs rm -f
find plugins test-suite -name '*.vo' -o -name '*.glob' | xargs rm -f
rm -f */*.pp[iox] plugins/*/*.pp[iox]
rm -rf $(SOURCEDOCDIR)
rm -f toplevel/mltop.byteml toplevel/mltop.optml
Expand Down Expand Up @@ -227,7 +227,7 @@ archclean: clean-ide cleantheories
rm -f $(COQTOPEXE) $(COQMKTOP) $(COQC) $(CHICKEN) $(COQDEPBOOT)
rm -f $(COQTOPOPT) $(COQMKTOPOPT) $(COQCOPT) $(CHICKENOPT)
rm -f bin/coq-parser.opt$(EXE) bin/coq-interface.opt$(EXE)
find . -name '*.cmx' -or -name '*.cmxs' -or -name '*.cmxa' -or -name '*.[soa]' -or -name '*.so' | xargs rm -f
find . -name '*.cmx' -o -name '*.cmxs' -o -name '*.cmxa' -o -name '*.[soa]' -o -name '*.so' | xargs rm -f
rm -f $(TOOLS) $(CSDPCERT)
rm -rf _build myocamlbuild_config.ml

Expand All @@ -254,7 +254,7 @@ distclean: clean cleanconfig

cleantheories:
rm -f states/*.coq
find theories -name '*.vo' -or -name '*.glob' | xargs rm -f
find theories -name '*.vo' -o -name '*.glob' | xargs rm -f

devdocclean:
find . -name '*.dep.ps' -o -name '*.dot' -exec rm -f {} \;
Expand Down
6 changes: 3 additions & 3 deletions Makefile.build
Expand Up @@ -365,12 +365,12 @@ else
# coq-interface and coq-parser are direct calls to coqtop with some dynlink

bin/coq-interface$(EXE):
echo "#!/bin/sh" > $@
echo "#!/bin/bash" > $@
echo 'exec '$(BINDIR)'/coqtop -require CoqInterface' >> $@
chmod +x $@

bin/coq-parser$(EXE):
echo "#!/bin/sh" > $@
echo "#!/bin/bash" > $@
echo 'exec '$(BINDIR)'/coqtop -batch -l CoqParser' >> $@
chmod +x $@

Expand Down Expand Up @@ -889,7 +889,7 @@ else
endif
%.ml4.d: $(D_DEPEND_BEFORE_SRC) %.ml4
$(SHOW)'CAMLP4DEPS $<'
$(HIDE)( /bin/echo -n '$*.cmo $*.cmx $*.ml4.ml.d $*.ml4-preprocessed: $(SEP)' && $(CAMLP4DEPS) "$<" ) > "$@" \
$(HIDE)( printf "%s" '$*.cmo $*.cmx $*.ml4.ml.d $*.ml4-preprocessed: $(SEP)' && $(CAMLP4DEPS) "$<" ) > "$@" \
|| ( RV=$$?; rm -f "$@"; exit $${RV} )

%.ml4.ml.d: $(D_DEPEND_BEFORE_SRC) %.ml4 $(D_DEPEND_AFTER_SRC) $(GENFILES) $(ML4FILESML) %.ml4.d
Expand Down
1 change: 1 addition & 0 deletions Makefile.stage1
Expand Up @@ -6,6 +6,7 @@
# # GNU Lesser General Public License Version 2.1 #
#######################################################################

export SHELL:=/bin/bash
include Makefile.build

# All includes must be declared secondary, otherwise make will delete
Expand Down
2 changes: 1 addition & 1 deletion build
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash

FLAGS=
OCAMLBUILD=ocamlbuild
Expand Down
4 changes: 2 additions & 2 deletions configure
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash

##################################
#
Expand Down Expand Up @@ -293,7 +293,7 @@ case $arch_spec in
ARCH=`/usr/bin/uname -s`
else
echo "I can not automatically find the name of your architecture"
echo -n\
printf "%s"\
"Give me a name, please [win32 for Win95, Win98 or WinNT]: "
read ARCH
fi
Expand Down
2 changes: 1 addition & 1 deletion install.sh
@@ -1,4 +1,4 @@
#! /bin/sh
#! /bin/bash

dest="$1"
shift
Expand Down

0 comments on commit 0cf5414

Please sign in to comment.