blob: 1f061732171e65604d959947ce1634c2fef454cc (
plain) (
blame)
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
|
#!/bin/bash
name=ncurses
version=6.1
revision=0
sources=(
"http://mirror.rit.edu/gnu/${name}/${name}-${version}.tar.gz"
)
build_depends=(
"automake"
"autoconf"
)
depends=(
"base"
)
function prepare() {
tar xf ${name}-${version}.tar.gz
cd ${name}-${version}
}
function build() {
./configure --prefix=$prefix \
--without-static \
--with-shared \
--with-normal \
--without-debug \
--without-ada \
--enable-widec \
--enable-pc-files \
--with-cxx-bindings \
--with-cxx-shared \
--with-manpage-format=normal \
--with-pkg-config-libdir="${prefix}/lib/pkgconfig"
make -j${maxjobs}
}
function package() {
make install DESTDIR="${destdir}"
# Arch linux maintainers have the right idea here...
# fool packages looking to link to non-wide-character ncurses libraries
for lib in ncurses ncurses++ form panel menu; do
echo "INPUT(-l${lib}w)" > "${destdir}/${prefix}/lib/lib${lib}.so"
ln -s ${lib}w.pc "${destdir}/${prefix}/lib/pkgconfig/${lib}.pc"
done
for lib in tic tinfo; do
echo "INPUT(libncursesw.so.${version:0:1})" > "${destdir}/${prefix}/lib/lib${lib}.so"
ln -s libncursesw.so.${version:0:1} "${destdir}/${prefix}/lib/lib${lib}.so.${version:0:1}"
ln -s ncursesw.pc "${destdir}${prefix}/lib/pkgconfig/${lib}.pc"
done
# some packages look for -lcurses during build
echo 'INPUT(-lncursesw)' > "${destdir}${prefix}/lib/libcursesw.so"
ln -s libncurses.so "${destdir}/${prefix}/lib/libcurses.so"
# some packages include from ncurses/
ln -s ncurses "${destdir}/${prefix}/include/ncursesw"
}
|