################################################################### # [LibNN - Neural Networks Library] # http://libnn.org # Copyright (C) 2002 - 2003 LAGACHERIE Matthieu RICORDEAU Olivier # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. This # program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. You should have # received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, # USA. # # SPECIAL NOTE (the beerware clause): # This software is free software. However, it also falls under the beerware # special category. That is, if you find this software useful, or use it # every day, or want to grant us for our modest contribution to the # free software community, feel free to send us a beer from one of # your local brewery. Our preference goes to Belgium abbey beers and # irish stout (Guiness for strength!), but we like to try new stuffs. # # Authors: # LAGACHERIE Matthieu # Paper mail : 7 rue Delescluzes 94280 LE KREMLIN BICETRE, FRANCE # E-mail : matthieu@libnn.org # # RICORDEAU Olivier # Paper mail : 69 avenue d'Italie 75013 PARIS, FRANCE # E-mail : olivier@libnn.org # ################################################################### include ../common.Makefile # main target ############# all: $(BYTE) $(OPT) # Recompiles everything from scratch re: clean all # bytecode and native-code compilation ###################################### NAME = $(ERROR_DIR) # main targets: ML = $(ERROR_ML) MLI = $(ERROR_MLI) CMI = $(MLI:.mli=.cmi) CMO = $(ML:.ml=.cmo) $(BYTE): lib$(NAME).cma $(OPT): $(ERROR_CMX) lib$(NAME).cma: $(CMO) $(OCAMLC) $^ $(BFLAGS) $(BLFLAGS) -o $@ # documentation ############### DOCPATH = ../doc PDF = $(DOCPATH)/lib$(NAME)_code_documentation.pdf PS = $(DOCPATH)/lib$(NAME)_code_documentation.ps LATEX_SHORT = lib$(NAME)_code_documentation.tex LATEX = $(DOCPATH)/$(LATEX_SHORT) DVI_SHORT = lib$(NAME)_code_documentation.dvi DVI = $(DOCPATH)/$(DVI_SHORT) TEXI_SHORT = lib$(NAME)_code_documentation.texi TEXI = $(DOCPATH)/$(TEXI_SHORT) TEXI2HTML = $(DOCPATH)/lib$(NAME)_code_documentation.html $(LATEX): $(ML) $(MLI) $(OCAMLDOC) -o $(LATEX) -latex -t 'lib$(NAME) code documentation' \ $(ML) $(MLI) $(DVI): $(LATEX) cp $(LATEX) $(TMP); \ cd $(TMP); \ latex $(LATEX_SHORT); \ latex $(LATEX_SHORT); \ cd -; \ cp $(TMP)/$(DVI_SHORT) $(DVI) $(PDF): $(DVI) dvipdf $(DVI) $(PDF) $(PS): $(DVI) dvips $(DVI) -o $(PS) $(TEXI): $(ML) $(MLI) $(OCAMLDOC) -texi -o $(TEXI) -t 'lib$(NAME) code documentation' $(ML) \ $(MLI) $(TEXI2HTML): $(TEXI) (cd $(DOCPATH) && \ texi2html -glossary -menu -number $(TEXI_SHORT)) html-generation: $(ML) $(MLI) $(OCAMLDOC) -html -d $(DOCPATH)/html -all-params -colorize-code \ -t 'lib$(NAME) code documentation' $(ML) $(MLI) man-generation: $(ML) $(MLI) $(OCAMLDOC) -man -d $(DOCPATH)/man -man-mini \ -t 'lib$(NAME) code documentation' $(ML) $(MLI) $(OCAMLDOC): man-generation html-generation $(TEXI) $(LATEX) $(LATEX_HERE): $(DVI) $(DVIPDF_HERE): $(PDF) $(DVIPS_HERE): $(PS) $(TEXI2HTML_HERE): $(TEXI2HTML) # 'make doc' generates as much documentation as possibe, depending on latex, # dvips, dvipdf, texi2html and ocamldoc's presence. doc: $(CMO) $(OCAMLDOC) $(LATEX_HERE) $(DVIPS_HERE) $(DVIPDF_HERE) $(TEXI2HTML_HERE) # clean ####### clean:: doc-clean $(RM) *.cm[iox] *.o *~ \#* $(RM) lib$(NAME).cma doc-clean: dist-clean distclean:: clean doc-clean