mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-08 21:00:05 +02:00
228 lines
7.1 KiB
Bash
228 lines
7.1 KiB
Bash
SUMMARY="A virtual globe and world atlas"
|
|
DESCRIPTION="Marble is a geographical atlas and a virtual globe which lets you \
|
|
quickly explore places on our home planet.
|
|
|
|
You can use Marble to look up addresses, to easily create maps, \
|
|
measure distances and to retrieve detail information about locations \
|
|
that you have just heard about in the news or on the Internet.
|
|
|
|
The user interface is clean, simple and easy to use."
|
|
HOMEPAGE="https://marble.kde.org/"
|
|
COPYRIGHT="2007-2025 Marble Virtual Globe authors"
|
|
LICENSE="GNU LGPL v2.1"
|
|
REVISION="1"
|
|
SOURCE_URI="https://download.kde.org/stable/release-service/$portVersion/src/marble-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256="ae29bd99b09eef35079ff6c58f5f34c1bebf8b7708bcb78eb67040950caadc7b"
|
|
PATCHES="marble-$portVersion.patchset"
|
|
ADDITIONAL_FILES="marble.rdef.in"
|
|
|
|
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="
|
|
marble$secondaryArchSuffix = $portVersion
|
|
app:Marble
|
|
cmd:marble$commandSuffix = $portVersion
|
|
cmd:marble_behaim$commandSuffix = $portVersion
|
|
cmd:marble_maps$commandSuffix = $portVersion
|
|
lib:libastro$secondaryArchSuffix = $libVersionCompat
|
|
lib:libmarblewidget_qt6$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
lib:libGL$secondaryArchSuffix
|
|
lib:libphonon4Qt6$secondaryArchSuffix
|
|
lib:libprotobuf$secondaryArchSuffix
|
|
lib:libz$secondaryArchSuffix
|
|
# KF6
|
|
lib:libKF6ColorScheme$secondaryArchSuffix
|
|
lib:libKF6ConfigCore$secondaryArchSuffix
|
|
lib:libKF6ConfigWidgets$secondaryArchSuffix
|
|
lib:libKF6CoreAddons$secondaryArchSuffix
|
|
lib:libKF6Crash$secondaryArchSuffix
|
|
lib:libKF6GuiAddons$secondaryArchSuffix
|
|
lib:libKF6I18n$secondaryArchSuffix
|
|
lib:libKF6KIOCore$secondaryArchSuffix
|
|
lib:libKF6Parts$secondaryArchSuffix
|
|
lib:libKF6WidgetsAddons$secondaryArchSuffix
|
|
lib:libKF6XmlGui$secondaryArchSuffix
|
|
# Qt6
|
|
lib:libQt6Core$secondaryArchSuffix
|
|
lib:libQt6Core5Compat$secondaryArchSuffix
|
|
lib:libQt6DBus$secondaryArchSuffix
|
|
lib:libQt6Gui$secondaryArchSuffix
|
|
lib:libQt6Network$secondaryArchSuffix
|
|
lib:libQt6PrintSupport$secondaryArchSuffix
|
|
lib:libQt6Qml$secondaryArchSuffix
|
|
lib:libQt6Quick$secondaryArchSuffix
|
|
lib:libQt6Svg$secondaryArchSuffix
|
|
lib:libQt6Widgets$secondaryArchSuffix
|
|
lib:libQt6Xml$secondaryArchSuffix
|
|
"
|
|
|
|
PROVIDES_devel="
|
|
marble${secondaryArchSuffix}_devel = $portVersion
|
|
devel:libastro$secondaryArchSuffix = $libVersionCompat
|
|
devel:libmarblewidget_qt6$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES_devel="
|
|
marble$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
abseil_cpp${secondaryArchSuffix}_devel >= 20230125
|
|
devel:libphonon4qt6$secondaryArchSuffix
|
|
devel:libprotobuf$secondaryArchSuffix
|
|
devel:libz$secondaryArchSuffix
|
|
# KF6
|
|
extra_cmake_modules$secondaryArchSuffix
|
|
devel:libKF6Archive$secondaryArchSuffix
|
|
devel:libKF6Attica$secondaryArchSuffix
|
|
devel:libKF6AuthCore$secondaryArchSuffix
|
|
devel:libKF6Bookmarks$secondaryArchSuffix
|
|
devel:libKF6Codecs$secondaryArchSuffix
|
|
devel:libKF6Completion$secondaryArchSuffix
|
|
devel:libKF6ConfigCore$secondaryArchSuffix
|
|
devel:libKF6ConfigGui$secondaryArchSuffix
|
|
devel:libKF6ConfigWidgets$secondaryArchSuffix
|
|
devel:libKF6CoreAddons$secondaryArchSuffix
|
|
devel:libKF6Crash$secondaryArchSuffix
|
|
devel:libKF6GuiAddons$secondaryArchSuffix
|
|
devel:libKF6I18n$secondaryArchSuffix
|
|
devel:libKF6IconThemes$secondaryArchSuffix
|
|
devel:libKF6ItemModels$secondaryArchSuffix
|
|
devel:libKF6ItemViews$secondaryArchSuffix
|
|
devel:libKF6JobWidgets$secondaryArchSuffix
|
|
devel:libKF6KIOCore$secondaryArchSuffix
|
|
devel:libKF6KIOFileWidgets$secondaryArchSuffix
|
|
devel:libKF6KIOWidgets$secondaryArchSuffix
|
|
devel:libKF6NewStuffCore$secondaryArchSuffix
|
|
devel:libKF6Parts$secondaryArchSuffix
|
|
devel:libKF6Runner$secondaryArchSuffix
|
|
devel:libKF6Service$secondaryArchSuffix
|
|
devel:libKF6Solid$secondaryArchSuffix
|
|
devel:libKF6SonnetUi$secondaryArchSuffix
|
|
devel:libKF6TextWidgets$secondaryArchSuffix
|
|
devel:libKF6WidgetsAddons$secondaryArchSuffix
|
|
devel:libKF6WindowSystem$secondaryArchSuffix
|
|
devel:libKF6XmlGui$secondaryArchSuffix
|
|
# Qt6
|
|
qt6_tools${secondaryArchSuffix}_devel
|
|
devel:libQt6Core$secondaryArchSuffix
|
|
devel:libQt6Core5Compat$secondaryArchSuffix
|
|
devel:libQt6Gui$secondaryArchSuffix
|
|
devel:libQt6Multimedia$secondaryArchSuffix
|
|
devel:libQt6Network$secondaryArchSuffix
|
|
devel:libQt6Positioning$secondaryArchSuffix
|
|
devel:libQt6PrintSupport$secondaryArchSuffix
|
|
devel:libQt6Qml$secondaryArchSuffix
|
|
devel:libQt6Quick$secondaryArchSuffix
|
|
devel:libQt6SerialPort$secondaryArchSuffix
|
|
devel:libQt6Svg$secondaryArchSuffix
|
|
# devel:libQt6WebChannel$secondaryArchSuffix
|
|
# devel:libQt6WebEngineCore$secondaryArchSuffix
|
|
# devel:libQt6WebEngineWidgets$secondaryArchSuffix
|
|
devel:libQt6Widgets$secondaryArchSuffix
|
|
devel:libQt6Xml$secondaryArchSuffix
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:cmake
|
|
cmd:g++$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:msgfmt$secondaryArchSuffix
|
|
cmd:msgmerge$secondaryArchSuffix
|
|
cmd:perl
|
|
cmd:pkg_config$secondaryArchSuffix
|
|
"
|
|
|
|
TEST_REQUIRES="
|
|
qthaikuplugins$secondaryArchSuffix
|
|
lib:libvpx$secondaryArchSuffix
|
|
"
|
|
|
|
PATCH()
|
|
{
|
|
# disable docs generation
|
|
sed -e '/add_subdirectory(doc)/ s/^#*/#/' -i CMakeLists.txt
|
|
# disable knsrc file install
|
|
sed -e '/install(FILES marble.knsrc/ s/^#*/#/' -i src/apps/marble-kde/CMakeLists.txt
|
|
# disable doctools
|
|
sed -e '/ kdoctools_install/ s/^#*/#/' -i src/apps/marble-kde/CMakeLists.txt
|
|
}
|
|
|
|
BUILD()
|
|
{
|
|
cmake -Bbuild -S. \
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
$cmakeDirArgs \
|
|
-DCMAKE_INSTALL_BINDIR=$commandBinDir \
|
|
-DICON_INSTALL_DIR=$dataDir/icons \
|
|
-DINCLUDE_INSTALL_DIR=$includeDir \
|
|
-DMARBLE_PRI_INSTALL_DIR=$dataDir/Qt6/mkspecs \
|
|
-DQT_PLUGINS_DIR=$addOnsDir/Qt6 \
|
|
-DCMAKE_SKIP_RPATH=YES \
|
|
-DBUILD_TESTING=OFF \
|
|
-Wno-dev
|
|
|
|
make -Cbuild $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
make -Cbuild install
|
|
|
|
# don't mess with shared_mime_info files
|
|
rm -rf $dataDir/mime/{aliases,generic-icons,globs,globs2,icons,magic}
|
|
rm -rf $dataDir/mime/{mime.cache,subclasses,treemagic,types,version,XMLnamespaces}
|
|
# cleanup
|
|
rm -rf $dataDir/{applications,icons,metainfo}
|
|
|
|
mkdir -p $appsDir
|
|
mv $commandBinDir/marble $appsDir/Marble
|
|
ln -s $appsDir/Marble $commandBinDir/marble
|
|
# only keep marble-kde
|
|
rm -rf $commandBinDir/marble-qt
|
|
|
|
local MAJOR="`echo "$portVersion" | cut -d. -f1`"
|
|
local MIDDLE="`echo "$portVersion" | cut -d. -f2`"
|
|
local MINOR="`echo "$portVersion" | cut -d. -f3`"
|
|
sed \
|
|
-e "s|@APP_SIGNATURE@|$APP_SIGNATURE|" \
|
|
-e "s|@MAJOR@|$MAJOR|" \
|
|
-e "s|@MIDDLE@|$MIDDLE|" \
|
|
-e "s|@MINOR@|$MINOR|" \
|
|
$portDir/additional-files/marble.rdef.in > marble.rdef
|
|
|
|
addResourcesToBinaries marble.rdef $appsDir/Marble
|
|
|
|
addAppDeskbarSymlink $appsDir/Marble
|
|
|
|
prepareInstalledDevelLibs \
|
|
libastro \
|
|
libmarblewidget-qt6
|
|
|
|
packageEntries devel \
|
|
$developDir \
|
|
$dataDir/Qt6/mkspecs \
|
|
$libDir/cmake
|
|
}
|
|
|
|
TEST()
|
|
{
|
|
# 87% tests passed, 7 tests failed out of 54
|
|
export LIBRARY_PATH="$sourceDir/build/src/lib/astro:$sourceDir/build/src/lib/marble:\
|
|
$sourceDir/build/src/bin:$LIBRARY_PATH"
|
|
ctest --test-dir build --output-on-failure
|
|
}
|