inherit webapp-apache S=${WORKDIR}/${P} DESCRIPTION="HTTP/HTML indexing and searching system" SRC_URI="http://www.htdig.org/files/${P}.tar.gz" HOMEPAGE="http://www.htdig.org" KEYWORDS="x86 sparc ppc mips amd64" SLOT="0" LICENSE="GPL-2" DEPEND=">=sys-libs/zlib-1.1.3 app-arch/unzip" export CPPFLAGS="${CPPFLAGS} -Wno-deprecated" webapp-detect pkg_setup() { einfo "Installing into ${ROOT}${HTTPD_ROOT}." einfo "Using CGI dir: ${HTTPD_CGIBIN}." } src_compile() { local DocumentRoot=${HTTPD_ROOT} local destdir=${DocumentRoot}/${PN} cd ${S} econf \ --with-config-dir=/etc/${PN} \ --with-cgi-bin-dir=${HTTPD_CGIBIN} \ --with-common-dir=/usr/share/${PN} \ --with-database-dir=/var/${PN}/db \ --with-image-dir=${destdir} \ --with-default-config-file=/etc/${PN}/${PN}.conf emake || die } src_install () { local DocumentRoot=${HTTPD_ROOT} local destdir=${DocumentRoot}/${PN} webapp-pkg_install make \ DESTDIR=${D} \ CONFIG_DIR=${D}/etc/${PN} \ SEARCH_DIR=${D}/${destdir} \ CGIBIN_DIR=${D}/${HTTPD_CGIBIN} \ COMMON_DIR=${D}/usr/share/${PN} \ DATABASE_DIR=${D}/var/${PN}/db \ IMAGE_DIR=${D}/${destdir} \ DEFAULT_CONFIG_FILE=${D}/etc/${PN}/${PN}.conf \ exec_prefix=${D}/usr \ install || die dodoc ChangeLog COPYING README dohtml -r htdoc insinto /etc/conf.d doins installdir/htdig.conf dosed /etc/htdig/htdig.conf dosed /usr/bin/rundig touch ${D}/var/htdig/db/word2root.db touch ${D}/var/htdig/db/root2word.db }