wok-6.x annotate vim/receipt @ rev 7957
Up: mlt-python-bindings to 0.6.0.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Sat Jan 15 17:23:12 2011 +0000 (2011-01-15) |
parents | f0086951d969 |
children | be13f25e790b |
rev | line source |
---|---|
erjo@250 | 1 # SliTaz package receipt. |
erjo@250 | 2 |
erjo@250 | 3 PACKAGE="vim" |
erjo@1354 | 4 VERSION="7.2" |
pankso@271 | 5 CATEGORY="development" |
erjo@250 | 6 SHORT_DESC="Advanced text editor" |
erjo@784 | 7 MAINTAINER="erjo@slitaz.org" |
pascal@5007 | 8 DEPENDS="ncurses gtk+ acl xorg-libXt" |
erjo@250 | 9 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
erjo@250 | 10 WEB_SITE="http://www.vim.org/" |
erjo@250 | 11 WGET_URL="ftp://ftp.vim.org/pub/vim/unix/$TARBALL" |
mallory@6286 | 12 CONFIG_FILES="/etc/vim/vimrc" |
jozee@4975 | 13 TAGS="text-editor" |
erjo@250 | 14 |
erjo@250 | 15 # Rules to configure and make the package. |
erjo@250 | 16 compile_rules() |
erjo@250 | 17 { |
pankso@1382 | 18 src="vim72" |
erjo@250 | 19 cd $src |
erjo@250 | 20 |
erjo@250 | 21 ./configure --prefix=/usr \ |
erjo@250 | 22 --cache-file=$PWD/config.cache \ |
erjo@250 | 23 --infodir=/usr/share/info \ |
erjo@250 | 24 --with-features=normal \ |
erjo@2927 | 25 --enable-gui=gtk2 \ |
rocky@7851 | 26 --enable-multibyte \ |
erjo@2927 | 27 --disable-motif-check \ |
erjo@2927 | 28 --disable-athena-check \ |
pascal@2948 | 29 --mandir=/usr/share/man $CONFIGURE_ARGS && |
erjo@250 | 30 |
mallory@3100 | 31 make VIMRCLOC=/etc/vim VIMRUNTIMEDIR=/usr/share/vim/$src MAKE="make -e" && |
erjo@250 | 32 make DESTDIR=$PWD/_pkg install |
erjo@250 | 33 } |
erjo@250 | 34 |
erjo@250 | 35 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@250 | 36 genpkg_rules() |
erjo@250 | 37 { |
pankso@1383 | 38 _pkg="$PWD/vim72/_pkg" |
erjo@2927 | 39 |
erjo@2927 | 40 mkdir -p $fs/usr $fs/usr/share $fs/etc/vim |
erjo@2927 | 41 |
erjo@250 | 42 cp -a $_pkg/usr/bin $fs/usr |
erjo@250 | 43 cp -a $_pkg/usr/share/vim $fs/usr/share |
erjo@2927 | 44 cp -a $WOK/$PACKAGE/vim72/runtime/vimrc_example.vim $fs/etc/vim/vimrc |
erjo@2927 | 45 rm -f $fs/usr/bin/*vimtutor |
erjo@2927 | 46 } |
erjo@250 | 47 |
erjo@250 | 48 |
erjo@250 | 49 |
erjo@250 | 50 # Rules to clean extras dirs or files |
erjo@250 | 51 clean_wok() |
erjo@250 | 52 { |
erjo@1354 | 53 rm -rf $PWD/vim72 2>/dev/null |
erjo@250 | 54 } |
erjo@250 | 55 |
erjo@250 | 56 post_install() |
erjo@250 | 57 { |
erjo@250 | 58 local root |
erjo@250 | 59 root=$1 |
erjo@250 | 60 echo "Processing post-install commands..." |
erjo@250 | 61 cmd=`readlink $root/bin/vi` |
erjo@250 | 62 if [ ! "$cmd" = "/usr/bin/vim" ]; then |
erjo@250 | 63 echo "" |
erjo@250 | 64 echo "**** Actual VI link : $cmd" |
erjo@250 | 65 echo "" |
erjo@250 | 66 echo -n "Do you want vim for /bin/vi (y/N) ? : "; read anser |
erjo@250 | 67 if [ "$anser" == "y" ]; then |
erjo@250 | 68 echo "" |
erjo@250 | 69 echo -n "Removing vi link to make a new one pointing on /usr/bin/vim..." |
erjo@1354 | 70 rm $root/bin/vi && ln -sf $root/usr/bin/vim $root/bin/vi |
erjo@250 | 71 status |
erjo@250 | 72 else |
erjo@250 | 73 echo "" |
erjo@250 | 74 echo "Leaving /bin/vi to : $cmd" |
erjo@250 | 75 fi |
erjo@250 | 76 fi |
erjo@250 | 77 } |
erjo@250 | 78 |
erjo@2531 | 79 post_remove() |
erjo@2531 | 80 { |
erjo@2531 | 81 # restore previous symlink |
erjo@2531 | 82 echo "Processing post-remove commands..." |
erjo@2531 | 83 ln -sf /bin/busybox /bin/vi |
erjo@2531 | 84 } |