# $Id: Portfile 111503 2013-09-24 04:24:24Z ryandesign@macports.org $

PortSystem 1.0

name		stardict
version		3.0.4
categories	textproc
maintainers	gmail.com:alexandernx
platforms	darwin
license		GPL-3+

description	A full featured gtk2 dictionary
long_description \
	Very nice gnome dictionary. \
	Can handle both local and web dictionaries. \
	Though it needs a handful of gnome libraries for \
	installation.

homepage	http://code.google.com/p/stardict-3/
master_sites	googlecode:stardict-3
use_bzip2	yes

checksums	rmd160  78f20b2092006951f35497b804b176b9c2a15195 \
		sha256  c38b9d953fe0b2380a8aed4c98cb121ad83aff91a32af3c665198d8268b1dce8

depends_build	port:pkgconfig \
		port:intltool \
		port:gnome-doc-utils

depends_lib	path:lib/pkgconfig/glib-2.0.pc:glib2 \
		port:gtk2 \
		port:popt \
		port:p5.12-xml-parser

patchfiles	patch-zlib-1.2.6.diff

# t_lookupdata.cpp:41:30: error: variable length array of non-POD element type 'std::vector<gchar *>'
# http://code.google.com/p/stardict-3/issues/detail?id=58
compiler.blacklist *clang*

configure.args	--disable-gnome-support \
		--disable-spell \
		--disable-gucharmap \
		--disable-festival \
		--disable-espeak \
		--disable-tools

# Undefined symbols "_g_module_close", "_g_module_open", "_g_module_symbol"
configure.libs	-lgmodule-2.0

variant gnome description {Add Gnome support} {
#Should be more stable slower and with gnome deps.
configure.args-delete	--disable-gnome-support
depends_lib-append	port:libgnome port:libgnomeui
}

platform darwin {
	configure.args-append --enable-darwin-support
}
