SliTaz Packages

Community Doc Forum Pro Shop Bugs Hg
.

Receipt for package "mbedtls"

# SliTaz package receipt v2.

PACKAGE="mbedtls"
VERSION="2.6.0"
CATEGORY="security"
SHORT_DESC="Portable cryptographic and SSL/TLS library (ex polarssl)"
MAINTAINER="al.bobylev@gmail.com"
LICENSE="Apache"
WEB_SITE="https://www.trustedfirmware.org/projects/mbed-tls/"

TARBALL="$PACKAGE-$VERSION.tar.gz"
WGET_URL="https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/$TARBALL"

# What is the latest version available today?
current_version()
{
    wget -O - https://github.com/Mbed-TLS/mbedtls/releases 2>/dev/null | \
    sed '/tag\//!d;s|.*tag/v*||;s|".*||;q'
}

# Rules to configure and make the package.
compile_rules() {
    sed \
        -e 's|//\(#define MBEDTLS_THREADING_C\)|\1|' \
        -e 's|//\(#define MBEDTLS_THREADING_PTHREAD\)|\1|' \
        -i include/mbedtls/config.h
    sed -i 's|<time.h>|"platform.h"|' include/mbedtls/ssl.h

    LDFLAGS="$LDFLAGS -I../include " \
    make SHARED=1 no_test &&
    make DESTDIR=$install/usr install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules() {
    mkdir -p $fs/usr/lib/
    cp -a $install/usr/bin/      $fs/usr/
    cp -a $install/usr/lib/*.so* $fs/usr/lib/
}
5935 packages and 845883 files in cooking database (Thu Jun 27 00:01:54 2024)