wok view vim-tiny/receipt @ rev 16814

Up pcre and pcre-dev to version 8.35
author Yuri Pourre <yuripourre@gmail.com>
date Thu Jul 10 22:42:36 2014 -0300 (2014-07-10)
parents 749ffdd335d7
children d9d7fcbb1ab3
line source
1 # SliTaz package receipt.
3 PACKAGE="vim-tiny"
4 VERSION="7.3"
5 CATEGORY="development"
6 SHORT_DESC="Advanced text editor with no GUI"
7 MAINTAINER="erjo@slitaz.org"
8 LICENSE="other"
9 SOURCE="vim"
10 TARBALL="$SOURCE-$VERSION.tar.bz2"
11 WEB_SITE="http://www.vim.org/"
12 WGET_URL="ftp://ftp.vim.org/pub/vim/unix/$TARBALL"
13 CONFIG_FILES="/etc/vim/vimrc"
14 TAGS="text-editor"
16 DEPENDS="ncurses"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 cd $src
23 # define the place for the global vimrc file (set to /etc/vim/vimrc)
24 # (patch from Arch Linux PKGBUILD)
25 sed -i 's|^.*\(#define SYS_VIMRC_FILE\).*$|\1 "/etc/vim/vimrc"|' $src/src/feature.h
27 ./configure --prefix=/usr \
28 --cache-file=$PWD/config.cache \
29 --infodir=/usr/share/info \
30 --with-features=tiny \
31 --with-x=no \
32 --disable-gui \
33 --enable-multibyte \
34 --with-vim-name=$PACKAGE \
35 --disable-acl \
36 --disable-motif-check \
37 --disable-athena-check \
38 --mandir=/usr/share/man $CONFIGURE_ARGS &&
40 make VIMRCLOC=/etc/vim VIMRUNTIMEDIR=/usr/share/vim/vim73 MAKE="make -e" &&
41 make DESTDIR=$DESTDIR install
42 mkdir -p $DESTDIR/etc/vim
43 cp -a $src/runtime/vimrc_example.vim $DESTDIR/etc/vim/vimrc
44 }
46 # Rules to gen a SliTaz package suitable for Tazpkg.
47 genpkg_rules()
48 {
49 mkdir -p $fs/usr/share $fs/etc
51 cp -a $install/usr/bin $fs/usr
52 cp -a $install/usr/share/vim $fs/usr/share
53 cp -a $install/etc/vim $fs/etc
54 rm -f $fs/usr/bin/*tutor
55 }
57 post_install()
58 {
59 local root
60 root=$1
61 echo "Processing post-install commands..."
62 cmd=`readlink $root/bin/vi`
63 if [ ! "$cmd" = "/usr/bin/vim" ]; then
64 echo ""
65 echo "**** Actual VI link : $cmd"
66 echo ""
67 echo -n "Do you want vim for /bin/vi (y/N) ? : "; read -t 30 anser
68 if [ "$anser" == "y" ]; then
69 echo ""
70 echo -n "Removing vi link to make a new one pointing on /usr/bin/vim..."
71 rm $root/bin/vi && ln -sf $root/usr/bin/vim-tiny $root/bin/vi
72 status
73 else
74 echo ""
75 echo "Leaving /bin/vi to : $cmd"
76 fi
77 fi
78 }
80 post_remove()
81 {
82 # restore previous symlink
83 echo "Processing post-remove commands..."
84 ln -sf /bin/busybox $1/bin/vi
85 }