# $Id: Portfile 86632 2011-10-30 12:24:57Z ryandesign@macports.org $

PortSystem              1.0

name                    bluefish
conflicts               bluefish-devel
version                 2.0.3
categories              editors www
platforms               darwin
maintainers             nomaintainer
homepage                http://bluefish.openoffice.nl/
description             A powerful editor for web designers

long_description        Bluefish is a powerful editor for experienced web designers and \
                        programmers. Bluefish supports many programming and markup languages \
                        but it focuses on editing dynamic and interactive websites.

dist_subdir             bluefish
distname                bluefish-${version}

master_sites            sourceforge:project/bluefish/bluefish/${version} \
                        http://www.bennewitz.com/bluefish/stable/source/

checksums           	md5     4c062fcb1f90f91a35687b877d37d6dd \
                    	sha1    ab6b16d50faca169c25001d5a26ca8b84ddb1019 \
                    	rmd160  0a82d8973b201014bcc03fbe09896472bfcdf3c1

use_bzip2               yes

depends_build           port:pkgconfig \
                        port:intltool

depends_lib             port:gtk2 \
                        port:libxml2 \
                        port:enchant \
                        port:gucharmap

configure.args          --mandir=${prefix}/share/man \
                        --infodir=${prefix}/share/info \
                        --sysconfdir=${prefix}/etc \
                        --with-icon-path=${prefix}/share/pixmaps \
                        --without-freedesktop_org-menu \
                        --without-freedesktop_org-mime

pre-configure {
    configure.env-append    CHARMAP_PLUGIN_CFLAGS="[exec ${prefix}/bin/pkg-config --cflags gucharmap-2]" \
                            CHARMAP_PLUGIN_LIBS="[exec ${prefix}/bin/pkg-config --libs gucharmap-2]"
}

destroot.destdir        DESTDIR=${destroot}

variant nosplash {
    configure.args-append --disable-splash-screen
}

variant no_spellcheck description {Disable spell-check feature} {
    depends_lib-delete port:enchant
    configure.args-append --disable-spell-check
}

variant tidy {
    depends_run bin:tidy:tidy
}
