wok-next annotate vim-tiny/receipt @ rev 20402
Up seed (3.8.1) use webkitgtk instead of libwebkit; add cogl for clutter; up clutter (1.26.2) using mesa17 instead of mesa; up gnome-games using mesa17 instead of mix 'mesa & mesa17'
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Tue Dec 05 17:49:11 2017 +0200 (2017-12-05) |
parents | f1752c8b2a2a |
children |
rev | line source |
---|---|
erjo@4784 | 1 # SliTaz package receipt. |
erjo@4784 | 2 |
erjo@4784 | 3 PACKAGE="vim-tiny" |
al@19582 | 4 VERSION="7.4" |
pascal@18559 | 5 CATEGORY="editors" |
erjo@4784 | 6 SHORT_DESC="Advanced text editor with no GUI" |
erjo@4784 | 7 MAINTAINER="erjo@slitaz.org" |
pascal@15363 | 8 LICENSE="other" |
erjo@4784 | 9 WEB_SITE="http://www.vim.org/" |
manuelfloresv@9417 | 10 CONFIG_FILES="/etc/vim/vimrc" |
jozee@4975 | 11 TAGS="text-editor" |
erjo@4784 | 12 |
al@19582 | 13 TARBALL="vim-$VERSION.tar.bz2" |
al@19582 | 14 WGET_URL="ftp://ftp.vim.org/pub/vim/unix/$TARBALL" |
al@19582 | 15 |
pascal@15363 | 16 DEPENDS="ncurses" |
pascal@17716 | 17 BUILD_DEPENDS="ncurses-dev" |
pascal@15363 | 18 |
erjo@4784 | 19 # Rules to configure and make the package. |
erjo@4784 | 20 compile_rules() |
erjo@4784 | 21 { |
al@19582 | 22 echo '#define SYS_VIMRC_FILE "/etc/vimrc"' >> src/feature.h |
al@18741 | 23 |
erjo@4784 | 24 ./configure --prefix=/usr \ |
al@18741 | 25 --with-features=tiny \ |
al@19582 | 26 --without-x \ |
al@18741 | 27 --disable-gui \ |
al@18741 | 28 --enable-multibyte \ |
al@18741 | 29 --with-vim-name=$PACKAGE \ |
al@18741 | 30 --disable-acl \ |
al@19582 | 31 $CONFIGURE_ARGS && |
al@19582 | 32 make && make install |
al@18741 | 33 |
slaxemulator@8751 | 34 mkdir -p $DESTDIR/etc/vim |
slaxemulator@8751 | 35 cp -a $src/runtime/vimrc_example.vim $DESTDIR/etc/vim/vimrc |
al@19582 | 36 |
al@19582 | 37 mkdir -p $install/usr/share/doc |
al@19582 | 38 mv $install/usr/share/vim/vim*/doc $install/usr/share/doc/$PACKAGE-$VERSION |
erjo@4784 | 39 } |
erjo@4784 | 40 |
erjo@4784 | 41 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@4784 | 42 genpkg_rules() |
erjo@4784 | 43 { |
al@19783 | 44 copy etc/ bin/ vim/ |
al@19582 | 45 rm -f $fs/usr/bin/*tutor |
al@19582 | 46 rm -rf $fs/usr/share/vim/vim*/tutor |
erjo@4784 | 47 } |
erjo@4784 | 48 |
erjo@4784 | 49 post_install() |
erjo@4784 | 50 { |
al@18741 | 51 cmd=$(readlink "$1/bin/vi") |
al@18741 | 52 if [ "$cmd" != '/usr/bin/vim' ]; then |
al@19582 | 53 echo |
al@18741 | 54 echo "**** Actual VI link : $cmd" |
al@19582 | 55 echo |
al@19582 | 56 echo -n 'Do you want vim for /bin/vi (y/N)? : '; read -t 30 anser |
al@18741 | 57 if [ "$anser" == 'y' ]; then |
al@19582 | 58 echo |
al@18741 | 59 action 'Removing vi link to make a new one pointing on /usr/bin/vim...' |
al@18741 | 60 rm "$1/bin/vi" && ln -sf /usr/bin/vim-tiny "$1/bin/vi" |
al@18741 | 61 status |
al@18741 | 62 else |
al@19582 | 63 echo |
al@19582 | 64 echo "Leaving /bin/vi to $cmd" |
al@18741 | 65 fi |
al@18741 | 66 fi |
erjo@4784 | 67 } |
erjo@4784 | 68 |
erjo@4784 | 69 post_remove() |
erjo@4784 | 70 { |
erjo@4784 | 71 # restore previous symlink |
pascal@18730 | 72 ln -sf /bin/busybox "$1/bin/vi" |
erjo@4784 | 73 } |