We will now add our own file directly in the ht://Dig source tree.
First the following should be appended to
BaseDir
/htdig/htsearch/Makefile.am:
ourSearchProgram_SOURCES = DocMatch.cc ResultList.cc ResultMatch.cc \
Template.cc TemplateList.cc WeightWord.cc \
Collection.cc SplitMatches.cc HtURLSeedScore.cc ourSearchProgram.cc
ourSearchProgram_DEPENDENCIES = $(top_builddir)/htfuzzy/libfuzzy.la $(HTLIBS)
ourSearchProgram_LDFLAGS = $(PROFILING) ${extra_ldflags}
ourSearchProgram_LDADD = $(top_builddir)/htfuzzy/libfuzzy.la $(HTLIBS)
and change line 8 in the same file from:
bin_PROGRAMS = htsearch qtest
to:
bin_PROGRAMS = htsearch qtest ourSearchProgram
Copy the files ourSearchProgram.cc
and
ourSearchProgram.h
to
BaseDir
/htdig/htsearch/.
Then execute the following:
$ cd <BaseDir>/htdig $ automake-1.7 $ ./config.status $ make
Then ourSearchProgram should be build. Automake and ./config.status
are run to update the makefiles. This is necessary as we changed
BaseDir
/htdig/htsearch/Makefile.am.