# $Id: Portfile 63910 2010-02-18 00:52:41Z blair@macports.org $

PortSystem 1.0

name                    spymemcached
version                 2.4.2
categories              java
platforms               darwin
maintainers             blair
description             A high performance, distributed object caching system.

long_description        Memcached is a high-performance, distributed \
                        memory object caching system, generic in nature, \
                        but intended for use in speeding up dynamic web \
                        applications by alleviating database load.  This \
                        Port provides a native Java client written by \
                        Dustin Sallings.

homepage                http://code.google.com/p/spymemcached/

master_sites            googlecode
distfiles               memcached-${version}.jar \
                        memcached-${version}-javadoc.zip
extract.only

checksums               memcached-${version}.jar \
                                md5 f961a9a179134118b771d2fc13c2cf29 \
                                sha1 57ea9b5b9fcb0311d941527d942c0db29b467fcf \
                                rmd160 ffbcb29820417dd4b789a9fdb39b82693b06039f \
                        memcached-${version}-javadoc.zip \
                                md5 1bcd25995f784a9eba4ac4a7579f74ff \
                                sha1 0e12f82b3d0fb7aadc7527987414222826747279 \
                                rmd160 65ee216285cf245a217aeeeb45878ba310581011

depends_lib             bin:java:kaffe

use_configure           no

build { }

destroot {
        set javadir ${destroot}${prefix}/share/java
        set docdir ${destroot}${prefix}/share/doc/${name}

        xinstall -d -m 755 ${javadir}
        xinstall -d -m 755 ${docdir}/api

        file copy ${distpath}/memcached-${version}.jar \
                ${javadir}/spymemcached.jar
        system "unzip -q ${distpath}/memcached-${version}-javadoc.zip -d ${docdir}/api"
}
