2023-02-19 13:52:45 +00:00
# Maintainer: Knut Ahlers
pkgname = chatterino2-dankerino-git
2024-07-16 17:30:11 +00:00
pkgver = 2024.07.16
2024-06-29 12:32:45 +00:00
pkgrel = 1
2023-02-19 13:52:45 +00:00
pkgdesc = "Fork of Chatterino 2"
arch = ( any)
url = https://github.com/Mm2PL/dankerino
license = ( 'MIT' )
2024-06-29 12:28:57 +00:00
depends = ( 'qt6-base' 'qt6-tools' 'boost-libs' 'openssl' 'qt6-imageformats' 'qtkeychain-qt6' 'qt6-5compat' 'qt6-svg' )
makedepends = ( 'git' 'boost' 'cmake' )
2023-02-19 13:52:45 +00:00
optdepends = (
'streamlink: For piping streams to video players'
'pulseaudio: For audio output'
)
provides = ( 'chatterino' )
conflicts = ( 'chatterino' )
2024-06-29 12:28:57 +00:00
# We temporarily disable LTO since we get an ICE when compiling with gcc since this commit https://github.com/Chatterino/chatterino2/commit/ed20e71db4c957d3b2a8ce9350b847f4c805cb83
# Bug report tracking https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114501
options = ( '!lto' )
2023-02-19 13:52:45 +00:00
source = ( " git+ ${ url } .git#tag=nightly-build " )
2024-07-16 17:30:11 +00:00
sha512sums = ( 'f0da04f1ea5511cc9cd0f348da8b0e655cf92aa5ba32aa8dee9665372f85a4c312dd257d55a3e43c488d33be366361d2b1b3b107a1b6a6c4edbd4080ef0125e6' )
2023-02-19 13:52:45 +00:00
build( ) {
cd " ${ srcdir } /dankerino "
mkdir -p build
cd build
2024-06-29 12:28:57 +00:00
declare -a flags
if [ [ $CXXFLAGS = = *"-flto" * ] ] ; then
flags += ( "-DCHATTERINO_LTO=ON" )
fi
2023-02-19 13:52:45 +00:00
cmake \
-DCMAKE_BUILD_TYPE= Release \
-DUSE_SYSTEM_QTKEYCHAIN= ON \
-DUSE_PRECOMPILED_HEADERS= OFF \
2024-06-29 12:28:57 +00:00
-DBUILD_WITH_QT6= ON \
-DCHATTERINO_UPDATER= OFF \
-DCHATTERINO_PLUGINS= ON \
" ${ flags [@] } " \
2023-02-19 13:52:45 +00:00
..
2024-06-29 12:28:57 +00:00
cmake --build .
2023-02-19 13:52:45 +00:00
}
package( ) {
cd " $srcdir /dankerino "
if [ -f "build/bin/chatterino" ] && [ -x "build/bin/chatterino" ] ; then
echo "Getting chatterino binary from bin folder"
install -Dm755 "build/bin/chatterino" " $pkgdir /usr/bin/chatterino "
else
echo "Getting chatterino binary from NON-BIN folder"
# System ccache is enabled, causing the binary file to not fall into the bin folder
# Temporary solution until we have figured out a way to stabilize the ccache output
install -Dm755 "build/chatterino" " $pkgdir /usr/bin/chatterino "
fi
install -Dm644 "resources/com.chatterino.chatterino.desktop" " $pkgdir /usr/share/applications/com.chatterino.chatterino.desktop "
install -Dm644 "resources/icon.png" " $pkgdir /usr/share/pixmaps/chatterino.png "
}
pkgver( ) {
cd " ${ srcdir } /dankerino "
printf "r%s.%s" " $( git rev-list --count HEAD) " " $( git rev-parse --short HEAD) "
}
prepare( ) {
cd " ${ srcdir } /dankerino "
git submodule update --init --recursive
}