# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4

PortSystem          1.0
PortGroup           github 1.0
PortGroup           makefile 1.0

github.setup        davidesantangelo krep 0.1.7 v
github.tarball_from archive
revision            0

homepage            https://davidesantangelo.github.io/krep/

description         A High-Performance String Search Utility

long_description    \
    ${name} is a blazingly fast string search utility designed for \
    performance-critical applications. It implements multiple optimized \
    search algorithms and leverages modern hardware capabilities to deliver \
    maximum throughput.

checksums           rmd160  250e8a67e1099706e934016ea0391e71bce357ac \
                    sha256  a42f1d70dd1826bcfc5ffc91c9a6f52ff3e85bb47bda7b67038f549dd6c00982 \
                    size    22319

categories          textproc
installs_libs       no
license             BSD
maintainers         {gmail.com:herby.gillot @herbygillot} \
                    openmaintainer

build.args-append   ENABLE_ARCH_DETECTION=0

compiler.c_standard 2011

patch {
    reinplace -E {s|CC =|CC ?=|g}           ${worksrcpath}/Makefile
    reinplace -E {s|CFLAGS =|CFLAGS ?=|g}   ${worksrcpath}/Makefile
    reinplace -E {s|LDFLAGS =|LDFLAGS ?=|g} ${worksrcpath}/Makefile
}

destroot {
    xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin/
}
