# $Id: Portfile 61220 2009-12-05 19:31:30Z nox@macports.org $

PortSystem      1.0
PortGroup       muniversal 1.0

name			lzo2
set my_name     lzo
version			2.03
revision		2
categories		archivers
platforms		darwin
maintainers		gmail.com:yunzheng.hu
description		Real-time data compression library

long_description \
	LZO is a portable lossless data compression library written in ANSI C. \
	It offers pretty fast compression and very fast decompression. \
	Decompression requires no memory. \
	In addition there are slower compression levels achieving a quite \
	competitive compression ratio while still decompressing at \
	this very high speed. \
	LZO is distributed under the GNU General Public License.

homepage		http://www.oberhumer.com/opensource/lzo/
master_sites    ${homepage}download/ \
				ftp://ftp.uni-koeln.de/util/arc/
distname        ${my_name}-${version}

checksums           md5     0c3d078c2e8ea5a88971089a2f02a726 \
                    sha1    135a50699296e853362a3d11b9f872c74c8b8c5a \
                    rmd160  1c2eb11ba2babd81236128b7fef3676c9db7da51

configure.args	--enable-shared --enable-static --disable-asm

test.run		yes
test.target		check

platform darwin 8 {
	# supposedly, the asm bits work on tiger
	configure.args-delete --disable-asm
}

post-destroot {
    set docdir ${prefix}/share/doc/${my_name}-${version}

    xinstall -d ${destroot}${docdir}
    xinstall -m 0644 -W ${worksrcpath} AUTHORS BUGS COPYING ChangeLog NEWS README THANKS \
        ${destroot}${docdir}
    eval xinstall -m 0644 [glob ${worksrcpath}/doc/*] ${destroot}${docdir}
}

livecheck.type  regex
livecheck.url   ${homepage}
livecheck.regex "Version (\\d+(?:\\.\\d+)*)"

