# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # $Id$ PortSystem 1.0 name redis version 2.4.16 revision 0 categories databases license BSD platforms darwin maintainers gmail.com:brianjlandau openmaintainer description Redis is an open source, advanced key-value store. long_description ${description} homepage http://redis.io/ master_sites googlecode:redis checksums rmd160 ddfda09035ca6469df1973e8e1b1fd73c8b506ce \ sha256 d35cc89d73aa1ff05af5f1380a4411c828979b3b446f5caf8b5720225b38e15b use_configure no variant universal {} build.env-append CC="${configure.cc} [get_canonical_archflags]" post-build { copy ${filespath}/redis.conf.sample.in ${workpath}/redis.conf.sample copy ${filespath}/redis-daemon.conf.sample.in ${workpath}/redis-daemon.conf.sample reinplace "s|@PREFIX@|${prefix}|g" \ ${workpath}/redis.conf.sample \ ${workpath}/redis-daemon.conf.sample } destroot.keepdirs ${destroot}${prefix}/var/db/redis destroot { xinstall -d ${destroot}${prefix}/var/db/redis xinstall -m 0755 -W ${worksrcpath}/src \ redis-benchmark \ redis-check-aof \ redis-check-dump \ redis-cli \ redis-server \ ${destroot}${prefix}/bin xinstall -m 0644 -W ${workpath} \ redis.conf.sample \ redis-daemon.conf.sample \ ${destroot}${prefix}/etc } post-activate { if {![file exists ${prefix}/etc/redis-daemon.conf]} { file copy ${prefix}/etc/redis-daemon.conf.sample \ ${prefix}/etc/redis-daemon.conf } if {![file exists ${prefix}/etc/redis.conf]} { file copy ${prefix}/etc/redis.conf.sample \ ${prefix}/etc/redis.conf } xinstall -d ${prefix}/var/log touch ${prefix}/var/log/redis.log } startupitem.create yes startupitem.start "${prefix}/bin/redis-server ${prefix}/etc/redis-daemon.conf" startupitem.stop "echo \"SHUTDOWN\" | nc localhost 6379" notes " To start up a redis server instance use this command: redis-server ${prefix}/etc/redis.conf "