From: Guillaume Brochu Date: Fri, 28 Dec 2018 14:55:18 -0500 Subject: compile-gui compile gui and tweak makefile accordingly --- Makefile | 6 ++++++ gui/Makefile | 15 +++++---------- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index 54ac39a..29ccbed 100644 --- a/Makefile +++ b/Makefile @@ -18,6 +18,7 @@ out:: cd gwb2ged; $(MAKE) all cd setup; $(MAKE) all cd gwtp; $(MAKE) all + cd gui; $(MAKE) all opt:: cd wserver; $(MAKE) opt @@ -27,6 +28,7 @@ opt:: cd gwb2ged; $(MAKE) opt cd setup; $(MAKE) opt cd gwtp; $(MAKE) opt + cd gui; $(MAKE) opt install: mkdir -p $(PREFIX)/bin @@ -110,6 +112,8 @@ new_distrib: classical_distrib cp setup/lang/*.htm $(DESTDIR)/gw/setup/lang/. cp setup/lang/lexicon.txt $(DESTDIR)/gw/setup/lang/. cp setup/gwsetup $(DESTDIR)/gw/gwsetup$(EXE) + cp gui/gw/gui_lex.txt $(DESTDIR)/gw/. + cp gui/gui $(DESTDIR)/gw/gui$(EXE) cp LICENSE $(DESTDIR)/LICENSE.txt cp etc/START.htm $(DESTDIR)/. cp CHANGES $(DESTDIR)/CHANGES.txt @@ -162,6 +166,7 @@ clean:: cd gwb2ged; $(MAKE) clean cd setup; $(MAKE) clean cd gwtp; $(MAKE) clean + cd gui; $(MAKE) clean $(RM) -rf $(DESTDIR) $(RM) -f *~ .#* @@ -177,3 +182,4 @@ depend: cd gwb2ged; $(MAKE) depend cd setup; $(MAKE) depend cd gwtp; $(MAKE) depend + cd gui; $(MAKE) depend diff --git a/gui/Makefile b/gui/Makefile index eda1316..3f106c6 100644 --- a/gui/Makefile +++ b/gui/Makefile @@ -2,16 +2,12 @@ # Copyright (c) 2006-2007 INRIA include ../tools/Makefile.inc - -LABLGTK2=+lablgtk2 -OCAMLC=ocamlc.opt -OCAMLOPT=ocamlopt.opt -annot +LABLGTK2=`ocamlfind query lablgtk2`/ GWB=.. OBJS=../src/version.cmo ../src/iovalue.cmo ../src/buff.cmo ../src/name.cmo ../src/mutil.cmo gui.cmo OCAMLI=-I ../src -I $(LABLGTK2) -TEST_DIR=test $$(basename "$<") = "$<" || { echo "Please run 'make' in directory '$$(dirname "$<")' first"; exit 1; } -all:: opt +all:: out out:: gui.out $(RM) gui @@ -20,6 +16,7 @@ out:: gui.out opt:: gui.opt $(RM) gui cp gui.opt gui + $(STRIP) gui gui.out: $(OBJS) $(OCAMLC) -I $(LABLGTK2) lablgtk.cma unix.cma $(OBJS) -o gui.out @@ -31,11 +28,9 @@ clean:: $(RM) gui depend: - export LC_ALL=C; TOP=$(GWB) $(GWB)/tools/camlp5_depend.sh $(OCAMLI) $$(ls *.mli *.ml) | sed -e 's|\.\.|$$(GWB)|g' > .depend.new - mv .depend.new .depend + $(ROOT)/tools/camlp5_depend.sh $(CAMLP5F) $(OCAMLI) -- *.ml* > .depend %.cmo: %.ml - @$(TEST_DIR) - ocamlc -pp camlp5r $(OCAMLI) -I +lablgtk2 -c $< + $(OCAMLC) -pp camlp5r $(OCAMLI) -I $(LABLGTK2) -c $< include .depend