wok rev 250
ADD: vim
author | Eric Joseph-Alexandre <erjo@slitaz.org> |
---|---|
date | Fri Feb 22 11:22:36 2008 +0100 (2008-02-22) |
parents | c956bc99b845 |
children | 39ab194bbbef |
files | vim/receipt |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/vim/receipt Fri Feb 22 11:22:36 2008 +0100 1.3 @@ -0,0 +1,73 @@ 1.4 +# SliTaz package receipt. 1.5 + 1.6 +PACKAGE="vim" 1.7 +VERSION="7.1" 1.8 +CATEGORY="extra" 1.9 +SHORT_DESC="Advanced text editor" 1.10 +MAINTAINER="Erjo <erjo@slita.org>" 1.11 +DEPENDS="" 1.12 +TARBALL="$PACKAGE-$VERSION.tar.bz2" 1.13 +WEB_SITE="http://www.vim.org/" 1.14 +WGET_URL="ftp://ftp.vim.org/pub/vim/unix/$TARBALL" 1.15 + 1.16 +# Rules to configure and make the package. 1.17 +compile_rules() 1.18 +{ 1.19 + src="vim71" 1.20 + cd $src 1.21 + 1.22 + ./configure --prefix=/usr \ 1.23 + --cache-file=$PWD/config.cache \ 1.24 + --infodir=/usr/share/info \ 1.25 + --with-features=normal \ 1.26 + --enable-gui=no \ 1.27 + --without-x 1.28 + --mandir=/usr/share/man $CONFIGURE_ARGS 1.29 + 1.30 + make 1.31 + make DESTDIR=$PWD/_pkg install 1.32 +} 1.33 + 1.34 +# Rules to gen a SliTaz package suitable for Tazpkg. 1.35 +genpkg_rules() 1.36 +{ 1.37 + _pkg="$PWD/vim71/_pkg" 1.38 + mkdir -p $fs/usr $fs/usr/share 1.39 + cp -a $_pkg/usr/bin $fs/usr 1.40 + cp -a $_pkg/usr/share/vim $fs/usr/share 1.41 + 1.42 + rm -f $fs/usr/bin/vimtutor 1.43 + 1.44 + strip -s $fs/usr/bin/* 1.45 +} 1.46 + 1.47 + 1.48 +# Rules to clean extras dirs or files 1.49 +clean_wok() 1.50 +{ 1.51 + rm -rf $PWD/vim71 2>/dev/null 1.52 +} 1.53 + 1.54 +post_install() 1.55 +{ 1.56 + local root 1.57 + root=$1 1.58 + echo "Processing post-install commands..." 1.59 + cmd=`readlink $root/bin/vi` 1.60 + if [ ! "$cmd" = "/usr/bin/vim" ]; then 1.61 + echo "" 1.62 + echo "**** Actual VI link : $cmd" 1.63 + echo "" 1.64 + echo -n "Do you want vim for /bin/vi (y/N) ? : "; read anser 1.65 + if [ "$anser" == "y" ]; then 1.66 + echo "" 1.67 + echo -n "Removing vi link to make a new one pointing on /usr/bin/vim..." 1.68 + rm $root/bin/vi && ln -s $root/usr/bin/vim $root/bin/vi 1.69 + status 1.70 + else 1.71 + echo "" 1.72 + echo "Leaving /bin/vi to : $cmd" 1.73 + fi 1.74 + fi 1.75 +} 1.76 +