Files
haikuports/net-libs/kdsoap-ws-discovery-client/kdsoap_ws_discovery_client_qt5-0.4.0.recipe

96 lines
2.6 KiB
Bash

SUMMARY="WS-Discovery client library based on KDSoap"
DESCRIPTION="This project is trying to create a WS-Discovery client library \
based on the KDSoap library. It uses modern C++ 11 and Qt 5. The initial \
development is done for ONVIFViewer, a ONVIF camera viewer. However the \
library is designed to be useful as a generic WS-Discovery client."
HOMEPAGE="https://caspermeijn.gitlab.io/kdsoap-ws-discovery-client"
COPYRIGHT="2019-2020 Casper Meijn"
LICENSE="GNU GPL v3
CC0-1.0"
REVISION="1"
SOURCE_URI="https://download.kde.org/stable/kdsoap-ws-discovery-client/kdsoap-ws-discovery-client-$portVersion.tar.xz"
CHECKSUM_SHA256="2cd247c013e75f410659bac372aff93d22d71c5a54c059e137b9444af8b3427a"
SOURCE_DIR="kdsoap-ws-discovery-client-$portVersion"
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
commandSuffix=$secondaryArchSuffix
commandBinDir=$binDir
if [ "$targetArchitecture" = x86_gcc2 ]; then
commandSuffix=
commandBinDir=$prefix/bin
fi
libVersion="$portVersion"
libVersionCompat="$libVersion compat >= ${libVersion%.*}"
PROVIDES="
kdsoap_ws_discovery_client_qt5$secondaryArchSuffix = $portVersion
lib:libKDSoapWSDiscoveryClient$secondaryArchSuffix = $libVersionCompat
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libkdsoap$secondaryArchSuffix
lib:libkdsoap_server$secondaryArchSuffix
lib:libQt5Core$secondaryArchSuffix
lib:libQt5Network$secondaryArchSuffix
lib:libQt5Xml$secondaryArchSuffix
"
PROVIDES_devel="
kdsoap_ws_discovery_client_qt5${secondaryArchSuffix}_devel = $portVersion
devel:libKDSoapWSDiscoveryClient$secondaryArchSuffix = $libVersionCompat
"
REQUIRES_devel="
kdsoap_ws_discovery_client_qt5$secondaryArchSuffix == $portVersion base
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
extra_cmake_modules$secondaryArchSuffix
devel:libkdsoap$secondaryArchSuffix
devel:libkdsoap_server$secondaryArchSuffix
devel:libQt5Core$secondaryArchSuffix
devel:libQt5Network$secondaryArchSuffix
devel:libQt5Xml$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:g++$secondaryArchSuffix
cmd:ld$secondaryArchSuffix
cmd:lrelease$secondaryArchSuffix >= 5
cmd:make
cmd:pkg_config$secondaryArchSuffix
"
BUILD()
{
cmake -Bbuild -S. $cmakeDirArgs \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_BINDIR=$commandBinDir \
-DECM_DIR=/system/data/cmake/Modules/ECM/cmake \
-DBUILD_QCH=OFF
make -C build $jobArgs
}
INSTALL()
{
make -C build install
# prepare develop/lib
prepareInstalledDevelLib \
libKDSoapWSDiscoveryClient
# devel package
packageEntries devel \
$developDir \
$libDir/cmake
}
TEST()
{
export LIBRARY_PATH="$sourceDir/build/bin${LIBRARY_PATH:+:$LIBRARY_PATH}"
make -C build test
}