Commit 614a219a authored by bguillaum's avatar bguillaum
Browse files

fix installation procedure (following libcaml-log update)

git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/semagramme/libcaml-grew/trunk@8745 7838e531-6607-4d57-9587-6c381814729c
parent a4a17e03
......@@ -15,14 +15,16 @@ conf: config/configure.ac
cd config && autoconf -o ../configure configure.ac
rm -rf config.status config.log autom4te.cache config/autom4te.cache config/ac_lib_checking.m4
purge_makefile:
@make -C src purge_makefile
@make purge
@make -C config purge
clean:
@make -C src clean
@make cleanup
@make -C src/parser clean
rm -f config.log confdefs.h config.status
purge: clean
rm -f config/Makefile
rm -f config/ac_lib_checking.m4
rm -f Makefile src/Makefile test/Makefile
rm -rf doc
uninstall:
$(OCAMLFIND) remove libgrew > /dev/null
......
VERSION = 0.28
VERSION = 0.28.1
INSTALL_DIR_LIB = @OCAMLLIB@
INSTALL_DIR = @prefix@/bin/
DATA_DIR = @prefix@@datarootdir@/libgrew/
DOC_DIR = @prefix@@datarootdir@/libgrew-doc/
......@@ -11,7 +9,6 @@ OCAMLLIB = @OCAMLLIB@
OCAMLFIND = @OCAMLFIND@
OCAMLLEX = @OCAMLLEX@
MENHIR = @MENHIR@
OCAMLFIND_DIR=`$(OCAMLFIND) printconf destdir`
BYTE_FLAGS = -g -dtypes
OPT_FLAGS = -g -dtypes
......@@ -38,34 +35,24 @@ ANSITERMINAL_DIR = @ANSITERMINAL_INCLUDE@
ANSITERMINAL_BYTE = $(ANSITERMINAL_DIR) ANSITerminal.cma
ANSITERMINAL_OPT = $(ANSITERMINAL_DIR) ANSITerminal.cmxa
cleanup:
rm -rf *.cmo *.cmx *.cmi *.annot *.o *.*~
purge:
rm -rf Makefile
infos:
@echo ""
@echo "version -> " $(VERSION)
@echo "VERSION -> " $(VERSION)
@echo ""
@echo "prefix -> " @prefix@
@echo "exec install dir -> " $(INSTALL_DIR)
@echo "lib install dir -> " $(INSTALL_DIR_LIB)
@echo "data install dir -> " $(DATA_DIR)
@echo "doc install dir -> " $(DOC_DIR)
@echo "DATA_DIR -> " $(DATA_DIR)
@echo "DOC_DIR -> " $(DOC_DIR)
@echo ""
@echo "OCAMLC -> " $(OCAMLC)
@echo "OCAMLOPT -> " $(OCAMLOPT)
@echo "OCAMLLIB -> " $(OCAMLLIB)
@echo "OCAMLFIND -> " $(OCAMLFIND)
@echo "byte compil flags -> " $(BYTE_FLAGS)
@echo "native compil flags -> " $(OPT_FLAGS)
@echo "BYTE_FLAGS -> " $(BYTE_FLAGS)
@echo "OPT_FLAGS -> " $(OPT_FLAGS)
@echo ""
@echo "log -> " $(LOG_OPT)
@echo "dep2pict -> " $(DEP2PICT_OPT)
@echo "ansiterminal -> " $(ANSITERMINAL_OPT)
@echo "LOG_OPT -> " $(LOG_OPT)
@echo "DEP2PICT_OPT -> " $(DEP2PICT_OPT)
@echo "ANSITERMINAL_OPT -> " $(ANSITERMINAL_OPT)
@echo ""
@echo "DEBUG -> " $(DEBUG)
@echo "WARNING -> " $(WARNING)
......
......@@ -22,34 +22,8 @@ PARSER_CMX = $(PARSER_DEP:%=%.cmx)
all: grew_base.cmx grew_ast.cmx parser grew test
byte: grew_base.cmo grew_ast.cmo parser.byte grew.byte test.byte
include ../config/Makefile
#executables
grew.byte: parser/parser_global.cmo parser_byte parser/grew_parser.cmo $(FILES_CMO) grew.ml
$(OCAMLC) $(BYTE_FLAGS) -o grew.byte $(XML_LIGHT_BYTE) $(ANSITERMINAL_BYTE) $(LOG_BYTE) \
$(FILES_CMO) -I parser $(PARSER_CMO) \
grew.ml
grew: parser/parser_global.cmx parser_opt parser/grew_parser.cmx $(FILES_CMX) grew.ml
$(OCAMLOPT) $(OPT_FLAGS) -o grew str.cmxa unix.cmxa $(XML_LIGHT_OPT) $(ANSITERMINAL_OPT) $(LOG_OPT) \
$(FILES_CMX) -I parser $(PARSER_CMX) \
grew.ml
test.byte: parser/parser_global.cmo parser_byte parser/grew_parser.cmo $(FILES_CMO) $(FILES_CMI) test.ml
$(OCAMLC) $(BYTE_FLAGS) -o test.byte $(XML_LIGHT_BYTE) $(ANSITERMINAL_BYTE) $(LOG_BYTE) \
$(FILES_CMO) -I parser $(PARSER_CMO) \
test.ml
test: parser/parser_global.cmx parser_opt parser/grew_parser.cmx $(FILES_CMX) $(FILES_CMI) test.ml
$(OCAMLOPT) $(OPT_FLAGS) -o test str.cmxa unix.cmxa $(XML_LIGHT_OPT) $(ANSITERMINAL_OPT) $(LOG_OPT) \
$(FILES_CMX) -I parser $(PARSER_CMX) \
test.ml
#parser
parser_opt:
@make -C parser
......@@ -76,22 +50,22 @@ libgrew.mli : libgrew_types.mli libgrew_.mli
libgrew.cma : $(FILES_CMO) parser_byte libgrew.mli libgrew.ml
ifeq (@DEP2PICT@,no)
$(OCAMLC) -c -pp 'camlp4o pa_macro.cmo' $(BYTE_FLAGS) $(FILES_CMO) $(XML_LIGHT_BYTE) str.cma -I parser $(PARSER_CMO) libgrew.mli
$(OCAMLC) -a -o libgrew.cma $(BYTE_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\"' -linkall -I parser $(PRE_FILES_CMO) $(PARSER_CMO) $(POST_FILES_CMO) libgrew.ml
$(OCAMLC) -a -o libgrew.cma $(BYTE_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\"' -linkall -I parser $(LOG_DIR) $(PRE_FILES_CMO) $(PARSER_CMO) $(POST_FILES_CMO) libgrew.ml
else
$(OCAMLC) -c -pp 'camlp4o pa_macro.cmo -DDEP2PICT' $(BYTE_FLAGS) $(FILES_CMO) $(XML_LIGHT_BYTE) str.cma -I parser $(PARSER_CMO) libgrew.mli
$(OCAMLC) -a -o libgrew.cma $(BYTE_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\" -DDEP2PICT' -linkall -I parser $(PRE_FILES_CMO) $(PARSER_CMO) $(POST_FILES_CMO) libgrew.ml
$(OCAMLC) -a -o libgrew.cma $(BYTE_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\" -DDEP2PICT' -linkall -I parser $(LOG_DIR) $(DEP2PICT_DIR) $(PRE_FILES_CMO) $(PARSER_CMO) $(POST_FILES_CMO) libgrew.ml
endif
libgrew.cmxa : $(FILES_CMX) parser_opt libgrew.mli libgrew.ml
ifeq (@DEP2PICT@,no)
$(OCAMLOPT) -c -pp 'camlp4o pa_macro.cmo' $(OPT_FLAGS) $(FILES_CMX) $(XML_LIGHT_OPT) str.cmxa -I parser $(PARSER_CMX) libgrew.mli
$(OCAMLOPT) -a -o libgrew.cmxa $(OPT_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\"' -linkall -I parser $(PRE_FILES_CMX) $(PARSER_CMX) $(POST_FILES_CMX) libgrew.ml
$(OCAMLOPT) -c -pp 'camlp4o pa_macro.cmo' $(OPT_FLAGS) $(FILES_CMX) $(LOG_OPT) $(XML_LIGHT_OPT) str.cmxa -I parser $(PARSER_CMX) libgrew.mli
$(OCAMLOPT) -a -o libgrew.cmxa $(OPT_FLAGS) -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\"' -linkall -I parser $(LOG_DIR) $(PRE_FILES_CMX) $(PARSER_CMX) $(POST_FILES_CMX) libgrew.ml
else
$(OCAMLOPT) -c -pp 'camlp4o pa_macro.cmo -DDEP2PICT' $(FILES_CMX) $(XML_LIGHT_OPT) str.cmxa -I parser $(PARSER_CMX) libgrew.mli
$(OCAMLOPT) -a -o libgrew.cmxa -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\" -DDEP2PICT' -linkall -I parser $(PRE_FILES_CMX) $(PARSER_CMX) $(POST_FILES_CMX) libgrew.ml
$(OCAMLOPT) -a -o libgrew.cmxa -pp 'camlp4o pa_macro.cmo -DDATA_DIR=\"$(DATA_DIR)\" -DDEP2PICT' -linkall -I parser $(LOG_DIR) $(DEP2PICT_DIR) $(PRE_FILES_CMX) $(PARSER_CMX) $(POST_FILES_CMX) libgrew.ml
endif
DEPENDS_DIR= -I parser
DEPENDS_DIR= -I parser $(LOG_DIR)
###### grew_base.ml ##############################################################
GREW_UTILS_DEP =
......
......@@ -25,10 +25,10 @@ lexer.ml: lexer.mll
ocamllex lexer.mll
lexer.cmx: gr_grs_parser.cmx lexer.ml ../grew_ast.cmx
$(OCAMLOPT) -c $(OPT_FLAGS) -I .. grew_ast.cmx lexer.ml
$(OCAMLOPT) -c $(OPT_FLAGS) -I .. $(LOG_DIR) grew_ast.cmx lexer.ml
lexer.cmo: gr_grs_parser.cmo lexer.ml ../grew_ast.cmo
$(OCAMLC) -c $(BYTE_FLAGS) -I .. grew_ast.cmo lexer.ml
$(OCAMLC) -c $(BYTE_FLAGS) -I .. $(LOG_DIR) grew_ast.cmo lexer.ml
grew_parser.cmx: gr_grs_parser.cmx lexer.cmx grew_parser.ml ../grew_ast.cmx
$(OCAMLOPT) -c $(OPT_FLAGS) -I .. grew_ast.cmx grew_parser.ml
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment