blob: 281f78eff5a034a99425ff65bd66211304dc8369 (
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
|
#!/bin/sh -e
mkdir temp
TMPDIR="$PWD/temp"
(
cd db/build_unix
../dist/configure \
--prefix=/usr \
--disable-shared
make
make DESTDIR="$TMPDIR" install
)
(
cd nvi
for patch in ../nvi*.patch; do
printf 'Applying %s\n' "$patch"
patch -Np1 < "$patch"
done
export CFLAGS="$CFLAGS -I$TMPDIR/usr/include"
export LDFLAGS="$LDFLAGS -L$TMPDIR/usr/lib -static"
export OPTFLAG="$CFLAGS"
export CC="${CC:-cc} --static"
cd dist
./configure \
--prefix=/usr \
--enable-widechar \
--disable-shared \
vi_cv_path_preserve=/var/tmp \
vi_cv_sprintf_count=yes
sed -i -e '/define.*_PATH_MSGCAT/ s/".*"/"\/usr\/share\/vi\/catalog\/"/' pathnames.h
make
install -Dm755 vi "$1/usr/bin/vi"
)
|