blob: 55e3ce48e6339dabf53d68c1e7f2fbc60ba7f6b7 (
plain)
1 # Description: Ncurse-based MPD console client
2 # URL: https://www.musicpd.org/
3 # Maintainer: Aaron Ball, nullspoon at oper dot io
4 # Depends on: boost ncurses libmpdclient python3-docutils
5 # Nice to have: python3-sphinx libpcre2
6
7 name=ncmpc
8 version=0.50
9 release=1
10 source=(https://www.musicpd.org/download/ncmpc/0/ncmpc-${version}.tar.xz
11 roles.rst)
12
13 nosphinx_process_man() {
14 local doc="${SRC}/${name}-${version}/doc/index.rst"
15 sed -i 's/.. option::/.. topic::/' "${doc}"
16 cat ${SRC}/roles.rst
17 head -n2 "${doc}"
18 printf -- '-------------------\nncmpc Documentation\n-------------------\n\n'
19 tail -n +3 "${doc}"
20 }
21
22 build() {
23 meson build ${name}-${version} \
24 --prefix=/usr \
25 --sysconfdir=/etc \
26 -D nls=disabled \
27 -D lyrics_screen=true
28 ninja -C build
29 DESTDIR=${PKG} ninja -C build install
30
31 mkdir -p ${PKG}/etc/ncmpc
32
33 install -m 0644 ${name}-${version}/doc/config.sample ${PKG}/etc/ncmpc/config
34 install -m 0644 ${name}-${version}/doc/keys.sample ${PKG}/etc/ncmpc/keys
35
36 if prt-get isinst python3-docutils; then
37 mkdir -p ${PKG}/usr/share/man/man1
38 nosphinx_process_man | rst2man > ${PKG}/usr/share/man/man1/${name}.1
39 gzip ${PKG}/usr/share/man/man1/${name}.1
40 fi
41
42 rm -rf ${PKG}/usr/share/doc
43 }
|