Protect install paths against spaces (on Windows)

master
Christophe Troestler 2015-11-27 22:30:41 +01:00 committed by Damien Doligez
parent 59aab8d1c2
commit 7f6a8ae2f0
16 changed files with 124 additions and 119 deletions

View File

@ -184,32 +184,33 @@ INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
INSTALL_COMPLIBDIR=$(DESTDIR)$(COMPLIBDIR)
INSTALL_STUBLIBDIR=$(DESTDIR)$(STUBLIBDIR)
INSTALL_MANDIR=$(DESTDIR)$(MANDIR)
INSTALL_DISTRIB=$(DESTDIR)$(PREFIX)
install: installbyt installopt
installbyt:
mkdir -p $(INSTALL_BINDIR)
mkdir -p $(INSTALL_LIBDIR)
mkdir -p $(INSTALL_STUBLIBDIR)
mkdir -p $(INSTALL_COMPLIBDIR)
cp VERSION $(INSTALL_LIBDIR)/
mkdir -p "$(INSTALL_BINDIR)"
mkdir -p "$(INSTALL_LIBDIR)"
mkdir -p "$(INSTALL_STUBLIBDIR)"
mkdir -p "$(INSTALL_COMPLIBDIR)"
cp VERSION "$(INSTALL_LIBDIR)/"
cd byterun ; $(MAKEREC) install
cp ocamlc $(INSTALL_BINDIR)/ocamlc.exe
cp ocaml $(INSTALL_BINDIR)/ocaml.exe
cp ocamlc "$(INSTALL_BINDIR)/ocamlc.exe"
cp ocaml "$(INSTALL_BINDIR)/ocaml.exe"
cd stdlib ; $(MAKEREC) install
cp lex/ocamllex $(INSTALL_BINDIR)/ocamllex.exe
cp yacc/ocamlyacc.exe $(INSTALL_BINDIR)/ocamlyacc.exe
cp lex/ocamllex "$(INSTALL_BINDIR)/ocamllex.exe"
cp yacc/ocamlyacc.exe "$(INSTALL_BINDIR)/ocamlyacc.exe"
cp utils/*.cmi utils/*.cmt utils/*.cmti \
parsing/*.cmi parsing/*.cmt parsing/*.cmti \
typing/*.cmi typing/*.cmt typing/*.cmti \
bytecomp/*.cmi bytecomp/*.cmt bytecomp/*.cmti \
driver/*.cmi driver/*.cmt driver/*.cmti \
toplevel/*.cmi toplevel/*.cmt toplevel/*.cmti $(INSTALL_COMPLIBDIR)
toplevel/*.cmi toplevel/*.cmt toplevel/*.cmti "$(INSTALL_COMPLIBDIR)"
cp compilerlibs/ocamlcommon.cma compilerlibs/ocamlbytecomp.cma \
compilerlibs/ocamltoplevel.cma $(BYTESTART) $(TOPLEVELSTART) \
$(INSTALL_COMPLIBDIR)
cp expunge $(INSTALL_LIBDIR)/expunge.exe
cp toplevel/topdirs.cmi $(INSTALL_LIBDIR)
"$(INSTALL_COMPLIBDIR)"
cp expunge "$(INSTALL_LIBDIR)/expunge.exe"
cp toplevel/topdirs.cmi "$(INSTALL_LIBDIR)"
cd tools ; $(MAKEREC) install
for i in $(OTHERLIBRARIES); do \
$(MAKEREC) -C otherlibs/$$i install || exit $$?; \
@ -220,11 +221,11 @@ installbyt:
else :; fi
if test -n "$(FLEXDLL_SUBMODULE_PRESENT)"; then $(MAKEREC) install-flexdll; \
else :; fi
cp config/Makefile $(INSTALL_LIBDIR)/Makefile.config
cp README.adoc $(INSTALL_DISTRIB)/Readme.general.txt
cp README.win32.adoc $(INSTALL_DISTRIB)/Readme.windows.txt
cp LICENSE $(INSTALL_DISTRIB)/License.txt
cp Changes $(INSTALL_DISTRIB)/Changes.txt
cp config/Makefile "$(INSTALL_LIBDIR)/Makefile.config"
cp README.adoc "$(INSTALL_DISTRIB)/Readme.general.txt"
cp README.win32.adoc "$(INSTALL_DISTRIB)/Readme.windows.txt"
cp LICENSE "$(INSTALL_DISTRIB)/License.txt"
cp Changes "$(INSTALL_DISTRIB)/Changes.txt"
install-flexdll:
# The $(if ...) installs the correct .manifest file for MSVC and MSVC64
@ -235,14 +236,14 @@ install-flexdll:
# Installation of the native-code compiler
installopt:
cd asmrun ; $(MAKEREC) install
cp ocamlopt $(INSTALL_BINDIR)/ocamlopt.exe
cp ocamlopt "$(INSTALL_BINDIR)/ocamlopt.exe"
cd stdlib ; $(MAKEREC) installopt
cp middle_end/*.cmi middle_end/*.cmt middle_end/*.cmti \
$(INSTALL_COMPLIBDIR)
"$(INSTALL_COMPLIBDIR)"
cp middle_end/base_types/*.cmi middle_end/base_types/*.cmt \
middle_end/base_types/*.cmti $(INSTALL_COMPLIBDIR)
cp asmcomp/*.cmi asmcomp/*.cmt asmcomp/*.cmti $(INSTALL_COMPLIBDIR)
cp compilerlibs/ocamloptcomp.cma $(OPTSTART) $(INSTALL_COMPLIBDIR)
middle_end/base_types/*.cmti "$(INSTALL_COMPLIBDIR)"
cp asmcomp/*.cmi asmcomp/*.cmt asmcomp/*.cmti "$(INSTALL_COMPLIBDIR)"
cp compilerlibs/ocamloptcomp.cma $(OPTSTART) "$(INSTALL_COMPLIBDIR)"
if test -n "$(WITH_OCAMLDOC)"; then (cd ocamldoc; $(MAKEREC) installopt); fi
for i in $(OTHERLIBRARIES); do \
$(MAKEREC) -C otherlibs/$$i installopt || exit $$?; \
@ -252,17 +253,17 @@ installopt:
if test -f ocamlopt.opt -a -f flexdll/flexlink.opt ; then cp -f flexdll/flexlink.opt $(INSTALL_BINDIR)/flexlink.exe ; fi
installoptopt:
cp ocamlc.opt $(INSTALL_BINDIR)/ocamlc.opt$(EXE)
cp ocamlopt.opt $(INSTALL_BINDIR)/ocamlopt.opt$(EXE)
cp lex/ocamllex.opt $(INSTALL_BINDIR)/ocamllex.opt$(EXE)
cp ocamlc.opt "$(INSTALL_BINDIR)/ocamlc.opt$(EXE)"
cp ocamlopt.opt "$(INSTALL_BINDIR)/ocamlopt.opt$(EXE)"
cp lex/ocamllex.opt "$(INSTALL_BINDIR)/ocamllex.opt$(EXE)"
cp utils/*.cmx parsing/*.cmx typing/*.cmx bytecomp/*.cmx \
driver/*.cmx asmcomp/*.cmx $(INSTALL_COMPLIBDIR)
driver/*.cmx asmcomp/*.cmx "$(INSTALL_COMPLIBDIR)"
cp compilerlibs/ocamlcommon.cmxa compilerlibs/ocamlcommon.$(A) \
compilerlibs/ocamlbytecomp.cmxa compilerlibs/ocamlbytecomp.$(A) \
compilerlibs/ocamloptcomp.cmxa compilerlibs/ocamloptcomp.$(A) \
$(BYTESTART:.cmo=.cmx) $(BYTESTART:.cmo=.$(O)) \
$(OPTSTART:.cmo=.cmx) $(OPTSTART:.cmo=.$(O)) \
$(INSTALL_COMPLIBDIR)
"$(INSTALL_COMPLIBDIR)"
clean:: partialclean

View File

@ -61,7 +61,7 @@ amd64.o: amd64.S
INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
install:
cp libasmrun.$(A) $(INSTALL_LIBDIR)
cp libasmrun.$(A) "$(INSTALL_LIBDIR)"
$(LINKEDFILES): %.c: ../byterun/%.c
cp ../byterun/$*.c $*.c

View File

@ -66,9 +66,9 @@ install-noshared:
.PHONY: install-noshared
install-shared:
cp libcamlrun_shared.so $(INSTALL_LIBDIR)/libcamlrun_shared.so
cp libcamlrun_pic.a $(INSTALL_LIBDIR)/libcamlrun_pic.a
cd $(INSTALL_LIBDIR); $(RANLIB) libcamlrun_pic.a
cp libcamlrun_shared.so "$(INSTALL_LIBDIR)/libcamlrun_shared.so"
cp libcamlrun_pic.a "$(INSTALL_LIBDIR)/libcamlrun_pic.a"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) libcamlrun_pic.a
.PHONY: install-shared
clean::

View File

@ -63,15 +63,15 @@ INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
install::
cp $(CAMLRUN)$(EXE) $(INSTALL_BINDIR)/ocamlrun$(EXE)
cp libcamlrun.$(A) $(INSTALL_LIBDIR)/libcamlrun.$(A)
cd $(INSTALL_LIBDIR); $(RANLIB) libcamlrun.$(A)
if test -d $(INSTALL_LIBDIR)/caml; then : ; \
else mkdir $(INSTALL_LIBDIR)/caml; fi
cp $(CAMLRUN)$(EXE) "$(INSTALL_BINDIR)/ocamlrun$(EXE)"
cp libcamlrun.$(A) "$(INSTALL_LIBDIR)/libcamlrun.$(A)"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) libcamlrun.$(A)
if test -d "$(INSTALL_LIBDIR)/caml"; then : ; \
else mkdir "$(INSTALL_LIBDIR)/caml"; fi
for i in $(PUBLIC_INCLUDES); do \
sed -f ../tools/cleanup-header caml/$$i > $(INSTALL_LIBDIR)/caml/$$i; \
sed -f ../tools/cleanup-header caml/$$i > "$(INSTALL_LIBDIR)/caml/$$i"; \
done
cp ld.conf $(INSTALL_LIBDIR)/ld.conf
cp ld.conf "$(INSTALL_LIBDIR)/ld.conf"
.PHONY: install
install:: install-$(RUNTIMED)
@ -84,8 +84,8 @@ install-noruntimed:
# because it's an executable for the target machine, while we're installing
# binaries for the host.
install-runtimed:
cp ocamlrund$(EXE) $(INSTALL_BINDIR)/ocamlrund$(EXE)
cp libcamlrund.$(A) $(INSTALL_LIBDIR)/libcamlrund.$(A)
cp ocamlrund$(EXE) "$(INSTALL_BINDIR)/ocamlrund$(EXE)"
cp libcamlrund.$(A) "$(INSTALL_LIBDIR)/libcamlrund.$(A)"
.PHONY: install-runtimed
ifeq "$(RUNTIMEI)" "true"

View File

@ -91,7 +91,7 @@ ocamldebug$(EXE): $(OBJS) $(OTHEROBJS)
$(CAMLC) $(LINKFLAGS) -o ocamldebug$(EXE) -linkall $(OTHEROBJS) $(OBJS)
install:
cp ocamldebug$(EXE) $(INSTALL_BINDIR)/ocamldebug$(EXE)
cp ocamldebug$(EXE) "$(INSTALL_BINDIR)/ocamldebug$(EXE)"
clean::
rm -f ocamldebug$(EXE)

View File

@ -253,24 +253,24 @@ odoc_see_lexer.ml: odoc_see_lexer.mll
# Installation targets
######################
install: dummy
if test -d $(INSTALL_BINDIR); then : ; else $(MKDIR) $(INSTALL_BINDIR); fi
if test -d $(INSTALL_LIBDIR); then : ; else $(MKDIR) $(INSTALL_LIBDIR); fi
if test -d $(INSTALL_CUSTOMDIR); then : ; else $(MKDIR) $(INSTALL_CUSTOMDIR); fi
$(CP) $(OCAMLDOC) $(INSTALL_BINDIR)/$(OCAMLDOC)$(EXE)
$(CP) ocamldoc.hva *.cmi $(OCAMLDOC_LIBCMA) $(INSTALL_LIBDIR)
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) $(INSTALL_LIBDIR)
if test -d $(INSTALL_MANODIR); then : ; else $(MKDIR) $(INSTALL_MANODIR); fi
if test -d stdlib_man; then $(CP) stdlib_man/* $(INSTALL_MANODIR); else : ; fi
if test -d "$(INSTALL_BINDIR)"; then : ; else $(MKDIR) "$(INSTALL_BINDIR)"; fi
if test -d "$(INSTALL_LIBDIR)"; then : ; else $(MKDIR) "$(INSTALL_LIBDIR)"; fi
if test -d "$(INSTALL_CUSTOMDIR)"; then : ; else $(MKDIR) "$(INSTALL_CUSTOMDIR)"; fi
$(CP) $(OCAMLDOC) "$(INSTALL_BINDIR)/$(OCAMLDOC)$(EXE)"
$(CP) ocamldoc.hva *.cmi $(OCAMLDOC_LIBCMA) "$(INSTALL_LIBDIR)"
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) "$(INSTALL_LIBDIR)"
if test -d "$(INSTALL_MANODIR)"; then : ; else $(MKDIR) "$(INSTALL_MANODIR)"; fi
if test -d stdlib_man; then $(CP) stdlib_man/* "$(INSTALL_MANODIR)"; else : ; fi
installopt:
if test -f $(OCAMLDOC_OPT); then $(MAKE) installopt_really ; fi
installopt_really:
if test -d $(INSTALL_BINDIR); then : ; else $(MKDIR) $(INSTALL_BINDIR); fi
if test -d $(INSTALL_LIBDIR); then : ; else $(MKDIR) $(INSTALL_LIBDIR); fi
$(CP) $(OCAMLDOC_OPT) $(INSTALL_BINDIR)/$(OCAMLDOC_OPT)$(EXE)
$(CP) ocamldoc.hva *.cmx $(OCAMLDOC_LIBA) $(OCAMLDOC_LIBCMXA) $(INSTALL_LIBDIR)
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) $(INSTALL_LIBDIR)
if test -d "$(INSTALL_BINDIR)"; then : ; else $(MKDIR) "$(INSTALL_BINDIR)"; fi
if test -d "$(INSTALL_LIBDIR)"; then : ; else $(MKDIR) "$(INSTALL_LIBDIR)"; fi
$(CP) $(OCAMLDOC_OPT) "$(INSTALL_BINDIR)/$(OCAMLDOC_OPT)$(EXE)"
$(CP) ocamldoc.hva *.cmx $(OCAMLDOC_LIBA) $(OCAMLDOC_LIBCMXA) "$(INSTALL_LIBDIR)"
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) "$(INSTALL_LIBDIR)"
# Testing :
###########

View File

@ -210,21 +210,22 @@ odoc_see_lexer.ml: odoc_see_lexer.mll
# Installation targets
######################
install: dummy
$(MKDIR) -p $(INSTALL_BINDIR)
$(MKDIR) -p $(INSTALL_LIBDIR)
$(CP) $(OCAMLDOC) $(INSTALL_BINDIR)/$(OCAMLDOC)$(EXE)
$(CP) ocamldoc.hva *.cmi $(OCAMLDOC_LIBCMA) $(INSTALL_LIBDIR)
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) $(INSTALL_LIBDIR)
$(MKDIR) -p "$(INSTALL_BINDIR)"
$(MKDIR) -p "$(INSTALL_LIBDIR)"
$(CP) $(OCAMLDOC) "$(INSTALL_BINDIR)/$(OCAMLDOC)$(EXE)"
$(CP) ocamldoc.hva *.cmi $(OCAMLDOC_LIBCMA) "$(INSTALL_LIBDIR)"
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) "$(INSTALL_LIBDIR)"
installopt:
if test -f $(OCAMLDOC_OPT); then $(MAKEREC) installopt_really; fi
installopt_really:
$(MKDIR) -p $(INSTALL_BINDIR)
$(MKDIR) -p $(INSTALL_LIBDIR)
$(CP) $(OCAMLDOC_OPT) $(INSTALL_BINDIR)/$(OCAMLDOC_OPT)$(EXE)
$(CP) ocamldoc.hva $(OCAMLDOC_LIBA) $(OCAMLDOC_LIBCMXA) $(INSTALL_LIBDIR)
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) $(INSTALL_LIBDIR)
$(MKDIR) -p "$(INSTALL_BINDIR)"
$(MKDIR) -p "$(INSTALL_LIBDIR)"
$(CP) $(OCAMLDOC_OPT) "$(INSTALL_BINDIR)/$(OCAMLDOC_OPT)$(EXE)"
$(CP) ocamldoc.hva $(OCAMLDOC_LIBA) $(OCAMLDOC_LIBCMXA) \
"$(INSTALL_LIBDIR)"
$(CP) $(INSTALL_MLIS) $(INSTALL_CMIS) "$(INSTALL_LIBDIR)"
# backup, clean and depend :

View File

@ -62,16 +62,18 @@ INSTALL_STUBLIBDIR=$(DESTDIR)$(STUBLIBDIR)
install::
if test -f dll$(CLIBNAME)$(EXT_DLL); then \
cp dll$(CLIBNAME)$(EXT_DLL) $(INSTALL_STUBLIBDIR)/; fi
cp lib$(CLIBNAME).$(A) $(INSTALL_LIBDIR)/
cd $(INSTALL_LIBDIR); $(RANLIB) lib$(CLIBNAME).$(A)
cp $(LIBNAME).cma $(CMIFILES) $(CMIFILES:.cmi=.mli) $(INSTALL_LIBDIR)/
if test -n "$(HEADERS)"; then cp $(HEADERS) $(INSTALL_LIBDIR)/caml/; fi
cp dll$(CLIBNAME)$(EXT_DLL) "$(INSTALL_STUBLIBDIR)/"; fi
cp lib$(CLIBNAME).$(A) "$(INSTALL_LIBDIR)/"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) lib$(CLIBNAME).$(A)
cp $(LIBNAME).cma $(CMIFILES) $(CMIFILES:.cmi=.mli) "$(INSTALL_LIBDIR)/"
if test -n "$(HEADERS)"; then \
cp $(HEADERS) "$(INSTALL_LIBDIR)/caml/"; fi
installopt:
cp $(CAMLOBJS_NAT) $(LIBNAME).cmxa $(LIBNAME).$(A) $(INSTALL_LIBDIR)/
cd $(INSTALL_LIBDIR); $(RANLIB) $(LIBNAME).a
if test -f $(LIBNAME).cmxs; then cp $(LIBNAME).cmxs $(INSTALL_LIBDIR)/; fi
cp $(CAMLOBJS_NAT) $(LIBNAME).cmxa $(LIBNAME).$(A) "$(INSTALL_LIBDIR)/"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) $(LIBNAME).a
if test -f $(LIBNAME).cmxs; then \
cp $(LIBNAME).cmxs "$(INSTALL_LIBDIR)/"; fi
partialclean:
rm -f *.cm*

View File

@ -81,13 +81,13 @@ extract_crc: dynlink.cma extract_crc.cmo
INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
install:
cp dynlink.cmi dynlink.cma dynlink.mli $(INSTALL_LIBDIR)
cp extract_crc $(INSTALL_LIBDIR)/extract_crc$(EXE)
cp dynlink.cmi dynlink.cma dynlink.mli "$(INSTALL_LIBDIR)"
cp extract_crc "$(INSTALL_LIBDIR)/extract_crc$(EXE)"
installopt:
if $(NATDYNLINK); then \
cp $(NATOBJS) dynlink.cmxa dynlink.$(A) $(INSTALL_LIBDIR) && \
cd $(INSTALL_LIBDIR) && $(RANLIB) dynlink.$(A); \
cp $(NATOBJS) dynlink.cmxa dynlink.$(A) "$(INSTALL_LIBDIR)" && \
cd "$(INSTALL_LIBDIR)" && $(RANLIB) dynlink.$(A); \
fi
partialclean:

View File

@ -78,17 +78,18 @@ INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
INSTALL_STUBLIBDIR=$(DESTDIR)$(STUBLIBDIR)
install:
cp dllthreads.dll $(INSTALL_STUBLIBDIR)/dllthreads.dll
cp libthreads.$(A) $(INSTALL_LIBDIR)/libthreads.$(A)
mkdir -p $(INSTALL_LIBDIR)/threads
cp $(CMIFILES) threads.cma $(INSTALL_LIBDIR)/threads
rm -f $(INSTALL_LIBDIR)/threads/stdlib.cma
cp threads.h $(INSTALL_LIBDIR)/caml/threads.h
cp dllthreads.dll "$(INSTALL_STUBLIBDIR)/dllthreads.dll"
cp libthreads.$(A) "$(INSTALL_LIBDIR)/libthreads.$(A)"
mkdir -p "$(INSTALL_LIBDIR)/threads"
cp $(CMIFILES) threads.cma "$(INSTALL_LIBDIR)/threads"
rm -f "$(INSTALL_LIBDIR)/threads/stdlib.cma"
cp threads.h "$(INSTALL_LIBDIR)/caml/threads.h"
installopt:
cp libthreadsnat.$(A) $(INSTALL_LIBDIR)/libthreadsnat.$(A)
cp $(THREAD_OBJS:.cmo=.cmx) threads.cmxa threads.$(A) $(INSTALL_LIBDIR)/threads
cp threads.cmxs $(INSTALL_LIBDIR)/threads
cp libthreadsnat.$(A) "$(INSTALL_LIBDIR)/libthreadsnat.$(A)"
cp $(THREAD_OBJS:.cmo=.cmx) threads.cmxa threads.$(A) \
"$(INSTALL_LIBDIR)/threads"
cp threads.cmxs "$(INSTALL_LIBDIR)/threads"
.SUFFIXES: .ml .mli .cmo .cmi .cmx

View File

@ -25,22 +25,23 @@ allopt-prof: stdlib.p.cmxa std_exit.p.cmx
installopt: installopt-default installopt-$(PROFILING)
installopt-default:
cp stdlib.cmxa stdlib.a std_exit.o *.cmx $(INSTALL_LIBDIR)
cd $(INSTALL_LIBDIR); $(RANLIB) stdlib.a
cp stdlib.cmxa stdlib.a std_exit.o *.cmx "$(INSTALL_LIBDIR)"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) stdlib.a
installopt-noprof:
rm -f $(INSTALL_LIBDIR)/stdlib.p.cmxa; \
ln -s stdlib.cmxa $(INSTALL_LIBDIR)/stdlib.p.cmxa
rm -f $(INSTALL_LIBDIR)/stdlib.p.a; \
ln -s stdlib.a $(INSTALL_LIBDIR)/stdlib.p.a
rm -f $(INSTALL_LIBDIR)/std_exit.p.cmx; \
ln -s std_exit.cmx $(INSTALL_LIBDIR)/std_exit.p.cmx
rm -f $(INSTALL_LIBDIR)/std_exit.p.o; \
ln -s std_exit.o $(INSTALL_LIBDIR)/std_exit.p.o
rm -f "$(INSTALL_LIBDIR)/stdlib.p.cmxa"; \
ln -s stdlib.cmxa "$(INSTALL_LIBDIR)/stdlib.p.cmxa"
rm -f "$(INSTALL_LIBDIR)/stdlib.p.a"; \
ln -s stdlib.a "$(INSTALL_LIBDIR)/stdlib.p.a"
rm -f "$(INSTALL_LIBDIR)/std_exit.p.cmx"; \
ln -s std_exit.cmx "$(INSTALL_LIBDIR)/std_exit.p.cmx"
rm -f "$(INSTALL_LIBDIR)/std_exit.p.o"; \
ln -s std_exit.o "$(INSTALL_LIBDIR)/std_exit.p.o"
installopt-prof:
cp stdlib.p.cmxa stdlib.p.a std_exit.p.cmx std_exit.p.o $(INSTALL_LIBDIR)
cd $(INSTALL_LIBDIR); $(RANLIB) stdlib.p.a
cp stdlib.p.cmxa stdlib.p.a std_exit.p.cmx std_exit.p.o \
"$(INSTALL_LIBDIR)"
cd "$(INSTALL_LIBDIR)"; $(RANLIB) stdlib.p.a
stdlib.p.cmxa: $(OBJS:.cmo=.p.cmx)
$(CAMLOPT) -a -o stdlib.p.cmxa $(OBJS:.cmo=.p.cmx)

View File

@ -16,7 +16,7 @@ include Makefile.shared
allopt: stdlib.cmxa std_exit.cmx
installopt:
cp stdlib.cmxa stdlib.$(A) std_exit.$(O) *.cmx $(INSTALL_LIBDIR)
cp stdlib.cmxa stdlib.$(A) std_exit.$(O) *.cmx "$(INSTALL_LIBDIR)"
camlheader target_camlheader camlheader_ur: headernt.c ../config/Makefile
$(BYTECC) $(BYTECCCOMPOPTS) -c -I../byterun \

View File

@ -56,8 +56,8 @@ INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
install::
cp stdlib.cma std_exit.cmo *.cmi *.cmt *.cmti *.mli *.ml \
camlheader_ur \
$(INSTALL_LIBDIR)
cp target_camlheader $(INSTALL_LIBDIR)/camlheader
"$(INSTALL_LIBDIR)"
cp target_camlheader "$(INSTALL_LIBDIR)/camlheader"
ifeq "$(RUNTIMED)" "runtimed"
install::
@ -69,7 +69,6 @@ install::
cp target_camlheaderi $(INSTALL_LIBDIR)
endif
stdlib.cma: $(OBJS)
$(CAMLC) -a -o stdlib.cma $(OBJS)

View File

@ -19,7 +19,7 @@ ocamlmktop: ocamlmktop.tpl ../config/Makefile
chmod +x ocamlmktop
install::
cp ocamlmktop $(INSTALL_BINDIR)
cp ocamlmktop "$(INSTALL_BINDIR)"
clean::
rm -f ocamlmktop

View File

@ -23,7 +23,7 @@ ocamlmktop: $(OCAMLMKTOP)
$(CAMLC) $(LINKFLAGS) -o ocamlmktop $(OCAMLMKTOP_IMPORTS) $(OCAMLMKTOP)
install::
cp ocamlmktop $(INSTALL_BINDIR)/ocamlmktop$(EXE)
cp ocamlmktop "$(INSTALL_BINDIR)/ocamlmktop$(EXE)"
clean::
rm -f ocamlmktop objinfo_helper$(EXE).manifest

View File

@ -60,9 +60,9 @@ INSTALL_BINDIR=$(DESTDIR)$(BINDIR)
INSTALL_LIBDIR=$(DESTDIR)$(LIBDIR)
install::
cp ocamldep $(INSTALL_BINDIR)/ocamldep$(EXE)
if test -f ocamldep.opt; \
then cp ocamldep.opt $(INSTALL_BINDIR)/ocamldep.opt$(EXE); else :; fi
cp ocamldep "$(INSTALL_BINDIR)/ocamldep$(EXE)"
if test -f ocamldep.opt; then \
cp ocamldep.opt "$(INSTALL_BINDIR)/ocamldep.opt$(EXE)"; else :; fi
# The profiler
@ -87,13 +87,13 @@ ocamloptp: ocamloptp.cmo
opt:: profiling.cmx
install::
cp ocamlprof $(INSTALL_BINDIR)/ocamlprof$(EXE)
cp ocamlcp $(INSTALL_BINDIR)/ocamlcp$(EXE)
cp ocamloptp $(INSTALL_BINDIR)/ocamloptp$(EXE)
cp profiling.cmi profiling.cmo $(INSTALL_LIBDIR)
cp ocamlprof "$(INSTALL_BINDIR)/ocamlprof$(EXE)"
cp ocamlcp "$(INSTALL_BINDIR)/ocamlcp$(EXE)"
cp ocamloptp "$(INSTALL_BINDIR)/ocamloptp$(EXE)"
cp profiling.cmi profiling.cmo "$(INSTALL_LIBDIR)"
installopt::
cp profiling.cmx profiling.$(O) $(INSTALL_LIBDIR)
cp profiling.cmx profiling.$(O) "$(INSTALL_LIBDIR)"
clean::
rm -f ocamlprof ocamlcp ocamloptp
@ -105,7 +105,7 @@ ocamlmklib: ocamlmklibconfig.cmo ocamlmklib.cmo
$(CAMLC) $(LINKFLAGS) -o ocamlmklib ocamlmklibconfig.cmo config.cmo ocamlmklib.cmo
install::
cp ocamlmklib $(INSTALL_BINDIR)/ocamlmklib$(EXE)
cp ocamlmklib "$(INSTALL_BINDIR)/ocamlmklib$(EXE)"
clean::
rm -f ocamlmklib
@ -137,7 +137,7 @@ lexer299.ml: lexer299.mll
$(CAMLLEX) lexer299.mll
#install::
# cp ocaml299to3 $(INSTALL_BINDIR)/ocaml299to3$(EXE)
# cp ocaml299to3 "$(INSTALL_BINDIR)/ocaml299to3$(EXE)"
clean::
rm -f ocaml299to3 lexer299.ml
@ -153,7 +153,7 @@ lexer301.ml: lexer301.mll
$(CAMLLEX) lexer301.mll
#install::
# cp scrapelabels $(INSTALL_LIBDIR)
# cp scrapelabels "$(INSTALL_LIBDIR)"
clean::
rm -f scrapelabels lexer301.ml
@ -170,7 +170,7 @@ addlabels: addlabels.cmo
$(ADDLABELS_IMPORTS) addlabels.cmo
#install::
# cp addlabels $(INSTALL_LIBDIR)
# cp addlabels "$(INSTALL_LIBDIR)"
clean::
rm -f addlabels
@ -235,7 +235,7 @@ opnames.ml: ../byterun/caml/instruct.h
unset LC_ALL || : ; \
unset LC_CTYPE || : ; \
unset LC_COLLATE LANG || : ; \
sed -e '/\/\*/d' \
sed -e '/[/][*]/d' \
-e '/^#/d' \
-e 's/enum \(.*\) {/let names_of_\1 = [|/' \
-e 's/.*};$$/ |]/' \
@ -276,8 +276,8 @@ objinfo: objinfo_helper$(EXE) $(OBJINFO)
$(CAMLC) -o objinfo $(OBJINFO)
install::
cp objinfo $(INSTALL_BINDIR)/ocamlobjinfo$(EXE)
cp objinfo_helper$(EXE) $(INSTALL_LIBDIR)/objinfo_helper$(EXE)
cp objinfo "$(INSTALL_BINDIR)/ocamlobjinfo$(EXE)"
cp objinfo_helper$(EXE) "$(INSTALL_LIBDIR)/objinfo_helper$(EXE)"
clean::
rm -f objinfo objinfo_helper$(EXE)