wok annotate vim-tiny/receipt @ rev 25399
updated vim and vim-tiny (8.2.0664 -> 9.0.0133)
author | Hans-G?nter Theisgen |
---|---|
date | Tue Aug 02 14:18:25 2022 +0100 (22 months ago) |
parents | ac8ca9758df1 |
children | 54dc13c9ffd0 |
rev | line source |
---|---|
erjo@4784 | 1 # SliTaz package receipt. |
erjo@4784 | 2 |
erjo@4784 | 3 PACKAGE="vim-tiny" |
Hans-G?nter@25399 | 4 VERSION="9.0.0133" |
Hans-G?nter@25399 | 5 basever=${VERSION%.*} |
Hans-G?nter@25399 | 6 basever=${basever/./} |
pascal@18559 | 7 CATEGORY="editors" |
Hans-G?nter@22106 | 8 TAGS="text-editor" |
Hans-G?nter@22106 | 9 SHORT_DESC="Advanced text editor without GUI." |
erjo@4784 | 10 MAINTAINER="erjo@slitaz.org" |
pascal@15363 | 11 LICENSE="other" |
Hans-G?nter@22106 | 12 WEB_SITE="https://www.vim.org/" |
Hans-G?nter@22106 | 13 |
erjo@4784 | 14 SOURCE="vim" |
Hans-G?nter@22108 | 15 TARBALL="$SOURCE-$VERSION.tar.gz" |
Hans-G?nter@22106 | 16 WGET_URL="https://github.com/$SOURCE/$SOURCE/archive/v$VERSION.tar.gz" |
erjo@4784 | 17 |
pascal@15363 | 18 DEPENDS="ncurses" |
pascal@17716 | 19 BUILD_DEPENDS="ncurses-dev" |
pascal@15363 | 20 |
Hans-G?nter@22106 | 21 CONFIG_FILES="/etc/vim/vimrc" |
Hans-G?nter@22106 | 22 |
pascal@24055 | 23 current_version() |
pascal@24055 | 24 { |
pascal@24299 | 25 wget -O - ${WGET_URL%/arch*}/tags 2>/dev/null | \ |
pascal@24055 | 26 sed '/archive.*tar/!d;s|.*/v\(.*\).tar.*|\1|;q' |
pascal@24055 | 27 } |
pascal@24055 | 28 |
erjo@4784 | 29 # Rules to configure and make the package. |
erjo@4784 | 30 compile_rules() |
erjo@4784 | 31 { |
pascal@17716 | 32 export LDFLAGS="$LDFLAGS -ltinfo" |
manuelfloresv@9417 | 33 |
manuelfloresv@9417 | 34 # define the place for the global vimrc file (set to /etc/vim/vimrc) |
manuelfloresv@9417 | 35 # (patch from Arch Linux PKGBUILD) |
Hans-G?nter@23724 | 36 sed -i 's|^.*\(#define SYS_VIMRC_FILE\).*$|\1 "/etc/vim/vimrc"|' \ |
Hans-G?nter@23724 | 37 $src/src/feature.h |
al@18741 | 38 |
Hans-G?nter@25399 | 39 # 9.0.0133 unrecognised: |
Hans-G?nter@25399 | 40 # --disable-athena-check |
Hans-G?nter@25399 | 41 |
Hans-G?nter@22106 | 42 ./configure \ |
Hans-G?nter@22106 | 43 --prefix=/usr \ |
Hans-G?nter@22106 | 44 --cache-file=$PWD/config.cache \ |
Hans-G?nter@22106 | 45 --infodir=/usr/share/info \ |
Hans-G?nter@22106 | 46 --with-features=tiny \ |
Hans-G?nter@22106 | 47 --with-x=no \ |
Hans-G?nter@22106 | 48 --disable-gui \ |
Hans-G?nter@22106 | 49 --enable-multibyte \ |
Hans-G?nter@22106 | 50 --with-vim-name=$PACKAGE \ |
Hans-G?nter@22106 | 51 --disable-acl \ |
Hans-G?nter@22106 | 52 --disable-motif-check \ |
Hans-G?nter@22106 | 53 --mandir=/usr/share/man \ |
Hans-G?nter@22106 | 54 $CONFIGURE_ARGS && |
Hans-G?nter@22106 | 55 make \ |
Hans-G?nter@22106 | 56 VIMRCLOC=/etc/vim \ |
Hans-G?nter@25399 | 57 VIMRUNTIMEDIR=/usr/share/vim/vim$basever\ |
Hans-G?nter@22106 | 58 MAKE="make -e" && |
Hans-G?nter@22106 | 59 make DESTDIR=$DESTDIR install |
al@18741 | 60 |
slaxemulator@8751 | 61 mkdir -p $DESTDIR/etc/vim |
Hans-G?nter@23724 | 62 cp -a $src/runtime/vimrc_example.vim $DESTDIR/etc/vim/vimrc |
erjo@4784 | 63 } |
erjo@4784 | 64 |
erjo@4784 | 65 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@4784 | 66 genpkg_rules() |
erjo@4784 | 67 { |
Hans-G?nter@22106 | 68 mkdir -p $fs/usr/share |
Hans-G?nter@22106 | 69 mkdir -p $fs/etc |
al@18741 | 70 |
Hans-G?nter@22106 | 71 cp -a $install/usr/bin $fs/usr |
Hans-G?nter@22106 | 72 cp -a $install/usr/share/vim $fs/usr/share |
Hans-G?nter@22106 | 73 cp -a $install/etc/vim $fs/etc |
Hans-G?nter@22106 | 74 |
Hans-G?nter@25399 | 75 rm -f $fs/usr/share/vim/vim$basedir/tutor/* |
erjo@4784 | 76 } |
erjo@4784 | 77 |
erjo@4784 | 78 post_install() |
erjo@4784 | 79 { |
al@18741 | 80 cmd=$(readlink "$1/bin/vi") |
Hans-G?nter@22106 | 81 if [ "$cmd" != '/usr/bin/vim' ] |
Hans-G?nter@22106 | 82 then |
al@18741 | 83 echo '' |
al@18741 | 84 echo "**** Actual VI link : $cmd" |
al@18741 | 85 echo '' |
Hans-G?nter@25399 | 86 echo -n 'Do you want vim for /bin/vi (y/N) ? : ' |
Hans-G?nter@25399 | 87 read -t 30 anser |
Hans-G?nter@22106 | 88 if [ "$anser" = 'y' ] |
Hans-G?nter@22106 | 89 then |
al@18741 | 90 echo '' |
al@18741 | 91 action 'Removing vi link to make a new one pointing on /usr/bin/vim...' |
Hans-G?nter@25399 | 92 rm "$1/bin/vi" && |
Hans-G?nter@25399 | 93 ln -sf /usr/bin/vim-tiny "$1/bin/vi" |
al@18741 | 94 status |
Hans-G?nter@22106 | 95 else |
al@18741 | 96 echo '' |
al@18741 | 97 echo "Leaving /bin/vi to : $cmd" |
al@18741 | 98 fi |
al@18741 | 99 fi |
erjo@4784 | 100 } |
erjo@4784 | 101 |
erjo@4784 | 102 post_remove() |
erjo@4784 | 103 { |
Hans-G?nter@25399 | 104 # restore previous symbolic link |
pascal@18730 | 105 ln -sf /bin/busybox "$1/bin/vi" |
erjo@4784 | 106 } |