Rebuild all packages with control.tar.gz
[termux-packages] / packages / ncurses / build.sh
CommitLineData
59f0d218
FF
1TERMUX_PKG_HOMEPAGE=http://invisible-island.net/ncurses/
2TERMUX_PKG_DESCRIPTION="Library for text-based user interfaces in a terminal-independent manner"
c9a1a699 3TERMUX_PKG_VERSION=6.0.20170909
86c94e04 4TERMUX_PKG_REVISION=1
c9a1a699 5TERMUX_PKG_SHA256=d504add16629f6c68b7a28a866833d17e89df0942185646bfd35958eb9f6d3e2
408001f3 6TERMUX_PKG_SRCURL=http://invisible-mirror.net/archives/ncurses/current/ncurses-${TERMUX_PKG_VERSION:0:3}-${TERMUX_PKG_VERSION:4}.tgz
59f0d218 7# --without-normal disables static libraries:
aaff9cad
FF
8TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
9ac_cv_header_locale_h=no
10--enable-const
11--enable-ext-colors
12--enable-ext-mouse
13--enable-overwrite
14--enable-pc-files
15--enable-widec
16--mandir=$TERMUX_PREFIX/share/man
17--without-ada
18--without-cxx-binding
19--without-debug
20--without-normal
21--without-static
22--without-tests
23--with-shared
24"
0411bce9 25TERMUX_PKG_INCLUDE_IN_DEVPACKAGE="
1a580cee 26share/man/man1/ncursesw6-config.1*
0411bce9
S
27bin/ncursesw6-config
28"
2e27b20c
FF
29TERMUX_PKG_RM_AFTER_INSTALL="
30bin/captoinfo
31bin/infotocap
1a580cee
FF
32share/man/man1/captoinfo.1*
33share/man/man1/infotocap.1*
34share/man/man5
35share/man/man7
2e27b20c
FF
36"
37
38termux_step_pre_configure() {
39 TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --with-pkg-config-libdir=$PKG_CONFIG_LIBDIR"
40}
59f0d218 41
59f0d218
FF
42termux_step_post_make_install () {
43 cd $TERMUX_PREFIX/lib
44 for lib in form menu ncurses panel; do
45 for file in lib${lib}w.so*; do
46 ln -s -f $file `echo $file | sed 's/w//'`
47 done
48 (cd pkgconfig && ln -s -f ${lib}w.pc `echo $lib | sed 's/w//'`.pc)
49 done
50
aed0f112
FF
51 # Some packages wants this:
52 cd $TERMUX_PREFIX/include/
53 rm -Rf ncursesw
54 mkdir ncursesw
55 cd ncursesw
56 ln -s ../{ncurses.h,termcap.h,panel.h,unctrl.h,menu.h,form.h,tic.h,nc_tparm.h,term.h,eti.h,term_entry.h,ncurses_dll.h,curses.h} .
59f0d218 57}
9ff2bc5d
FF
58
59termux_step_post_massage () {
60 # Strip away 30 years of cruft to decrease size.
86cb8449 61 local TI=$TERMUX_PKG_MASSAGEDIR/$TERMUX_PREFIX/share/terminfo
9ff2bc5d 62 mv $TI $TERMUX_PKG_TMPDIR/full-terminfo
fc19ac86 63 mkdir -p $TI/{a,d,e,n,l,p,r,s,t,v,x}
9ff2bc5d 64 cp $TERMUX_PKG_TMPDIR/full-terminfo/a/ansi $TI/a/
85fba239
FF
65 cp $TERMUX_PKG_TMPDIR/full-terminfo/d/{dtterm,dumb} $TI/d/
66 cp $TERMUX_PKG_TMPDIR/full-terminfo/e/eterm-color $TI/e/
9ff2bc5d
FF
67 cp $TERMUX_PKG_TMPDIR/full-terminfo/n/nsterm $TI/n/
68 cp $TERMUX_PKG_TMPDIR/full-terminfo/l/linux $TI/l/
69 cp $TERMUX_PKG_TMPDIR/full-terminfo/p/putty{,-256color} $TI/p/
70 cp $TERMUX_PKG_TMPDIR/full-terminfo/r/rxvt{,-256color} $TI/r/
71 cp $TERMUX_PKG_TMPDIR/full-terminfo/s/screen{,2,-256color} $TI/s/
fc19ac86 72 cp $TERMUX_PKG_TMPDIR/full-terminfo/t/tmux{,-256color} $TI/t/
9ff2bc5d
FF
73 cp $TERMUX_PKG_TMPDIR/full-terminfo/v/{vt52,vt100,vt102} $TI/v/
74 cp $TERMUX_PKG_TMPDIR/full-terminfo/x/xterm{,-color,-new,-16color,-256color,+256color} $TI/x/
86cb8449
FF
75
76 local RXVT_TAR=$TERMUX_PKG_CACHEDIR/rxvt-unicode-9.22.tar.bz2
77 termux_download http://dist.schmorp.de/rxvt-unicode/rxvt-unicode-9.22.tar.bz2 \
78 $RXVT_TAR \
79 e94628e9bcfa0adb1115d83649f898d6edb4baced44f5d5b769c2eeb8b95addd
80 cd $TERMUX_PKG_TMPDIR
81 local TI_FILE=rxvt-unicode-9.22/doc/etc/rxvt-unicode.terminfo
82 tar xf $RXVT_TAR $TI_FILE
83 tic -x -o $TI $TI_FILE
9ff2bc5d 84}