# $Id: Portfile 43533 2008-12-11 17:59:44Z jmr@macports.org $

PortSystem 1.0
PortGroup python24 1.0

name			py-magic
version			0.1
revision		2
categories		python sysutils
platforms		darwin
maintainers		nomaintainer
description		python module for determining a files or streams magic number
long_description	Determines the mime type of a file using magic \
				numbers. Can also operate on arbitrary data streams. \
				Much like the Unix file(1) program.

homepage		http://www.jsnp.net/code/
master_sites	${homepage}
distfiles		magic.py
dist_subdir		python/${name}/${version}_${revision}
checksums		md5 baa1b1864c60d3f5482971cff810f8a4 \
				sha1 48c617490ebfa3c1a1cf0445dcb6d8fd4abda236

extract	{
	file mkdir ${worksrcpath}
	file copy ${distpath}/magic.py ${worksrcpath}
	file copy ${filespath}/setup.py ${worksrcpath}
	reinplace "s|VERSION|${version}|g" ${worksrcpath}/setup.py
}
