1SUMMARY="A cryptography library" 2DESCRIPTION="Botan is a cryptography library written in C++. \ 3Its goal is to offer the tools necessary to implement a range of practical \ 4systems, such as TLS/DTLS, PKIX certificate handling, PKCS#11 and TPM \ 5hardware support, password hashing, and post quantum crypto schemes. \ 6Botan also has a C89 API specifically designed to be easy to call from other \ 7languages." 8HOMEPAGE="https://botan.randombit.net/" 9COPYRIGHT="1999-2024 The Botan Authors" 10LICENSE="BSD (2-clause)" 11REVISION="1" 12SOURCE_URI="https://botan.randombit.net/releases/Botan-$portVersion.tar.xz" 13CHECKSUM_SHA256="5a3a88ef6433e97bcab0efa1ed60c6197e4ada9d9d30bc1c47437bf89b97f276" 14SOURCE_DIR="Botan-$portVersion" 15PATCHES="botan-$portVersion.patchset" 16 17ARCHITECTURES="all !x86_gcc2" 18SECONDARY_ARCHITECTURES="x86" 19 20commandSuffix=$secondaryArchSuffix 21commandBinDir=$binDir 22if [ "$targetArchitecture" = x86_gcc2 ]; then 23 commandSuffix= 24 commandBinDir=$prefix/bin 25fi 26 27libVersion="19.19.4" 28libVersionCompat="$libVersion compat >= ${libVersion%%.*}" 29 30PROVIDES=" 31 botan$secondaryArchSuffix = $portVersion 32 lib:libbotan_2$secondaryArchSuffix = $libVersionCompat 33 " 34REQUIRES=" 35 haiku$secondaryArchSuffix 36 lib:libbz2$secondaryArchSuffix 37 lib:liblzma$secondaryArchSuffix 38 lib:libsqlite3$secondaryArchSuffix 39 lib:libz$secondaryArchSuffix 40 " 41 42PROVIDES_devel=" 43 botan${secondaryArchSuffix}_devel = $portVersion 44 devel:libbotan_2$secondaryArchSuffix = $libVersionCompat 45 " 46REQUIRES_devel=" 47 haiku${secondaryArchSuffix}_devel 48 botan$secondaryArchSuffix == $portVersion base 49 " 50 51BUILD_REQUIRES=" 52 haiku${secondaryArchSuffix}_devel 53 devel:libbz2$secondaryArchSuffix 54 devel:liblzma$secondaryArchSuffix 55 devel:libsqlite3$secondaryArchSuffix 56 devel:libz$secondaryArchSuffix 57 " 58BUILD_PREREQUIRES=" 59 cmd:awk 60 cmd:gcc$secondaryArchSuffix 61 cmd:g++$secondaryArchSuffix 62 cmd:ld$secondaryArchSuffix 63 cmd:make 64 cmd:pkg_config$secondaryArchSuffix 65 cmd:python3 66 " 67 68BUILD() 69{ 70 runConfigure --omit-buildspec --omit-dirs binDir ./configure.py \ 71 --bindir="$commandBinDir" \ 72 --enable-shared-library \ 73 --disable-static \ 74 --with-bzip2 --with-lzma --with-zlib \ 75 --with-sqlite3 76 make $jobArgs 77} 78 79INSTALL() 80{ 81 make install 82 83 prepareInstalledDevelLib libbotan-2 84 fixPkgconfig 85 86 packageEntries devel \ 87 "$developDir" \ 88 "$documentationDir" 89 90 # remove the cmd in favor for package botan3 91 rm -rf $commandBinDir 92} 93 94TEST() 95{ 96 LIBRARY_PATH="$sourceDir${LIBRARY_PATH:+:$LIBRARY_PATH}" \ 97 ./botan-test 98} 99