# $Id: Portfile,v 1.1 2006/04/29 19:54:05 yves Exp $

PortSystem   1.0
PortGroup   gnustep 1.0

name        gnustep-back
version     0.10.3
revision    1
platforms   darwin
maintainers yves@opendarwin.org

description A back-end component for the GNUstep GUI Library.
long_description \
    The implementation of the GNUstep GUI Library is designed \
    in two parts.  The first part is the front-end component \
    which is independent of platform and display system.  \
    This front-end is combined with a back-end component \
    which handles all of the display system dependent \
    such as specific calls to the X Window System.

depends_lib   port:gnustep-gui port:libart_lgpl port:windowmaker port:Xft2

checksums     md5 410e1a84774ac7f49472b0001c10cf7e 

use_configure   yes
configure.args-append   --enable-graphics=art --disable-glitz

post-install {
	ui_msg "\n\
	        In order to have a working GNUstep environment,\n\
	        copy these lines at the top of your ~/.xinitrc file :\n\n\
	        . ${prefix}/GNUstep/System/Library/Makefiles/GNUstep.sh\n\
            gdnc \n\
            gpbs \n\
            make_services \n\n\
            For more information on setting the GNUstep environment, see\n\
            http://gnustep.made-it.com/BuildGuide/#CONFIG.GNUSTEP \n\n"
}

platform darwin {
    array set gnustep.post_flags {
        Source  "-lgnustep-gui"
        Tools   "-lgnustep-gui"
    }
}

platform darwin 8 {
	configure.args-append  --disable-glx
}

# not tested
variant cairo {
    depends_lib-delete  port:libart_lgpl
    depends_lib-append  port:cairo port:glitz
    configure.args-delete --enable-graphics=art --disable-glitz
    configure.args-append --enable-graphics=cairo --enable-glitz
}
