wok-current annotate gvim/receipt @ rev 22465
updated acpid (2.0.31 -> 2.0.32)
author | Hans-G?nter Theisgen |
---|---|
date | Fri Dec 27 16:26:35 2019 +0100 (2019-12-27) |
parents | bd87193daed4 |
children | e9af2ddc813b |
rev | line source |
---|---|
erjo@2928 | 1 # SliTaz package receipt. |
erjo@2928 | 2 |
erjo@2928 | 3 PACKAGE="gvim" |
Hans-G?nter@21019 | 4 VERSION="8.1" |
pascal@18559 | 5 CATEGORY="editors" |
Hans-G?nter@21019 | 6 TAGS="text-editor" |
Hans-G?nter@21019 | 7 SHORT_DESC="Advanced text editor, with gtk+ GUI." |
erjo@2928 | 8 MAINTAINER="erjo@slitaz.org" |
pascal@15600 | 9 LICENSE="other" |
Hans-G?nter@21019 | 10 WEB_SITE="https://www.vim.org/" |
pascal@22432 | 11 PROVIDES="xxd" |
Hans-G?nter@21019 | 12 |
gokhlayeh@9147 | 13 SOURCE="vim" |
gokhlayeh@9147 | 14 TARBALL="$SOURCE-$VERSION.tar.bz2" |
gokhlayeh@9147 | 15 WGET_URL="ftp://ftp.vim.org/pub/vim/unix/$TARBALL" |
Hans-G?nter@21019 | 16 |
Hans-G?nter@21019 | 17 DEPENDS="gtk+ ncurses xorg-libXau xorg-libXdmcp xorg-libXt" |
Hans-G?nter@21019 | 18 BUILD_DEPENDS="gtk+-dev" |
gokhlayeh@9147 | 19 CONFIG_FILES="/etc/vim/vimrc" |
pascal@15600 | 20 |
gokhlayeh@9131 | 21 # Rules to configure and make the package. |
gokhlayeh@9131 | 22 compile_rules() |
gokhlayeh@9131 | 23 { |
pascal@17751 | 24 export LDFLAGS="$LDFLAGS -ltinfo" |
manuelfloresv@9417 | 25 |
manuelfloresv@9417 | 26 # define the place for the global vimrc file (set to /etc/vim/vimrc) |
manuelfloresv@9417 | 27 # (patch from Arch Linux PKGBUILD) |
Hans-G?nter@21019 | 28 sed -i 's|^.*\(#define SYS_VIMRC_FILE\).*$|\1 "/etc/vim/vimrc"|' \ |
Hans-G?nter@21019 | 29 $src/src/feature.h |
manuelfloresv@9417 | 30 # and global gvimrc file (set to /etc/vim/gvimrc) |
Hans-G?nter@21019 | 31 sed -i 's|^.*\(#define SYS_GVIMRC_FILE\).*$|\1 "/etc/vim/gvimrc"|' \ |
Hans-G?nter@21019 | 32 $src/src/feature.h |
al@18303 | 33 |
Hans-G?nter@21019 | 34 ./configure \ |
Hans-G?nter@21019 | 35 --prefix=/usr \ |
Hans-G?nter@21019 | 36 --cache-file=$PWD/config.cache \ |
Hans-G?nter@21019 | 37 --infodir=/usr/share/info \ |
Hans-G?nter@21019 | 38 --mandir=/usr/share/man \ |
Hans-G?nter@21019 | 39 --with-features=normal \ |
Hans-G?nter@21019 | 40 --with-x=yes \ |
Hans-G?nter@21019 | 41 --enable-gui=gtk2 \ |
Hans-G?nter@21019 | 42 --enable-multibyte \ |
Hans-G?nter@21019 | 43 --disable-athena-check \ |
Hans-G?nter@21019 | 44 --disable-motif-check \ |
al@18303 | 45 $CONFIGURE_ARGS && |
al@18303 | 46 |
Hans-G?nter@21019 | 47 make VIMRCLOC=/etc/vim VIMRUNTIMEDIR=/usr/share/vim/vim81 MAKE="make -e" && |
gokhlayeh@9131 | 48 make DESTDIR=$DESTDIR install |
Hans-G?nter@21019 | 49 |
gokhlayeh@9131 | 50 mkdir -p $DESTDIR/etc/vim |
Hans-G?nter@21019 | 51 cp -a $src/runtime/vimrc_example.vim $DESTDIR/etc/vim/vimrc |
gokhlayeh@9131 | 52 } |
gokhlayeh@9131 | 53 |
erjo@2928 | 54 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@2928 | 55 genpkg_rules() |
erjo@2928 | 56 { |
Hans-G?nter@21019 | 57 mkdir -p \ |
Hans-G?nter@21019 | 58 $fs/usr/share/icons/hicolor/16x16/apps \ |
Hans-G?nter@21019 | 59 $fs/usr/share/applications \ |
Hans-G?nter@21019 | 60 $fs/etc |
gokhlayeh@9131 | 61 |
Hans-G?nter@21019 | 62 cp -a $install/usr/bin $fs/usr |
Hans-G?nter@21019 | 63 cp -a $install/usr/share/vim $fs/usr/share |
Hans-G?nter@21019 | 64 cp -a $src/runtime/vim16x16.png $fs/usr/share/icons/hicolor/16x16/apps/gvim.png |
Hans-G?nter@21019 | 65 cp -a stuff/gvim.desktop $fs/usr/share/applications |
Hans-G?nter@21019 | 66 cp -a $install/etc/vim $fs/etc |
erjo@2928 | 67 } |
erjo@2928 | 68 |
manuelfloresv@9417 | 69 post_install() |
manuelfloresv@9417 | 70 { |
pascal@18730 | 71 cmd=$(readlink "$1/bin/vi") |
pascal@20892 | 72 if [ ! "$cmd" = '/usr/bin/vim' ]; then |
al@18303 | 73 echo "" |
al@18303 | 74 echo "**** Actual VI link : $cmd" |
al@18303 | 75 echo "" |
al@18303 | 76 echo -n "Do you want vim for /bin/vi (y/N) ? : "; read -t 30 answer |
pascal@20892 | 77 if [ "$answer" = 'y' ]; then |
al@18303 | 78 echo "" |
al@18303 | 79 echo -n "Removing vi link to make a new one pointing on /usr/bin/vim..." |
pascal@18730 | 80 rm "$1/bin/vi" && ln -sf /usr/bin/vim "$1/bin/vi" |
al@18303 | 81 status |
al@18303 | 82 else |
al@18303 | 83 echo "" |
al@18303 | 84 echo "Leaving /bin/vi to : $cmd" |
al@18303 | 85 fi |
al@18303 | 86 fi |
manuelfloresv@9417 | 87 } |
erjo@2928 | 88 |
manuelfloresv@9417 | 89 post_remove() |
manuelfloresv@9417 | 90 { |
al@18303 | 91 # restore previous symlink |
pascal@18730 | 92 ln -sf busybox "$1/bin/vi" |
manuelfloresv@9417 | 93 } |