--- /dev/null
+# makefile for configuring lablGTK
+
+# Default compilers
+CAMLC = ocamlc
+CAMLOPT = ocamlopt
+
+# Default installation directories
+BINDIR = `$(GETBINDIR)`
+INSTALLDIR = $(LIBDIR)/lablgtk
+
+# Autoconf
+GETLIBDIR = ocamlc -v | grep "^Standard" | sed 's/^.*: *//'
+LIBDIR = `$(GETLIBDIR)`
+GETBINDIR = $(GETLIBDIR) | sed -e 's|/lib/[^/]*$$|/bin|' -e 's|/lib$$|/bin|'
+GETRANLIB = which ranlib 2>/dev/null | sed -e 's|.*/ranlib$$|!|' -e 's/^[^!]*$$/:/' -e 's/!/ranlib/'
+
+ifdef USE_GNOME
+GTKGETCFLAGS = gtk-config --cflags`" -I"`gnome-config --includedir
+GNOMELIBS = `gnome-config --libs gtkxmhtml`
+else
+GTKGETCFLAGS = gtk-config --cflags
+endif
+
+GTKGETLIBS = gtk-config --libs
+
+configure: .depend config.make
+
+.depend:
+ ocamldep *.ml *.mli > .depend
+
+config.make:
+ @echo CAMLC=$(CAMLC) > config.make
+ @echo CAMLOPT=$(CAMLOPT) >> config.make
+ @echo USE_GL=$(USE_GL) >> config.make
+ @echo USE_GNOME=$(USE_GNOME) >> config.make
+ @echo USE_CC=$(USE_CC) >> config.make
+ @echo DEBUG=$(DEBUG) >> config.make
+ @echo CC=$(CC) >> config.make
+ @echo RANLIB=`$(GETRANLIB)` >> config.make
+ @echo LIBDIR=$(LIBDIR) >> config.make
+ @echo BINDIR=`$(GETBINDIR)` >> config.make
+ @echo INSTALLDIR=$(INSTALLDIR) >> config.make
+ @echo GTKCFLAGS=`$(GTKGETCFLAGS)` >> config.make
+ @echo GTKLIBS=`$(GTKGETLIBS)` | \
+ sed -e 's/-l/-cclib &/g' -e 's/-[LRWr][^ ]*/-ccopt &/g' \
+ >> config.make
+ @echo GNOMELIBS=$(GNOMELIBS) | \
+ sed -e 's/-l/-cclib &/g' -e 's/-[LRWr][^ ]*/-ccopt &/g' \
+ >> config.make
+ cat config.make
--- /dev/null
+Index: Makefile
+===================================================================
+RCS file: /staff2/garrigue/repos/lablGL/Makefile,v
+retrieving revision 1.33
+retrieving revision 1.34
+diff -c -r1.33 -r1.34
+*** Makefile 1998/09/17 03:16:06 1.33
+--- Makefile 1999/06/18 07:39:08 1.34
+***************
+*** 12,22 ****
+ OTHERLIBS=-L$(LABLTKDIR) -llabltk41 $(LIBS)
+
+ # Files
+! MLOBJS = raw.cmo togl.cmo \
+ gl.cmo glLight.cmo glList.cmo glMap.cmo \
+ glMat.cmo glMisc.cmo glPix.cmo glClear.cmo \
+ glTex.cmo glDraw.cmo glFunc.cmo gluMisc.cmo \
+ gluNurbs.cmo gluQuadric.cmo gluTess.cmo gluMat.cmo
+ OPTOBJS = $(MLOBJS:.cmo=.cmx)
+ COBJS = ml_gl.o ml_glu.o ml_togl.o ml_raw.o \
+ $(TOGLDIR)/togl.o
+--- 12,23 ----
+ OTHERLIBS=-L$(LABLTKDIR) -llabltk41 $(LIBS)
+
+ # Files
+! LIBOBJS = raw.cmo \
+ gl.cmo glLight.cmo glList.cmo glMap.cmo \
+ glMat.cmo glMisc.cmo glPix.cmo glClear.cmo \
+ glTex.cmo glDraw.cmo glFunc.cmo gluMisc.cmo \
+ gluNurbs.cmo gluQuadric.cmo gluTess.cmo gluMat.cmo
++ MLOBJS = $(LIBOBJS) togl.cmo
+ OPTOBJS = $(MLOBJS:.cmo=.cmx)
+ COBJS = ml_gl.o ml_glu.o ml_togl.o ml_raw.o \
+ $(TOGLDIR)/togl.o
+***************
+*** 53,60 ****
+ var2switch: var2switch.cmo
+ $(LINKER) var2switch.cmo -o $@
+
+! lablgl.cma: $(MLOBJS)
+! $(LIBRARIAN) -o lablgl.cma $(MLOBJS)
+
+ lablgl.cmxa: $(OPTOBJS)
+ $(OPTLIB) -o lablgl.cmxa $(OPTOBJS)
+--- 54,61 ----
+ var2switch: var2switch.cmo
+ $(LINKER) var2switch.cmo -o $@
+
+! lablgl.cma: $(LIBOBJS)
+! $(LIBRARIAN) -o lablgl.cma $(LIBOBJS)
+
+ lablgl.cmxa: $(OPTOBJS)
+ $(OPTLIB) -o lablgl.cmxa $(OPTOBJS)
+***************
+*** 66,74 ****
+ $(TOGLDIR)/togl.o:
+ cd $(TOGLDIR) && $(MAKE) togl.o
+
+! lablgltop: lablgl.cma liblablgl.a
+ olablmktop $(OLABLINC) -custom -o lablgltop \
+! unix.cma tk41.cma lablgl.cma \
+ -cclib "-L. -llablgl -lunix $(OTHERLIBS)"
+
+ lablgl: lablgl.in Makefile.config
+--- 67,75 ----
+ $(TOGLDIR)/togl.o:
+ cd $(TOGLDIR) && $(MAKE) togl.o
+
+! lablgltop: lablgl.cma togl.cmo liblablgl.a
+ olablmktop $(OLABLINC) -custom -o lablgltop \
+! unix.cma tk41.cma lablgl.cma togl.cmo \
+ -cclib "-L. -llablgl -lunix $(OTHERLIBS)"
+
+ lablgl: lablgl.in Makefile.config
+***************
+*** 107,113 ****
+ if test -d $(INSTALLDIR); then : ; else mkdir -p $(INSTALLDIR); fi
+ cp $(MLOBJS:.cmo=.cmi) $(INSTALLDIR)
+ cp $(MLOBJS:.cmo=.mli) $(INSTALLDIR)
+! cp lablgl.cma liblablgl.a $(INSTALLDIR)
+ cp lablgltop $(INSTALLDIR)
+ cp lablgl lablgllink $(BINDIR)
+ if test -f lablgl.cmxa; then : ; \
+--- 108,114 ----
+ if test -d $(INSTALLDIR); then : ; else mkdir -p $(INSTALLDIR); fi
+ cp $(MLOBJS:.cmo=.cmi) $(INSTALLDIR)
+ cp $(MLOBJS:.cmo=.mli) $(INSTALLDIR)
+! cp lablgl.cma togl.cmo liblablgl.a $(INSTALLDIR)
+ cp lablgltop $(INSTALLDIR)
+ cp lablgl lablgllink $(BINDIR)
+ if test -f lablgl.cmxa; then : ; \
+Index: lablgllink.in
+===================================================================
+RCS file: /staff2/garrigue/repos/lablGL/lablgllink.in,v
+retrieving revision 1.2
+retrieving revision 1.3
+diff -c -r1.2 -r1.3
+*** lablgllink.in 1998/09/16 10:26:17 1.2
+--- lablgllink.in 1999/06/18 07:39:09 1.3
+***************
+*** 1,5 ****
+ #!/bin/sh
+
+ exec olablc -custom @INCLUDES@ -I @INSTALLDIR@ \
+! tk41.cma lablgl.cma $* -cclib "-L@INSTALLDIR@ -llablgl" \
+ -cclib "@OTHERLIBS@"
+--- 1,5 ----
+ #!/bin/sh
+
+ exec olablc -custom @INCLUDES@ -I @INSTALLDIR@ \
+! tk41.cma lablgl.cma togl.cmo $* -cclib "-L@INSTALLDIR@ -llablgl" \
+ -cclib "@OTHERLIBS@"