%define contentdir /var/www
Summary: ht://Dig - Web search engine
Name: htdig
Version: 3.2.0
Release: 1.b3.4
Copyright: GPL
Group: Applications/Internet
Source: http://www.htdig.org/files/%{name}-%{version}b3.tar.bz2
Patch: htdig-3.1.5-rh.patch
Patch1: htdig-3.2.0b3-glibc222.patch
BuildRoot: %{_tmppath}/%{name}-root
Url: http://www.htdig.org/
BuildRequires: flex >= 2.5.4a-13
Prefix: %{_prefix}
%package web
Summary: Scripts and HTML code needed for using ht://Dig as a web search engine
Group: Applications/Internet
Requires: %{name} = %{version}
%description
The ht://Dig system is a complete world wide web indexing and searching
system for a small domain or intranet. This system is not meant to replace
the need for powerful internet-wide search systems like Lycos, Infoseek,
Webcrawler and AltaVista. Instead it is meant to cover the search needs for
a single company, campus, or even a particular sub section of a web site. As
opposed to some WAIS-based or web-server based search engines, ht://Dig can
span several web servers at a site. The type of these different web servers
doesn't matter as long as they understand the HTTP 1.0 protocol.
ht://Dig is also used by KDE to search KDE's HTML documentation.
ht://Dig was developed at San Diego State University as a way to search the
various web servers on the campus network.
%description web
The ht://Dig system is a complete world wide web indexing and searching
system for a small domain or intranet. This system is not meant to replace
the need for powerful internet-wide search systems like Lycos, Infoseek,
Webcrawler and AltaVista. Instead it is meant to cover the search needs for
a single company, campus, or even a particular sub section of a web site. As
opposed to some WAIS-based or web-server based search engines, ht://Dig can
span several web servers at a site. The type of these different web servers
doesn't matter as long as they understand the HTTP 1.0 protocol.
The %{name}-web package includes CGI scripts and HTML code needed to use
ht://Dig on a website.
ht://Dig was developed at San Diego State University as a way to search the
various web servers on the campus network.
%prep
%setup -q -n htdig-%{version}b3
%patch -p1 -b .rh
%patch1 -p1 -b .glibc222
# Fix the flex output file for glibc 2.2 compatibility
cd htcommon
flex -oconf_lexer.cxx conf_lexer.lxx
cd ..
autoconf
%build
%configure \
--enable-shared \
--with-config-dir=%{_sysconfdir} \
--with-common-dir=%{contentdir}/html/htdig \
--with-database-dir=/var/lib/htdig \
--localstatedir=/var/lib/htdig \
--with-cgi-bin-dir=%{contentdir}/cgi-bin \
--with-image-dir=%{contentdir}/html/htdig \
--with-search-dir=%{contentdir}/html/htdig \
--with-default-config-file=/etc/htdig.conf \
--with-apache=/usr/sbin/httpd
make
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
strip -R .comment $RPM_BUILD_ROOT%{contentdir}/cgi-bin/* || :
strip -R .comment $RPM_BUILD_ROOT%{_bindir}/* || :
ln $RPM_BUILD_ROOT%{contentdir}/cgi-bin/htsearch $RPM_BUILD_ROOT%{_bindir}
chmod 644 $RPM_BUILD_ROOT%{contentdir}/html/htdig/*
ln -sf search.html $RPM_BUILD_ROOT%{contentdir}/html/htdig/index.html
# now get rid of the $RPM_BUILD_ROOT paths in the conf files
for i in /etc/htdig.conf /usr/bin/rundig ; do
perl -pi -e "s|$RPM_BUILD_ROOT||g" $RPM_BUILD_ROOT/$i
done
mkdir -p $RPM_BUILD_ROOT%{prefix}/share
mv $RPM_BUILD_ROOT%{contentdir}/html/htdig $RPM_BUILD_ROOT%{prefix}/share
ln -sf ../../../usr/share/htdig $RPM_BUILD_ROOT%{contentdir}/html/htdig
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%doc htdoc/*
%config /etc/htdig.conf
%dir /var/lib/htdig
%{_bindir}/*
%{_libdir}/*
%dir %{prefix}/share/htdig
%{prefix}/share/htdig/*
%files web
%defattr(-,root,root)
%{contentdir}/html/htdig
%{contentdir}/cgi-bin/*
%changelog
* Fri Apr 27 2001 Bill Nottingham <notting@redhat.com>
- rebuild for C++ exception handling on ia64
* Wed Mar 21 2001 Bernhard Rosenkraenzer <bero@redhat.com> 3.2.0-0.b3.4
- move pictures etc. to base package and to a directory outside of
/var/www - The current KDevelop search function doesn't work without
them.
* Mon Mar 5 2001 Bernhard Rosenkraenzer <bero@redhat.com>
- Add htsearch to the base package, kdevelop needs it
* Wed Jan 10 2001 Bernhard Rosenkraenzer <bero@redhat.com>
- Move the web related files to a separate package
* Tue Oct 3 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- 3.2.0b2
- fix build with glibc 2.2 and gcc 2.96
* Sat Aug 19 2000 Nalin Dahyabhai <nalin@redhat.com>
- fix syntax error introduced in our patch (#16598)
* Tue Aug 1 2000 Tim Powers <timp@redhat.com>
- fixed group to be a valid one
* Mon Jul 24 2000 Prospector <prospector@redhat.com>
- rebuilt
* Wed Jul 19 2000 Nalin Dahyabhai <nalin@redhat.com>
- rebuild for Power Tools
* Thu Jun 29 2000 Nalin Dahyabhai <nalin@redhat.com>
- rebuild for Power Tools
* Sat Feb 26 2000 Nalin Dahyabhai <nalin@redhat.com>
- 3.1.5
* Wed Jan 12 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- 3.1.4
- fix URL and source location
* Tue Sep 28 1999 Preston Brown <pbrown@redhat.com>
- 3.1.3 for SWS 3.1
* Wed May 05 1999 Preston Brown <pbrown@redhat.com>
- updates for SWS 3.0
* Mon Aug 31 1998 Preston Brown <pbrown@redhat.com>
- Updates for SWS 2.0
* Sat Feb 07 1998 Cristian Gafton <gafton@redhat.com>
- built against glibc
- build all the fuzzy databases before packaging, because it is time
consuming operation and we don't want the user to be impatient