# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 55272 2009-08-08 00:55:19Z ryandesign@macports.org $

PortSystem 1.0

name			gnuradio-omnithread
version			3.2
maintainers		nomaintainer
description		Omnithread component of GNU Radio.
long_description Omnithread component of GNU Radio: \
a cross-platform C++ thread library.

categories		science
homepage		http://gnuradio.org/trac

# all GNU Radio components come in a single tarball.
# Reuse this tarball for each Port

dist_subdir		gnuradio
master_sites.mirror_subdir gnuradio
distname		gnuradio-${version}
master_sites	gnu

platforms		darwin macosx

checksums		md5		9d91d0f8f2cb35bc86435784fa8e72d8 \
				sha1	3d7e177a57f8c40ec5ac95161f06097872aef1ba \
				rmd160	9d36dc6427eaf59795c8d4853764d5a526cfbce8

# omnithread gets built by the main configure script, which requires a
# whole slew of ports; no other ports are actually required, but we
# have to make configure happy ;)

depends_build	port:pkgconfig
depends_lib		port:gawk \
				port:libtool \
				port:zlib \
				port:boost \
				port:cppunit \
				port:fftw-3-single

configure.args	--disable-all-components \
				--enable-omnithread

use_parallel_build	yes

variant docs description "build documentation for ${name}" {
	configure.args-append --enable-doxygen --enable-docs
	depends_lib-append port:doxygen
}

if { ![variant_isset docs] } {
	configure.args-append --disable-doxygen --disable-docs
}

variant python25 conflicts python26 description "Use Python 2.5" {
	configure.env PYTHON=${prefix}/bin/python2.5
	depends_lib-append	port:python25
}

variant python26 conflicts python25 description "Use Python 2.6" {
	configure.env PYTHON=${prefix}/bin/python2.6
	depends_lib-append	port:python26
}

if { ![variant_isset python25] && ![variant_isset python26] } {
	default_variants +python26
}
