blob: 9228d381f2964f6a1954626d8de9ad8d45530b89 (
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
|
# Maintainer: taotieren <admin@taotieren.com>
pkgname=notepad---git
pkgver=2.14.r1.g335b72c
pkgrel=1
pkgdesc="Notepad-- 是使用C++编写的轻量级文本编辑器, 简称ndd, 可以支持Window/Mac/Linux操作系统平台。"
arch=('x86_64')
url="https://gitee.com/cxasm/notepad--"
license=('GPL-3.0-or-later')
provides=(${pkgname%-git} notepadplugin)
conflicts=(${pkgname%-git})
_qt=qt5
depends=(
glibc
gcc-libs
hicolor-icon-theme
$_qt-base)
makedepends=(cmake
ninja
git
$_qt-tools
$_qt-xmlpatterns
qscintilla-$_qt)
source=("${pkgname}::git+${url}.git")
sha256sums=('SKIP')
pkgver() {
cd "${srcdir}/${pkgname}/"
git describe --long --tags | sed 's/^v//g;s/\([^-]*-g\)/r\1/;s/-/./g'
}
prepare()
{
git -C "${srcdir}/${pkgname}" clean -dfx
}
build() {
cd "${srcdir}/${pkgname}"
cp -rv how_build/* .
sed -i 's/\bintptr_t\b/__intptr_t/g' src/qscint/src/xmlMatchedTagsHighlighter.cpp
sed -i 's/\bintptr_t\b/__intptr_t/g' src/qscint/src/xmlMatchedTagsHighlighter.h
sed -i 's/NotePad--/notepad--/g' CMakeLists.txt
sed -i '7s/NotePad--/notepad--/' src/linux/usr/share/applications/NotePad--.desktop
cmake -D CMAKE_BUILD_TYPE=Release \
-D CMAKE_INSTALL_PREFIX=/usr \
-B build \
-G Ninja \
-W no-dev
ninja -C build
}
package() {
DESTDIR="${pkgdir}" ninja -C "${srcdir}"/${pkgname}/build install
}
|