Index: Makefile.am
===================================================================
--- Makefile.am	(revision 542)
+++ Makefile.am	(revision 542)
@@ -0,0 +1,8 @@
+SUBDIRS = src doc
+
+docs:
+	@cd doc \
+	&& $(MAKE) $(AM_MAKEFLAGS) clean \
+	&& $(MAKE) $(AM_MAKEFLAGS) all
+
+.PHONY: docs
Index: bootstrap
===================================================================
--- bootstrap	(revision 542)
+++ bootstrap	(revision 542)
@@ -0,0 +1,4 @@
+#! /bin/sh
+aclocal-1.7 \
+&& automake-1.7 --gnu --add-missing \
+&& autoconf
Index: configure.ac
===================================================================
--- configure.ac	(revision 542)
+++ configure.ac	(revision 542)
@@ -0,0 +1,29 @@
+dnl Process this file with autoconf to produce a configure script.
+AC_INIT([HugoLib], [0.1], [etik-ol@cs.elte.hu], [hugo])
+AC_CONFIG_AUX_DIR([config])
+AM_INIT_AUTOMAKE(1.7)
+AC_CONFIG_SRCDIR([src/hugo/invalid.h])
+AC_PREREQ(2.57)
+
+dnl Checks for programs.
+AC_PROG_CC
+AC_PROG_CXX
+
+dnl Checks for libraries.
+
+dnl Checks for header files.
+AC_CHECK_HEADERS(limits.h sys/time.h unistd.h)
+
+dnl Checks for typedefs, structures, and compiler characteristics.
+AC_C_CONST
+AC_C_INLINE
+AC_TYPE_SIZE_T
+AC_HEADER_TIME
+AC_STRUCT_TM
+
+dnl Checks for library functions.
+AC_HEADER_STDC
+AC_CHECK_FUNCS(gettimeofday)
+
+AC_CONFIG_FILES([Makefile doc/Makefile src/Makefile src/hugo/Makefile src/test/Makefile])
+AC_OUTPUT
Index: doc/Doxyfile
===================================================================
--- doc/Doxyfile	(revision 508)
+++ doc/Doxyfile	(revision 542)
@@ -395,6 +395,6 @@
                          maps.dox coding_style.dox \
                          groups.dox \
-                         ../src/include \
-                         ../src/include/skeletons \
+                         ../src/hugo \
+                         ../src/hugo/skeletons \
                          ../src/work/alpar/list_graph.h \
                          ../src/work/athos/minlengthpaths.h \
Index: doc/Makefile.am
===================================================================
--- doc/Makefile.am	(revision 542)
+++ doc/Makefile.am	(revision 542)
@@ -0,0 +1,40 @@
+## TODO: Doxyfile should be generated from Doxyfile.in by configure. This way
+## the value of PROJECT_NAME, PROJRCT_NUMBER, PERL_PATH, etc. could be
+## substituted in configure-time.
+
+htmldir = $(datadir)/doc/@PACKAGE@-@VERSION@/html
+## htmldir = $(pkgdatadir)/doc
+
+EXTRA_DIST = Doxyfile html
+
+all-local: html/index.html
+
+## TODO: 'html/index.html' should depend on the files listed in Doxyfile's
+## INPUT variable.
+html/index.html: Doxyfile
+	-rm -rf html
+	doxygen Doxyfile
+
+## This is needed to make 'make dist' work even if the 'html' subdirectory
+## does not exist.
+html: html/index.html
+
+clean-local:
+	-rm -rf html
+
+install-data-local: html/index.html
+	@$(NORMAL_INSTALL)
+	$(mkinstalldirs) $(DESTDIR)$(htmldir)
+	@dir='$(<D)'; for p in $$dir/*.html $$dir/*.css $$dir/*.png $$dir/*.dot $$dir/*.php $$dir/*.idx ; do \
+	  f="`echo $$p | sed -e 's|^.*/||'`"; \
+	  echo " $(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$f"; \
+	  $(INSTALL_DATA) $$p $(DESTDIR)$(htmldir)/$$f; \
+	done
+
+uninstall-local: html/index.html
+	@$(NORMAL_UNINSTALL)
+	@dir='$(<D)'; for p in $$dir/*.html $$dir/*.css $$dir/*.png $$dir/*.dot $$dir/*.php $$dir/*.idx ; do \
+	  f="`echo $$p | sed -e 's|^.*/||'`"; \
+	  echo " rm -f $(DESTDIR)$(htmldir)/$$f"; \
+	  rm -f $(DESTDIR)$(htmldir)/$$f; \
+	done
Index: c/makefile
===================================================================
--- doc/makefile	(revision 295)
+++ 	(revision )
@@ -1,12 +1,0 @@
-doxy:
-	rm -rf html latex
-	doxygen Doxyfile
-
-texi: etikol.texi flf-graph.texi
-	makeinfo etikol.texi&&makeinfo --html etikol.texi&&texi2pdf etikol.texi
-
-texi-html: etikol.texi flf-graph.texi
-	makeinfo etikol.texi&&makeinfo --html etikol.texi
-
-clean:
-	rm -rf html latex
Index: src/Makefile.am
===================================================================
--- src/Makefile.am	(revision 542)
+++ src/Makefile.am	(revision 542)
@@ -0,0 +1,1 @@
+SUBDIRS = hugo test
Index: src/hugo/Makefile.am
===================================================================
--- src/hugo/Makefile.am	(revision 542)
+++ src/hugo/Makefile.am	(revision 542)
@@ -0,0 +1,12 @@
+pkginclude_HEADERS =							\
+	bin_heap.h							\
+	dijkstra.h							\
+	dimacs.h							\
+	error.h								\
+	fib_heap.h							\
+	invalid.h							\
+	maps.h								\
+	smart_graph.h							\
+	time_measure.h							\
+	unionfind.h							\
+	xy.h
Index: src/hugo/bin_heap.h
===================================================================
--- src/hugo/bin_heap.h	(revision 539)
+++ src/hugo/bin_heap.h	(revision 542)
@@ -59,6 +59,6 @@
 
 
-#ifndef BIN_HEAP_HH
-#define BIN_HEAP_HH
+#ifndef HUGO_BIN_HEAP_H
+#define HUGO_BIN_HEAP_H
 
 ///\ingroup auxdat
Index: src/hugo/dijkstra.h
===================================================================
--- src/hugo/dijkstra.h	(revision 539)
+++ src/hugo/dijkstra.h	(revision 542)
@@ -7,6 +7,6 @@
 ///\brief Dijkstra algorithm.
 
-#include <bin_heap.h>
-#include <invalid.h>
+#include <hugo/bin_heap.h>
+#include <hugo/invalid.h>
 
 namespace hugo {
Index: src/hugo/dimacs.h
===================================================================
--- src/hugo/dimacs.h	(revision 539)
+++ src/hugo/dimacs.h	(revision 542)
@@ -6,5 +6,5 @@
 #include <string>
 #include <vector>
-#include <maps.h>
+#include <hugo/maps.h>
 
 /// \file
Index: src/hugo/skeletons/graph.h
===================================================================
--- src/hugo/skeletons/graph.h	(revision 539)
+++ src/hugo/skeletons/graph.h	(revision 542)
@@ -6,5 +6,5 @@
 ///\brief Declaration of GraphSkeleton.
 
-#include <invalid.h>
+#include <hugo/invalid.h>
 
 /// The namespace of HugoLib
Index: src/hugo/smart_graph.h
===================================================================
--- src/hugo/smart_graph.h	(revision 539)
+++ src/hugo/smart_graph.h	(revision 542)
@@ -11,5 +11,5 @@
 #include <limits.h>
 
-#include "invalid.h"
+#include <hugo/invalid.h>
 
 namespace hugo {
Index: src/hugo/unionfind.h
===================================================================
--- src/hugo/unionfind.h	(revision 539)
+++ src/hugo/unionfind.h	(revision 542)
@@ -13,5 +13,5 @@
 #include <algorithm>
 
-#include <invalid.h>
+#include <hugo/invalid.h>
 
 namespace hugo {
Index: src/test/Makefile.am
===================================================================
--- src/test/Makefile.am	(revision 542)
+++ src/test/Makefile.am	(revision 542)
@@ -0,0 +1,8 @@
+AM_CPPFLAGS = -I$(top_srcdir)/src
+
+check_PROGRAMS = graph_test
+
+TESTS = $(check_PROGRAMS)
+XFAIL_TESTS =
+
+graph_test_SOURCES = graph_test.cc
Index: src/test/dijkstra_heap_test.cc
===================================================================
--- src/test/dijkstra_heap_test.cc	(revision 449)
+++ src/test/dijkstra_heap_test.cc	(revision 542)
@@ -15,10 +15,10 @@
 #include <math.h>
 
-#include <smart_graph.h>
-#include <dimacs.h>
-#include <dijkstra.h>
-#include <time_measure.h>
-#include <bin_heap.h>
-#include <fib_heap.h>
+#include <hugo/smart_graph.h>
+#include <hugo/dimacs.h>
+#include <hugo/dijkstra.h>
+#include <hugo/time_measure.h>
+#include <hugo/bin_heap.h>
+#include <hugo/fib_heap.h>
 
 using namespace hugo;
Index: src/test/error_test.cc
===================================================================
--- src/test/error_test.cc	(revision 489)
+++ src/test/error_test.cc	(revision 542)
@@ -1,5 +1,5 @@
 #include <iostream>
 
-#include <error.h>
+#include <hugo/error.h>
 
 using namespace hugo;
Index: src/test/graph_test.cc
===================================================================
--- src/test/graph_test.cc	(revision 515)
+++ src/test/graph_test.cc	(revision 542)
@@ -1,5 +1,5 @@
 #include<iostream>
-#include<smart_graph.h>
-#include<skeletons/graph.h>
+#include<hugo/smart_graph.h>
+#include<hugo/skeletons/graph.h>
 #include<../work/alpar/list_graph.h>
 
Index: c/test/makefile
===================================================================
--- src/test/makefile	(revision 490)
+++ 	(revision )
@@ -1,26 +1,0 @@
-INCLUDEDIRS ?= -I../include
-CXXFLAGS += -W -Wall -O3 -ansi -pedantic $(INCLUDEDIRS) 
-#LEDAROOT ?= /ledasrc/LEDA-4.1
-
-BINARIES = dijkstra_heap_test unionfind_test error_test
-
-ifdef GCCVER
-CXX := g++-$(GCCVER)
-else
-CXX := $(shell type -p g++-3.3 || type -p g++-3.2 || type -p g++-3.0 || type -p g++-3 || echo g++)
-endif
-
-CC=$(CXX)
-
-all: $(BINARIES)
-
-.depend dep depend:
-	$(CXX) $(INCLUDEDIRS) -M $(BINARIES:=.cc) > .depend
-
-makefile: .depend
-sinclude .depend
-
-clean:
-	$(RM) *.o $(BINARIES) .depend
-
-.PHONY: all clean dep depend
Index: src/test/unionfind_test.cc
===================================================================
--- src/test/unionfind_test.cc	(revision 483)
+++ src/test/unionfind_test.cc	(revision 542)
@@ -1,6 +1,6 @@
 #include <iostream>
 
-#include <maps.h>
-#include <unionfind.h>
+#include <hugo/maps.h>
+#include <hugo/unionfind.h>
 
 using namespace hugo;
Index: src/test/xy_test.cc
===================================================================
--- src/test/xy_test.cc	(revision 518)
+++ src/test/xy_test.cc	(revision 542)
@@ -1,3 +1,3 @@
-#include <xy.h>
+#include <hugo/xy.h>
 #include <iostream>
 using namespace std;
Index: src/work/alpar/list_graph.h
===================================================================
--- src/work/alpar/list_graph.h	(revision 531)
+++ src/work/alpar/list_graph.h	(revision 542)
@@ -11,5 +11,5 @@
 #include <limits.h>
 
-#include "invalid.h"
+#include <hugo/invalid.h>
 
 namespace hugo {
