From b81461aaf2af6b62e5bb9ae59e93aaa8a9099f80 Mon Sep 17 00:00:00 2001 From: "valery.isaev@gmail.com" Date: Mon, 30 May 2011 13:28:43 +0000 Subject: [PATCH] autotools git-svn-id: https://projectname.googlecode.com/svn/trunk@21 c416075f-80b4-e980-4839-00ea3ed24e77 --- trunk/Makefile.am | 30 ++++++++++++++++++++++++++++++ trunk/{Makefile => Makefile.dev} | 0 trunk/bootstrap | 7 +++++++ trunk/configure.in | 20 ++++++++++++++++++++ trunk/file.conf | 12 ++++++++++++ trunk/src/file_types/base.cpp | 2 -- trunk/src/file_types/text.cpp | 2 -- trunk/src/file_types/text.h | 1 - trunk/todo.txt | 0 9 files changed, 69 insertions(+), 5 deletions(-) create mode 100644 trunk/Makefile.am rename trunk/{Makefile => Makefile.dev} (100%) create mode 100755 trunk/bootstrap create mode 100644 trunk/configure.in create mode 100644 trunk/file.conf delete mode 100644 trunk/todo.txt diff --git a/trunk/Makefile.am b/trunk/Makefile.am new file mode 100644 index 0000000..521334a --- /dev/null +++ b/trunk/Makefile.am @@ -0,0 +1,30 @@ +bin_PROGRAMS = pn + +pn_SOURCES = \ + src/logger.cpp \ + src/file_types/img.cpp \ + src/file_types/base.cpp \ + src/file_types/text.cpp \ + src/program_options.cpp \ + src/magic_file.cpp \ + src/filesystem.cpp \ + src/default_main.cpp \ + src/main.cpp \ + src/file_typer.cpp \ + src/clusterization.cpp \ + src/logger.h \ + src/file_types/img.h \ + src/file_types/text.h \ + src/file_types/base.h \ + src/kleisli.h \ + src/type_list.h \ + src/program_options.h \ + src/magic_file.h \ + src/comparator.h \ + src/file_types.h \ + src/clusterization.h \ + src/file_typer.h \ + src/filesystem.h + +pn_CXXFLAGS = -I/usr/include/ImageMagick +pn_LDADD = -lMagick++ -lboost_program_options -lboost_filesystem -lboost_system diff --git a/trunk/Makefile b/trunk/Makefile.dev similarity index 100% rename from trunk/Makefile rename to trunk/Makefile.dev diff --git a/trunk/bootstrap b/trunk/bootstrap new file mode 100755 index 0000000..86acb4f --- /dev/null +++ b/trunk/bootstrap @@ -0,0 +1,7 @@ +aclocal +autoconf +autoheader +touch NEWS README AUTHORS ChangeLog +automake --add-missing +./configure +make diff --git a/trunk/configure.in b/trunk/configure.in new file mode 100644 index 0000000..f84a80e --- /dev/null +++ b/trunk/configure.in @@ -0,0 +1,20 @@ +AC_PREREQ([2.68]) +AC_INIT([pn], [0.1], [valery.isaev@gmail.com]) + +AC_CONFIG_SRCDIR([src/main.cpp]) +AC_CONFIG_HEADER(src/config.h) + +AM_INIT_AUTOMAKE([1.9 foreign]) + +AC_PROG_CXX + +AC_CHECK_HEADERS([magic.h]) +AC_CHECK_LIB(magic, magic_file) + +AC_HEADER_STDBOOL +AC_C_INLINE +AC_TYPE_SIZE_T +AC_TYPE_UINT32_T + +AC_CONFIG_FILES([Makefile]) +AC_OUTPUT diff --git a/trunk/file.conf b/trunk/file.conf new file mode 100644 index 0000000..2e010af --- /dev/null +++ b/trunk/file.conf @@ -0,0 +1,12 @@ +[text] +formats = text/plain, .txt +threshold = 2 +words_count = 10 + +[image] +formats = image/jpg, .jpg, image/png, .png +bucket_count = 4 +threshold = 0.005 +precise = no +max_diff = 200000 +img_size = 128 diff --git a/trunk/src/file_types/base.cpp b/trunk/src/file_types/base.cpp index 8e0dfe7..41d7a53 100644 --- a/trunk/src/file_types/base.cpp +++ b/trunk/src/file_types/base.cpp @@ -1,7 +1,5 @@ #include #include -#include -#include #include "base.h" #include "../kleisli.h" diff --git a/trunk/src/file_types/text.cpp b/trunk/src/file_types/text.cpp index c58013e..0e47d8f 100644 --- a/trunk/src/file_types/text.cpp +++ b/trunk/src/file_types/text.cpp @@ -1,7 +1,5 @@ #include #include -#include -#include #include #include "text.h" diff --git a/trunk/src/file_types/text.h b/trunk/src/file_types/text.h index f2901fc..17a32db 100644 --- a/trunk/src/file_types/text.h +++ b/trunk/src/file_types/text.h @@ -1,7 +1,6 @@ #ifndef _FILE_TYPE_TEXT_H_ #define _FILE_TYPE_TEXT_H_ -#include #include #include "base.h" diff --git a/trunk/todo.txt b/trunk/todo.txt deleted file mode 100644 index e69de29..0000000