# -*- 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: Portfile 118856 2014-04-13 07:41:00Z ryandesign@macports.org $

PortSystem                  1.0
PortGroup                   github 1.0
PortGroup                   xcode 1.0

github.setup                BlueM cliclick 2.4
categories                  sysutils
maintainers                 ryandesign
license                     BSD

description                 a command-line utility for simulating mouse clicks

long_description            ${name} emulates mouse clicks or series of mouse \
                            clicks (including double-clicks and Control-clicks) \
                            at arbitrary screen coordinates

homepage                    http://www.bluem.net/en/mac/cliclick/

checksums                   rmd160  c548b713cb1eae71138181ece6aff8c2bd7fe6b4 \
                            sha256  52a7c4cfbfe8cf290ce7c9ed97150b6ba4b39c5ee6b735b7731334f4a0f36abb

pre-fetch {
    if {${os.major} < 9} {
        ui_error "${name} requires Mac OS X 10.5 or greater."
        return -code error "incompatible Mac OS X version"
    }
}

xcode.configuration         Release

destroot {
    xinstall ${worksrcpath}/build/${xcode.configuration}/${name} ${destroot}${prefix}/bin
    xinstall -d ${destroot}${prefix}/share/doc/${name}
    xinstall -m 644 -W ${worksrcpath} README.markdown ${destroot}${prefix}/share/doc/${name}
}
