mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-08 21:00:05 +02:00
124 lines
3.4 KiB
Bash
124 lines
3.4 KiB
Bash
SUMMARY="Public transport navigator"
|
|
DESCRIPTION="KTrip helps you navigate in public transport. It allows you to find journeys between \
|
|
specified locations, departures for a specific station and shows real-time delay and disruption \
|
|
information."
|
|
HOMEPAGE="https://apps.kde.org/ktrip/"
|
|
COPYRIGHT="2010-2025 KDE Organisation"
|
|
LICENSE="GNU GPL v2"
|
|
REVISION="1"
|
|
SOURCE_URI="https://download.kde.org/stable/release-service/$portVersion/src/ktrip-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256="ebb5d68338e1291f343456917c1d277de957256463bf7f743005d452750220bf"
|
|
SOURCE_DIR="ktrip-$portVersion"
|
|
ADDITIONAL_FILES="ktrip.rdef.in
|
|
applications-development.svg"
|
|
|
|
ARCHITECTURES="all !x86_gcc2"
|
|
SECONDARY_ARCHITECTURES="x86"
|
|
|
|
PROVIDES="
|
|
ktrip$secondaryArchSuffix = $portVersion
|
|
app:KTrip = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
lib:libGL$secondaryArchSuffix
|
|
lib:libKirigamiAddonsStatefulApp$secondaryArchSuffix
|
|
lib:libKPublicTransport$secondaryArchSuffix
|
|
# KF6
|
|
lib:libKF6ConfigCore$secondaryArchSuffix
|
|
lib:libKF6ConfigGui$secondaryArchSuffix
|
|
lib:libKF6CoreAddons$secondaryArchSuffix
|
|
lib:libKF6Crash$secondaryArchSuffix
|
|
lib:libKF6I18n$secondaryArchSuffix
|
|
# Qt6
|
|
lib:libQt6Core$secondaryArchSuffix
|
|
lib:libQt6Gui$secondaryArchSuffix
|
|
lib:libQt6OpenGL$secondaryArchSuffix
|
|
lib:libQt6Network$secondaryArchSuffix
|
|
lib:libQt6Qml$secondaryArchSuffix
|
|
lib:libQt6Quick$secondaryArchSuffix
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
qqc2_desktop_style6${secondaryArchSuffix}_devel
|
|
devel:libKirigamiAddonsStatefulApp$secondaryArchSuffix
|
|
devel:libKPublicTransport$secondaryArchSuffix
|
|
devel:libKOpeningHours$secondaryArchSuffix >= 25
|
|
# KF6
|
|
extra_cmake_modules$secondaryArchSuffix
|
|
devel:libKF6ConfigCore$secondaryArchSuffix
|
|
devel:libKF6CoreAddons$secondaryArchSuffix
|
|
devel:libKF6Crash$secondaryArchSuffix
|
|
devel:libKF6I18n$secondaryArchSuffix
|
|
# Qt6
|
|
devel:libQt6Core$secondaryArchSuffix
|
|
devel:libQt6Qml$secondaryArchSuffix
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:cmake
|
|
cmd:g++$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:msgfmt$secondaryArchSuffix
|
|
cmd:msgmerge$secondaryArchSuffix
|
|
cmd:pkg_config$secondaryArchSuffix
|
|
"
|
|
|
|
PATCH()
|
|
{
|
|
# disable docs generation
|
|
sed -e '/kdoctools_install(po)/ s/^#*/#/' -i CMakeLists.txt
|
|
}
|
|
|
|
BUILD()
|
|
{
|
|
cmake -B build -S . -DCMAKE_BUILD_TYPE=Release \
|
|
$cmakeDirArgs \
|
|
-DCMAKE_INSTALL_BINDIR=$appsDir \
|
|
-DKDE_INSTALL_PLUGINDIR=$addOnsDir/Qt6 \
|
|
-DKDE_INSTALL_QMLDIR=$dataDir/Qt6/qml \
|
|
-DECM_MKSPECS_INSTALL_DIR=$dataDir/Qt6/mkspecs \
|
|
-DECM_DIR=/system/data/cmake/Modules/ECM/cmake \
|
|
-DCMAKE_SKIP_RPATH=YES \
|
|
-Wno-dev
|
|
|
|
make -C build $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
make -C build install
|
|
|
|
# cleanup
|
|
rm -rf $dataDir/{applications,icons,metainfo}
|
|
|
|
mv $appsDir/ktrip $appsDir/KTrip
|
|
|
|
local MAJOR="`echo "$portVersion" | cut -d. -f1`"
|
|
local MIDDLE="`echo "$portVersion" | cut -d. -f2`"
|
|
local MINOR="`echo "$portVersion" | cut -d. -f3`"
|
|
local APP_NAME="KTrip"
|
|
local LONG_INFO="$SUMMARY"
|
|
local APP_SIGNATURE="application/x-vnd.kde-ktrip"
|
|
sed \
|
|
-e "s|@MAJOR@|$MAJOR|" \
|
|
-e "s|@MIDDLE@|$MIDDLE|" \
|
|
-e "s|@MINOR@|$MINOR|" \
|
|
-e "s|@LONG_INFO@|$LONG_INFO|" \
|
|
-e "s|@APP_NAME@|$APP_NAME|" \
|
|
-e "s|@APP_SIGNATURE@|$APP_SIGNATURE|" \
|
|
$portDir/additional-files/ktrip.rdef.in > ktrip.rdef
|
|
|
|
addResourcesToBinaries ktrip.rdef $appsDir/KTrip
|
|
addAppDeskbarSymlink $appsDir/KTrip
|
|
|
|
iconDir=$dataDir/icons/haiku/actions/symbolic
|
|
mkdir -p $iconDir
|
|
cp $portDir/additional-files/applications-development.svg $iconDir
|
|
}
|
|
|
|
TEST()
|
|
{
|
|
ctest --test-dir build --output-on-failure
|
|
}
|