# -*- 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           cmake 1.1
PortGroup           github 1.0

name                libbtbb
categories          devel net security
description         Bluetooth baseband decoding library.
long_description    Bluetooth baseband decoding library, forked from the GR-Bluetooth project. \
                    It can be used to extract Bluetooth packet and piconet information \
                    from Ubertooth devices as well as GR-Bluetooth/USRP.
license             GPL-2
maintainers         {@barracuda156 gmail.com:vital.had} openmaintainer

subport             ${name}-devel {}

if {${subport} eq "${name}"} {
    conflicts       ${name}-devel

    github.setup    greatscottgadgets libbtbb 2020-12-R1
    # Change github.tarball_from to 'releases' or 'archive' next update
    github.tarball_from tarball
    checksums       rmd160  eca69c16710e4bf793cccfc722101e015a95b0e9 \
                    sha256  aa0588f21701156ccbd6b388fafe63225b41dd5b37b390f6c0ed3504d259847a \
                    size    308473

} elseif {${subport} eq "${name}-devel"} {
    conflicts       ${name}

    github.setup    greatscottgadgets libbtbb f0fe1768b080b1333a5357e8308d900e1273ec7f
    # Change github.tarball_from to 'releases' or 'archive' next update
    github.tarball_from tarball
    version         2022-08-26
    checksums       rmd160  82d6f97e4070ec7f14b64d3d21063c3b4d82fd9f \
                    sha256  daa64b8a746f87fb6a6f6e6c589ee251f98454d9b0093b665f883446b49d047f \
                    size    310865
}

set python_ver      310
depends_build-append \
                    port:python${python_ver}

# cc1: error: unrecognized command line option "-std=gnu90"
compiler.blacklist-append *gcc-4.*

platform darwin powerpc {
    # Needed for Rosetta
    compiler.blacklist-append clang
}
