# -*- 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

PortSystem      1.0
PortGroup       github 1.0

name            libusb-compat

description     library for USB device access
long_description \
    library for use by user level applications to \
    access USB devices regardless of OS

categories      devel
license         LGPL-2+
maintainers     {michaelld @michaelld} openmaintainer

github.setup    libusb libusb-compat-0.1 0.1.9 v
# Change github.tarball_from to 'releases' or 'archive' next update
github.tarball_from tarball
checksums       rmd160 5ea9c032106a010b8f87d4a47491526b0f22a115 \
                sha256  b74a9e777b6e38bd7429cd5f684a9acd1acd2ffe6167e02d194dd5e37b77dbba \
                size    39606
revision        0

homepage        https://libusb.info/

depends_build-append \
    port:automake \
    port:autoconf \
    port:libtool \
    port:pkgconfig

depends_lib     path:lib/pkgconfig/libusb-1.0.pc:libusb

# use autotools to get ready to configure

pre-configure {
    system -W ${worksrcpath} "${prefix}/bin/glibtoolize -v -i -W all && ${prefix}/bin/aclocal -I m4 && ${prefix}/bin/autoheader && ${prefix}/bin/autoconf && ${prefix}/bin/automake -a --gnu"
}

github.livecheck.regex  {([0-9.]+)}
