blob: de4640794ff6226e857a0f95b441a89a829ccf04 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
# Maintainer : Arnaud Dovi <mr.dovi@gmail.com>
# Contributor : SharkEzz <icraft640@gmail.com>
# Contributor : Nikola Milinković <nikmil@gmail.com>
# WITH_KNOTIFICATION = 0 -> Default notifier is use simply qt5
# WITH_KNOTIFICATION = 1 -> Enable the Plasma/knotifications support notifier
WITH_KNOTIFICATION=0
# WITH_DARK_ICON = 0 -> Default icons
# WITH_DARK_ICON = 1 -> Replace the green icon by a dark one (dark themes support)
WITH_DARK_ICON=1
PARALLEL_JOBS=$(nproc)
pkgname=octopi-git
pkgver=0.16.2.r31.d98b3541
pkgrel=1
pkgdesc="This is Octopi, a powerful Pacman frontend using Qt libs"
arch=('x86_64')
url="https://github.com/aarnt/octopi"
license=('GPL2')
depends=(
'sudo'
'pkgfile'
'qtermwidget'
'qt-sudo'
'alpm_octopi_utils-git'
)
makedepends=(
'git'
'qt6-base'
'qt6-tools'
)
provides=(
'octopi'
'octopi-cachecleaner'
'octopi-helper'
'octopi-notifier'
'octopi-repoeditor'
'octopi-sudo'
)
conflicts=(
'octopi'
'octopi-cachecleaner'
'octopi-helper'
'octopi-notifier'
'octopi-repoeditor'
'octopi-sudo'
'octopi-dev'
'octopi-kde-git'
'octopi-notifier-frameworks'
'octopi-notifier-qt5'
'octopi-notifier-noknotify'
)
#install=octopi.install
source=(
'git+https://github.com/aarnt/octopi.git'
'octopi_dark.png'
)
sha256sums=('SKIP'
'49aa640be835eb9ccf216f44a2d86aba3b39bf349e62b855192096526883cdc0')
pkgver() {
cd "${pkgname/-git/}" || exit
printf "%s" "$(git describe --long --tags | sed 's/^v//;s/\([^-]*-\)g/r\1/;s/-/./g')"
}
prepare() {
cd "${pkgname/-git/}" || exit
[[ "$WITH_KNOTIFICATION" == "1" ]] && sed -e "s|DEFINES += ALPM_BACKEND #KSTATUS|DEFINES += ALPM_BACKEND KSTATUS|" -i notifier/octopi-notifier.pro
if [[ "$WITH_DARK_ICON" -eq "1" ]]; then
cp resources/images/octopi_green.png resources/images/octopi_green.bak.png
cp "${srcdir}/octopi_dark.png" resources/images/octopi_green.png
fi
cp resources/images/octopi_green.png resources/images/octopi.png
# https://github.com/aarnt/octopi/commit/2250904a902fca96ea16adf463400fbda913aa70
#patch --forward --strip=2 --input="${srcdir}/2250904a902fca96ea16adf463400fbda913aa70.patch"
}
build() {
cd "${pkgname/-git/}" || exit
echo "Starting build..."
qmake6 PREFIX=/usr MAKEFLAGS="${MAKEFLAGS} -j${PARALLEL_JOBS}" QMAKE_CFLAGS="${CFLAGS} -j4" QMAKE_CXXFLAGS="${CXXFLAGS}" QMAKE_LFLAGS="${LDFLAGS}" octopi.pro
make -j${PARALLEL_JOBS}
_subdirs="cachecleaner helper notifier repoeditor"
for _subdir in $_subdirs; do
pushd $_subdir
echo "Building octopi-$_subdir..."
qmake6 PREFIX=/usr MAKEFLAGS="${MAKEFLAGS} -j${PARALLEL_JOBS}" QMAKE_CFLAGS="${CFLAGS}" QMAKE_CXXFLAGS="${CXXFLAGS}" QMAKE_LFLAGS="${LDFLAGS}" "octopi-$_subdir.pro"
make -j${PARALLEL_JOBS}
popd
done
}
package() {
cd "${pkgname/-git/}" || exit
install -d "$pkgdir"/usr/local/bin
make INSTALL_ROOT="${pkgdir}" install
_subdirs="cachecleaner helper notifier repoeditor"
for _subdir in $_subdirs; do
pushd $_subdir
make INSTALL_ROOT="${pkgdir}" install
popd
done
ln -s /usr/bin/qt-sudo "$pkgdir"/usr/local/bin/qt-sudo
}
|