# $Id: Portfile,v 1.8 2006/03/07 07:54:05 yves Exp $
PortSystem 1.0
name		galeon
version		2.0.1
description	A GNOME browser.
long_description        Galeon is a GNOME Web browser based on gecko (the \
			mozilla rendering engine). It's fast, it has a \
			light interface, and it is fully standards-compliant.
maintainers	gnome-darwinports@opendarwin.org
categories	gnome
platforms	darwin 
homepage	http://galeon.sourceforge.net
master_sites	sourceforge
use_bzip2	yes
checksums	md5 34d6e3a6ee78f9e4d12736e5d81b462b
#patchfiles	patch_mozilla-embed.cpp patch-MozillaPrivate.cpp
depends_lib     bin:mozilla:mozilla bin:gnome-session:gnome-session lib:libiconv.2:libiconv
configure.env   CPPFLAGS="-L${prefix}/lib -I${prefix}/include" \
                CFLAGS="-no-cpp-precomp -flat_namespace -undefined suppress"
configure.args	--enable-nautilus-view=no --mandir=${prefix}/share/man \
		--with-gconf-source="xml::${destroot}/${prefix}/etc/gconf/gconf.xml.defaults"
pre-destroot {
	# mkdir the directory for teh gconf'in
	file mkdir -f ${destroot}${prefix}/etc/gconf/gconf.xml.defaults/
}

post-destroot {
	# make a da script happen
	file copy ${destroot}${prefix}/bin/galeon ${destroot}${prefix}/bin/galeon-bin
	file copy -force ${filespath}/galeon ${destroot}${prefix}/bin/galeon
	# damn gconf
	file delete ${destroot}${prefix}/etc/gconf/gconf.xml.defaults/schemas/apps/%gconf.xml
	file delete ${destroot}${prefix}/etc/gconf/gconf.xml.defaults/schemas/%gconf.xml
	file delete ${destroot}${prefix}/etc/gconf/gconf.xml.defaults/apps/%gconf.xml
	# use da ${prefix} Luke ...
    reinplace "s|/opt/local|${prefix}|g" ${destroot}/${prefix}/bin/galeon
}
