274.5. kpublictransport-26.08.2
Library and QML module for public-transport journeys, departures and onboard train Wi-Fi APIs
26.08.2-1 · LGPL-2.0-or-later AND LGPL-2.1-or-later AND BSD-2-Clause AND BSD-3-Clause AND MIT AND CC0-1.0 AND ODbL-1.0 · 7.6 SBU · 7.4 MiB, 140 files · 43_toolkits, 154 of 344 · ports/core/gis/kpublictransport
Homepage: https://invent.kde.org/libraries/kpublictransport
KPublicTransport asks public-transport operators for journeys, departures, arrivals and vehicle layouts, through the backends Europe’s operators run: HAFAS, EFA, Navitia, OpenTripPlanner, MOTIS and the rest, plus GBFS feeds for rental bikes and scooters. It merges what several backends answer, chooses backends by the area a query covers, and offers it all to C++ and to QML (org.kde.kpublictransport and its ui module). A second library, KPublicTransportOnboard, reads the on-board Wi-Fi portals of trains and buses for position and next stops. ktrip, Itinerary and kosmindoormap are built on it.
Depends on: cmake, ninja, extra-cmake-modules, qt6-qtbase, qt6-qtdeclarative, qt6-qtlocation, qt6-qtpositioning, zlib, ki18n, kcoreaddons, kirigami, kirigami-addons, kitemmodels, networkmanager-qt.
Required by (3): itinerary, kosmindoormap, ktrip.
Sources: kpublictransport-26.08.2.tar.xz (982.0 KiB). Every step kpkg takes applies to this port.
Install: script/chroot/exec.sh bash -c 'source script/phases/43_toolkits/phase.env && kpkg install kpublictransport'
build.sh:
cmake -S . -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D KDE_INSTALL_LIBDIR=lib \
-D CMAKE_BUILD_TYPE=Release \
-D KDE_INSTALL_USE_QT_SYS_PATHS=ON \
-D BUILD_TESTING=OFF \
-D KF_SKIP_PO_PROCESSING=ON \
-D CMAKE_REQUIRE_FIND_PACKAGE_KF6NetworkManagerQt=ON \
-D CMAKE_DISABLE_FIND_PACKAGE_Protobuf=ON \
-D CMAKE_DISABLE_FIND_PACKAGE_PolyClipping=ON \
-D CMAKE_DISABLE_FIND_PACKAGE_OsmTools=ON \
-Wno-dev
cmake --build build
DESTDIR=$PKG cmake --install build
-D CMAKE_REQUIRE_FIND_PACKAGE_KF6NetworkManagerQt=ON— Requires networkmanager-qt. It is the only way the onboard library learns which Wi-Fi network the machine is on, outside Android; without it upstream builds a stand-in that never reports one, so a train’s Wi-Fi is never recognised.-D CMAKE_DISABLE_FIND_PACKAGE_Protobuf=ON— No OSM PBF reader. With Protobuf found, upstream builds it as a static plugin of the OSM library that nothing installed links, so it only adds build time and a dependency.-D CMAKE_DISABLE_FIND_PACKAGE_PolyClipping=ON— No coverage-area processing. It serves onlytransport-api-sync, the maintainer tool that refreshes the backend list from the Transport API Repository, which is not installed.-D CMAKE_DISABLE_FIND_PACKAGE_OsmTools=ON— Noosmconvertorosmfiltersearch. They regenerate the line-metadata tables, which the tarball ships already generated.-D KF_SKIP_PO_PROCESSING=ON— Builds none of the translation catalogues underpo/, which the package-wide English-only rule would remove anyway (see Size and language policy).
Libraries: libKPublicTransport.so, libKPublicTransportOnboard.so.
Directories: /usr/include/KPublicTransport, /usr/lib/cmake/KPublicTransport, /usr/lib/qt6/qml/org/kde/kpublictransport, /usr/share/licenses/kpublictransport.
Every query is a request to the operators’ public servers; nothing is fetched until an application asks. The QML pages import Kirigami, Kirigami Addons’ form cards and delegates, org.kde.kitemmodels, org.kde.coreaddons, org.kde.i18n.localeData, Qt Location and Qt Positioning at run time, which is why kirigami, kitemmodels, kcoreaddons, qt6-qtlocation and qt6-qtpositioning are in depends beside the build’s own requirements. The configure requires kirigami-addons 1.6.0 or newer.