# $Id: Portfile,v 1.11 2005/09/13 21:04:57 gwright Exp $

PortSystem 1.0
name		dillo
version		0.8.5
categories	www
maintainers	gwright@opendarwin.org
platforms	darwin
description	Simple but very fast web browser
long_description	\
		Dillo is a web browser project completely written in C.	\
		Dillo is small: source is less than 365 KB, and the	\
		binary is around 265 KB!				\
									\
		Dillo aims to be a multi-platform browser alternative	\
		that's small, stable, developer-friendly, usable, fast,	\
		and extensible.						\
									\
		Dillo is mainly based on GTK+ (GNOME is NOT required!)	\
		Dillo is a free-SW project in the terms of the GNU	\
		general public license.  Current code uses		\
		gzilla-0.2.2's html-parser, and almost			\
		everything else was rewritten from scratch!.		\
									\
		Dillo is very fast!

#user_notes	Remember to set the DISPLAY environment variable	\
#		to localhost:0.0 if you start dillo from a non-X11	\
#		terminal application.

use_bzip2	yes

homepage	http://www.dillo.org/
master_sites	${homepage}/download/:source \
                ${homepage}/Icons/:icon

distfiles  ${distname}${extract.suffix}:source \
           ProgramIcon48.png:icon
checksums	${distname}${extract.suffix} \
                md5 d0ab7fa1d40b310deb891388604188f8 \
            ProgramIcon48.png \
                md5 2ca5fb738b70051cac592acef3cb56e1
extract.only ${distname}${extract.suffix}              

depends_lib	lib:libjpeg:jpeg lib:libpng:libpng lib:libgtk.1:gtk1
depends_run bin:wget:wget

patchfiles	patch-configure patch-http.c
post-patch {
    reinplace "s|panel_size=medium|panel_size=small|" \
        ${worksrcpath}/dillorc
}

configure.env	CPPFLAGS="-no-cpp-precomp -I${prefix}/include" \
		LDFLAGS="-L${prefix}/lib"

configure.args	--with-jpeg-inc=${prefix}/include \
		--with-jpeg-lib=${prefix}/lib

pre-destroot 	{ system "strip ${worksrcpath}/src/dillo" }
post-destroot {
    xinstall -d ${destroot}${prefix}/share/pixmaps
    xinstall -m 644 ${distpath}/ProgramIcon48.png \
        ${destroot}${prefix}/share/pixmaps/dillo.png
}

