Contents of /trunk/core/vim/vim-7.2-r1.smage2
Parent Directory | Revision Log
Revision 28 -
(show annotations)
(download)
Fri Oct 10 23:25:33 2008 UTC (15 years, 7 months ago) by niro
File size: 2862 byte(s)
Fri Oct 10 23:25:33 2008 UTC (15 years, 7 months ago) by niro
File size: 2862 byte(s)
- moved to 'core'
1 | # $Header: /magellan-cvs/smage/vim/vim-7.1-r2.smage2,v 1.1 2008/02/11 23:02:02 niro Exp $ |
2 | |
3 | PNAME="vim" |
4 | PVER="7.2" |
5 | PBUILD="r1" |
6 | |
7 | PATCH_LEVEL="025" |
8 | |
9 | PCATEGORIE="app-editors" |
10 | STATE="unstable" |
11 | |
12 | DESCRIPTION="Vi IMproved!" |
13 | HOMEPAGE="http://www.vim.org/" |
14 | |
15 | DEPEND=">= sys-libs/ncurses-5.6" |
16 | |
17 | SDEPEND=">= sys-apps/sed-4 |
18 | >= sys-dev/automake-3 |
19 | >= sys-dev/autoconf-4" |
20 | |
21 | PROVIDE="virtual/editor" |
22 | |
23 | SRCFILE="${PNAME}-${PVER}.tar.bz2" |
24 | SRCDIR="${BUILDDIR}/${PNAME}${PVER/.}" |
25 | |
26 | LINGUAS="${PNAME}-${PVER}-lang.tar.gz" |
27 | |
28 | sminclude mtools |
29 | |
30 | SRC_URI=( |
31 | ftp://ftp.vim.org/pub/vim/unix/${SRCFILE} |
32 | ftp://ftp.vim.org/pub/vim/extra/${LINGUAS} |
33 | mirror://${PNAME}/${SRCFILE} |
34 | mirror://${PNAME}/${LINGUAS} |
35 | $(for ((i=1;i <= PATCH_LEVEL; i++)) |
36 | do |
37 | ver=00${i} |
38 | [[ ${i} -ge 10 ]] && ver=0${i} |
39 | [[ ${i} -ge 100 ]] && ver=${i} |
40 | echo "ftp://ftp.vim.org/pub/vim/patches/${PVER}/${PVER}.${ver}" |
41 | done) |
42 | ) |
43 | |
44 | UP2PVER="${PVER}.${PATCH_LEVEL}" |
45 | UP2DATE="updatecmd ${HOMEPAGE} | grep 'current version' | sed 's/.* \([0-9].*[0-9]\).*/\1/'" |
46 | |
47 | src_prepare() |
48 | { |
49 | munpack ${SRCFILE} || die |
50 | munpack ${LINGUAS} || die |
51 | cd ${SRCDIR} |
52 | |
53 | # # apply all upstream patches |
54 | local i |
55 | local ver |
56 | for ((i=1; i <= PATCH_LEVEL; i++)) |
57 | do |
58 | # excludes (patches for extra and non linux only) |
59 | [[ ${i} = 3 ]] && continue # win32 |
60 | [[ ${i} = 7 ]] && continue # mac |
61 | [[ ${i} = 41 ]] && continue # amiga dos os2 vms |
62 | [[ ${i} = 65 ]] && continue # win32 |
63 | [[ ${i} = 70 ]] && continue # win32 |
64 | [[ ${i} = 72 ]] && continue # amiga dos os2 vms |
65 | [[ ${i} = 80 ]] && continue # mac |
66 | [[ ${i} = 88 ]] && continue # mac |
67 | [[ ${i} = 91 ]] && continue # win32 |
68 | [[ ${i} = 92 ]] && continue # mac |
69 | [[ ${i} = 124 ]] && continue # mac |
70 | [[ ${i} = 126 ]] && continue # extras |
71 | [[ ${i} = 128 ]] && continue # win32 |
72 | [[ ${i} = 129 ]] && continue # win32 |
73 | [[ ${i} = 134 ]] && continue # win32 |
74 | [[ ${i} = 146 ]] && continue # amiga dos os2 vms |
75 | [[ ${i} = 158 ]] && continue # win32 |
76 | [[ ${i} = 168 ]] && continue # win32 |
77 | [[ ${i} = 196 ]] && continue # win32 |
78 | [[ ${i} = 204 ]] && continue # win32 |
79 | |
80 | ver=00${i} |
81 | [[ ${i} -ge 10 ]] && ver=0${i} |
82 | [[ ${i} -ge 100 ]] && ver=${i} |
83 | |
84 | mpatch ${PVER}.${ver} || die |
85 | done |
86 | |
87 | # fix location of vinmrc config file |
88 | echo '#define SYS_VIMRC_FILE "/etc/vimrc"' >> src/feature.h || die |
89 | echo '#define SYS_GVIMRC_FILE "/etc/gvimrc"' >> src/feature.h || die |
90 | } |
91 | |
92 | src_compile() |
93 | { |
94 | cd ${SRCDIR} |
95 | |
96 | mconfigure --with-features=huge --without-x --disable-gui || die |
97 | mmake || die |
98 | } |
99 | |
100 | src_install() |
101 | { |
102 | cd ${SRCDIR} |
103 | |
104 | # some needed directories |
105 | minstalldir /etc || die |
106 | |
107 | make install \ |
108 | DESTDIR=${BINDIR} \ |
109 | BINDIR=/usr/bin \ |
110 | MANDIR=/usr/share/man \ |
111 | DATADIR=/usr/share || die |
112 | |
113 | # enables the old-fashioned vi mode |
114 | mlink vim /usr/bin/vi || die |
115 | |
116 | # we want run vim in its own mode not in vi mode |
117 | cat > ${BINDIR}/etc/vimrc << "EOF" |
118 | set nocompatible |
119 | set backspace=2 |
120 | syntax on |
121 | EOF |
122 | |
123 | minstalldocs README* || die |
124 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |