// Detect It Easy: detection rule file

// Author: DosX
// E-Mail: collab@kay-software.ru
// GitHub: https://github.com/DosX-dev
// Telegram: @DosX_dev

// https://libsndfile.github.io/libsamplerate/
meta("library", "Secret Rabbit Code");

function detect() {
    if (PE.isLibraryPresentExp(/^libsamplerate/i) ||
        PE.isFunctionPresent("src_set_ratio")) {
        bDetected = true;
    } else if (
        PE.isExportFunctionPresent("src_set_ratio") ||
        PE.isExportFunctionPresent("src_simple") ||
        PE.isExportFunctionPresent("src_is_valid_ratio")) {
        sOptions = "static"; // EAT
        bDetected = true;
    }
    return result();
}