source: scripts/host-scripts/host-ncurses.sh@ 834dec0

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 834dec0 was 617118d, checked in by Jim Gifford <clfs@…>, 19 years ago

r561@server (orig r559): root | 2005-06-05 02:38:49 -0700
Fixed Directory Structure

  • Property mode set to 100755
File size: 1.5 KB
Line 
1#!/bin/bash
2
3### NCURSES ###
4
5cd ${SRC}
6LOG=ncurse-buildhost.log
7
8unpack_tarball ncurses-${NCURSES_VER} &&
9cd ${PKGDIR}
10
11# replace some deprecated headers
12# strstream deprecated in favour of sstream
13cd c++
14test -f cursesw.h-ORIG ||
15 mv cursesw.h cursesw.h-ORIG
16sed 's/include <strstream.h>/include <sstream>/g' ./cursesw.h-ORIG > ./cursesw.h
17
18# CHECK THIS... Should only affect ncurses 5.2 and less,
19# must check whether vsscanf is picked up or not in 5.3
20
21test 5.2 = "${NCURSES_VER}" &&
22{
23 # Apply cursesw.cc vsscanf patch
24 # Unsure who provided the original patch used.
25 # Please contact the authors so we can attribute you correctly.
26 test -f ./cursesw.cc-ORIG ||
27 cp cursesw.cc cursesw.cc-ORIG
28 grep -v strstreambuf cursesw.cc-ORIG |
29 sed 's@ss.vscan(@::vsscanf(buf, @' > cursesw.cc
30}
31cd ${SRC}/${PKGDIR}
32
33max_log_init Ncurses ${NCURSES_VER} "buildhost (static)" ${CONFLOGS} ${LOG}
34CC="${CC-gcc}" ./configure --prefix=${HST_TOOLS} \
35 --without-debug \
36 --without-cxx \
37 --without-cxx-binding \
38 >> ${LOGFILE} 2>&1 &&
39echo " o Configure OK" &&
40
41min_log_init ${BUILDLOGS} &&
42make \
43 >> ${LOGFILE} 2>&1 &&
44echo " o Build OK" &&
45
46min_log_init ${INSTLOGS} &&
47make install \
48 >> ${LOGFILE} 2>&1 &&
49echo " o ALL OK" || barf
50
51chmod 755 ${HST_TOOLS}/lib/*.${NCURSES_VER} &&
52ln -s libncurses.a ${HST_TOOLS}/lib/libcurses.a
53
54#ldconfig
55
56# Some braindead apps (util-linux) don't check for term.h under include/ncurses
57# Create link
58ln -sf ncurses/term.h ${HST_TOOLS}/include
59# Also create curses.h symlink
60ln -sf ncurses/curses.h ${HST_TOOLS}/include
61
Note: See TracBrowser for help on using the repository browser.