Gentoo Archives: gentoo-commits

From: "Tim Harder (radhermit)" <radhermit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-editors/vim: vim-9999.ebuild ChangeLog vim-7.4.712.ebuild
Date: Sun, 03 May 2015 07:03:48
Message-Id: 20150503070336.317309A9@oystercatcher.gentoo.org
1 radhermit 15/05/03 07:03:35
2
3 Modified: vim-9999.ebuild ChangeLog
4 Added: vim-7.4.712.ebuild
5 Log:
6 Version bump. Set tab indentation to 8 spaces for vimmanpager (bug #545628).
7
8 (Portage version: 2.2.18/cvs/Linux x86_64, signed Manifest commit with key 4F064CA3)
9
10 Revision Changes Path
11 1.28 app-editors/vim/vim-9999.ebuild
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/vim-9999.ebuild?rev=1.28&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/vim-9999.ebuild?rev=1.28&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/vim-9999.ebuild?r1=1.27&r2=1.28
16
17 Index: vim-9999.ebuild
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/app-editors/vim/vim-9999.ebuild,v
20 retrieving revision 1.27
21 retrieving revision 1.28
22 diff -u -r1.27 -r1.28
23 --- vim-9999.ebuild 31 Mar 2015 17:37:10 -0000 1.27
24 +++ vim-9999.ebuild 3 May 2015 07:03:35 -0000 1.28
25 @@ -1,6 +1,6 @@
26 # Copyright 1999-2015 Gentoo Foundation
27 # Distributed under the terms of the GNU General Public License v2
28 -# $Header: /var/cvsroot/gentoo-x86/app-editors/vim/vim-9999.ebuild,v 1.27 2015/03/31 17:37:10 ulm Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/app-editors/vim/vim-9999.ebuild,v 1.28 2015/05/03 07:03:35 radhermit Exp $
30
31 EAPI=5
32 VIM_VERSION="7.4"
33 @@ -125,7 +125,7 @@
34 sed -e 's/\x1B\[[[:digit:]]\+m//g' | col -b | \\
35 vim \\
36 -c 'let no_plugin_maps = 1' \\
37 - -c 'set nolist nomod ft=man' \\
38 + -c 'set nolist nomod ft=man ts=8' \\
39 -c 'let g:showmarks_enable=0' \\
40 -c 'runtime! macros/less.vim' -
41 END
42
43
44
45 1.496 app-editors/vim/ChangeLog
46
47 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/ChangeLog?rev=1.496&view=markup
48 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/ChangeLog?rev=1.496&content-type=text/plain
49 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/ChangeLog?r1=1.495&r2=1.496
50
51 Index: ChangeLog
52 ===================================================================
53 RCS file: /var/cvsroot/gentoo-x86/app-editors/vim/ChangeLog,v
54 retrieving revision 1.495
55 retrieving revision 1.496
56 diff -u -r1.495 -r1.496
57 --- ChangeLog 8 Apr 2015 07:30:35 -0000 1.495
58 +++ ChangeLog 3 May 2015 07:03:35 -0000 1.496
59 @@ -1,6 +1,12 @@
60 # ChangeLog for app-editors/vim
61 # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
62 -# $Header: /var/cvsroot/gentoo-x86/app-editors/vim/ChangeLog,v 1.495 2015/04/08 07:30:35 mgorny Exp $
63 +# $Header: /var/cvsroot/gentoo-x86/app-editors/vim/ChangeLog,v 1.496 2015/05/03 07:03:35 radhermit Exp $
64 +
65 +*vim-7.4.712 (03 May 2015)
66 +
67 + 03 May 2015; Tim Harder <radhermit@g.o> +vim-7.4.712.ebuild,
68 + vim-9999.ebuild:
69 + Version bump. Set tab indentation to 8 spaces for vimmanpager (bug #545628).
70
71 08 Apr 2015; Michał Górny <mgorny@g.o> vim-7.4.273.ebuild:
72 Remove old Python implementations
73
74
75
76 1.1 app-editors/vim/vim-7.4.712.ebuild
77
78 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/vim-7.4.712.ebuild?rev=1.1&view=markup
79 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/vim/vim-7.4.712.ebuild?rev=1.1&content-type=text/plain
80
81 Index: vim-7.4.712.ebuild
82 ===================================================================
83 # Copyright 1999-2015 Gentoo Foundation
84 # Distributed under the terms of the GNU General Public License v2
85 # $Header: /var/cvsroot/gentoo-x86/app-editors/vim/vim-7.4.712.ebuild,v 1.1 2015/05/03 07:03:35 radhermit Exp $
86
87 EAPI=5
88 VIM_VERSION="7.4"
89 PYTHON_COMPAT=( python{2_7,3_3,3_4} )
90 PYTHON_REQ_USE=threads
91 inherit eutils vim-doc flag-o-matic fdo-mime versionator bash-completion-r1 python-r1
92
93 if [[ ${PV} == 9999* ]] ; then
94 inherit mercurial
95 EHG_REPO_URI="https://vim.googlecode.com/hg/"
96 EHG_PROJECT="vim"
97 else
98 VIM_ORG_PATCH="vim-${PV}.patch.xz"
99 SRC_URI="ftp://ftp.vim.org/pub/vim/unix/vim-${VIM_VERSION}.tar.bz2
100 http://dev.gentoo.org/~radhermit/vim/${VIM_ORG_PATCH}
101 http://dev.gentoo.org/~radhermit/vim/vim-7.4.542-gentoo-patches.tar.bz2"
102 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~hppa-hpux ~ia64-hpux ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
103 fi
104
105 DESCRIPTION="Vim, an improved vi-style text editor"
106 HOMEPAGE="http://www.vim.org/"
107
108 SLOT="0"
109 LICENSE="vim"
110 IUSE="X acl cscope debug gpm lua luajit minimal nls perl python racket ruby selinux tcl vim-pager"
111 REQUIRED_USE="
112 luajit? ( lua )
113 python? (
114 || ( $(python_gen_useflags '*') )
115 ?? ( $(python_gen_useflags 'python2*') )
116 ?? ( $(python_gen_useflags 'python3*') )
117 )
118 "
119
120 RDEPEND="
121 >=app-eselect/eselect-vi-1.1
122 >=sys-libs/ncurses-5.2-r2
123 nls? ( virtual/libintl )
124 acl? ( kernel_linux? ( sys-apps/acl ) )
125 cscope? ( dev-util/cscope )
126 gpm? ( >=sys-libs/gpm-1.19.3 )
127 lua? (
128 luajit? ( dev-lang/luajit:2= )
129 !luajit? ( dev-lang/lua:0[deprecated] )
130 )
131 !minimal? (
132 ~app-editors/vim-core-${PV}
133 dev-util/ctags
134 )
135 perl? ( dev-lang/perl:= )
136 python? ( ${PYTHON_DEPS} )
137 racket? ( dev-scheme/racket )
138 ruby? ( || ( dev-lang/ruby:2.2 dev-lang/ruby:2.1 dev-lang/ruby:2.0 ) )
139 selinux? ( sys-libs/libselinux )
140 tcl? ( dev-lang/tcl:0= )
141 X? ( x11-libs/libXt )
142 "
143 DEPEND="${RDEPEND}
144 sys-devel/autoconf
145 nls? ( sys-devel/gettext )
146 "
147
148 S=${WORKDIR}/vim${VIM_VERSION/.}
149
150 pkg_setup() {
151 # people with broken alphabets run into trouble. bug 82186.
152 unset LANG LC_ALL
153 export LC_COLLATE="C"
154
155 # Gnome sandbox silliness. bug #114475.
156 mkdir -p "${T}"/home
157 export HOME="${T}"/home
158 }
159
160 src_prepare() {
161 if [[ ${PV} != 9999* ]] ; then
162 if [[ -f "${WORKDIR}"/${VIM_ORG_PATCH%.xz} ]] ; then
163 # Apply any patches available from vim.org for this version
164 epatch "${WORKDIR}"/${VIM_ORG_PATCH%.xz}
165 fi
166
167 if [[ -d "${WORKDIR}"/patches/ ]]; then
168 # Gentoo patches to fix runtime issues, cross-compile errors, etc
169 EPATCH_SUFFIX="patch" EPATCH_FORCE="yes" \
170 epatch "${WORKDIR}"/patches/
171 fi
172 fi
173
174 # Fixup a script to use awk instead of nawk
175 sed -i '1s|.*|#!'"${EPREFIX}"'/usr/bin/awk -f|' "${S}"/runtime/tools/mve.awk \
176 || die "mve.awk sed failed"
177
178 # Read vimrc and gvimrc from /etc/vim
179 echo '#define SYS_VIMRC_FILE "'${EPREFIX}'/etc/vim/vimrc"' >> "${S}"/src/feature.h
180 echo '#define SYS_GVIMRC_FILE "'${EPREFIX}'/etc/vim/gvimrc"' >> "${S}"/src/feature.h
181
182 # Use exuberant ctags which installs as /usr/bin/exuberant-ctags.
183 # Hopefully this pattern won't break for a while at least.
184 # This fixes bug 29398 (27 Sep 2003 agriffis)
185 sed -i 's/\<ctags\("\| [-*.]\)/exuberant-&/g' \
186 "${S}"/runtime/doc/syntax.txt \
187 "${S}"/runtime/doc/tagsrch.txt \
188 "${S}"/runtime/doc/usr_29.txt \
189 "${S}"/runtime/menu.vim \
190 "${S}"/src/configure.in || die 'sed failed'
191
192 # Don't be fooled by /usr/include/libc.h. When found, vim thinks
193 # this is NeXT, but it's actually just a file in dev-libs/9libs
194 # This fixes bug 43885 (20 Mar 2004 agriffis)
195 sed -i 's/ libc\.h / /' "${S}"/src/configure.in || die 'sed failed'
196
197 # gcc on sparc32 has this, uhm, interesting problem with detecting EOF
198 # correctly. To avoid some really entertaining error messages about stuff
199 # which isn't even in the source file being invalid, we'll do some trickery
200 # to make the error never occur. bug 66162 (02 October 2004 ciaranm)
201 find "${S}" -name '*.c' | while read c ; do echo >> "$c" ; done
202
203 # conditionally make the manpager.sh script
204 if use vim-pager ; then
205 cat <<-END > "${S}"/runtime/macros/manpager.sh
206 #!/bin/sh
207 sed -e 's/\x1B\[[[:digit:]]\+m//g' | col -b | \\
208 vim \\
209 -c 'let no_plugin_maps = 1' \\
210 -c 'set nolist nomod ft=man ts=8' \\
211 -c 'let g:showmarks_enable=0' \\
212 -c 'runtime! macros/less.vim' -
213 END
214 fi
215
216 # Try to avoid sandbox problems. Bug #114475.
217 if [[ -d "${S}"/src/po ]] ; then
218 sed -i '/-S check.vim/s,..VIM.,ln -s $(VIM) testvim \; ./testvim -X,' \
219 "${S}"/src/po/Makefile
220 fi
221
222 if version_is_at_least 7.3.122 ; then
223 cp "${S}"/src/config.mk.dist "${S}"/src/auto/config.mk
224 fi
225
226 # Bug #378107 - Build properly with >=perl-core/ExtUtils-ParseXS-3.20.0
227 if version_is_at_least 7.3 ; then
228 sed -i "s:\\\$(PERLLIB)/ExtUtils/xsubpp:${EPREFIX}/usr/bin/xsubpp:" \
229 "${S}"/src/Makefile || die 'sed for ExtUtils-ParseXS failed'
230 fi
231
232 epatch_user
233 }
234
235 src_configure() {
236 local myconf=()
237
238 # Fix bug 37354: Disallow -funroll-all-loops on amd64
239 # Bug 57859 suggests that we want to do this for all archs
240 filter-flags -funroll-all-loops
241
242 # Fix bug 76331: -O3 causes problems, use -O2 instead. We'll do this for
243 # everyone since previous flag filtering bugs have turned out to affect
244 # multiple archs...
245 replace-flags -O3 -O2
246
247 # Fix bug 18245: Prevent "make" from the following chain:
248 # (1) Notice configure.in is newer than auto/configure
249 # (2) Rebuild auto/configure
250 # (3) Notice auto/configure is newer than auto/config.mk
251 # (4) Run ./configure (with wrong args) to remake auto/config.mk
252 sed -i 's# auto/config\.mk:#:#' src/Makefile || die "Makefile sed failed"
253 rm -f src/auto/configure
254 emake -j1 -C src autoconf
255
256 # This should fix a sandbox violation (see bug 24447). The hvc
257 # things are for ppc64, see bug 86433.
258 for file in /dev/pty/s* /dev/console /dev/hvc/* /dev/hvc* ; do
259 [[ -e ${file} ]] && addwrite $file
260 done
261
262 if use minimal ; then
263 myconf=(
264 --with-features=tiny
265 --disable-nls
266 --disable-multibyte
267 --disable-acl
268 --enable-gui=no
269 --without-x
270 --disable-darwin
271 --disable-luainterp
272 --disable-perlinterp
273 --disable-pythoninterp
274 --disable-mzschemeinterp
275 --disable-rubyinterp
276 --disable-selinux
277 --disable-tclinterp
278 --disable-gpm
279 )
280 else
281 use debug && append-flags "-DDEBUG"
282
283 myconf=(
284 --with-features=huge
285 --enable-multibyte
286 $(use_enable acl)
287 $(use_enable cscope)
288 $(use_enable gpm)
289 $(use_enable lua luainterp)
290 $(usex lua "--with-lua-prefix=${EPREFIX}/usr" "")
291 $(use_with luajit)
292 $(use_enable nls)
293 $(use_enable perl perlinterp)
294 $(use_enable racket mzschemeinterp)
295 $(use_enable ruby rubyinterp)
296 $(use_enable selinux)
297 $(use_enable tcl tclinterp)
298 )
299
300 if use python ; then
301 py_add_interp() {
302 local v
303
304 [[ ${EPYTHON} == python3* ]] && v=3
305 myconf+=(
306 --enable-python${v}interp
307 vi_cv_path_python${v}="${PYTHON}"
308 )
309 }
310
311 python_foreach_impl py_add_interp
312 else
313 myconf+=(
314 --disable-pythoninterp
315 --disable-python3interp
316 )
317 fi
318
319 # --with-features=huge forces on cscope even if we --disable it. We need
320 # to sed this out to avoid screwiness. (1 Sep 2004 ciaranm)
321 if ! use cscope ; then
322 sed -i '/# define FEAT_CSCOPE/d' src/feature.h || \
323 die "couldn't disable cscope"
324 fi
325
326 # don't test USE=X here ... see bug #19115
327 # but need to provide a way to link against X ... see bug #20093
328 myconf+=(
329 --enable-gui=no
330 --disable-darwin
331 $(use_with X x)
332 )
333 fi
334
335 # Let Portage do the stripping. Some people like that.
336 export ac_cv_prog_STRIP="$(type -P true ) faking strip"
337
338 # Keep Gentoo Prefix env contained within the EPREFIX
339 use prefix && myconf+=( --without-local-dir )
340
341 econf \
342 --with-modified-by=Gentoo-${PVR} \
343 "${myconf[@]}"
344 }
345
346 src_compile() {
347 # The following allows emake to be used
348 emake -j1 -C src auto/osdef.h objects
349
350 emake
351 }
352
353 src_test() {
354 echo
355 einfo "Starting vim tests. Several error messages will be shown"
356 einfo "while the tests run. This is normal behaviour and does not"
357 einfo "indicate a fault."
358 echo
359 ewarn "If the tests fail, your terminal may be left in a strange"
360 ewarn "state. Usually, running 'reset' will fix this."
361 echo
362
363 # Don't let vim talk to X
364 unset DISPLAY
365
366 # We've got to call make test from within testdir, since the Makefiles
367 # don't pass through our VIMPROG argument
368 cd "${S}"/src/testdir
369
370 # Test 49 won't work inside a portage environment
371 einfo "Test 49 isn't sandbox-friendly, so it will be skipped."
372 sed -i 's~test49.out~~g' Makefile
373
374 # We don't want to rebuild vim before running the tests
375 sed -i 's,: \$(VIMPROG),: ,' Makefile
376
377 # Don't try to do the additional GUI test
378 emake -j1 VIMPROG=../vim nongui
379 }
380
381 # Make convenience symlinks, hopefully without stepping on toes. Some
382 # of these links are "owned" by the vim ebuild when it is installed,
383 # but they might be good for gvim as well (see bug 45828)
384 update_vim_symlinks() {
385 local f syms
386 syms="vimdiff rvim rview"
387 einfo "Calling eselect vi update..."
388 # Call this with --if-unset to respect user's choice (bug 187449)
389 eselect vi update --if-unset
390
391 # Make or remove convenience symlink, vim -> gvim
392 if [[ -f "${EROOT}"/usr/bin/gvim ]]; then
393 ln -s gvim "${EROOT}"/usr/bin/vim 2>/dev/null
394 elif [[ -L "${EROOT}"/usr/bin/vim && ! -f "${EROOT}"/usr/bin/vim ]]; then
395 rm "${EROOT}"/usr/bin/vim
396 fi
397
398 # Make or remove convenience symlinks to vim
399 if [[ -f "${EROOT}"/usr/bin/vim ]]; then
400 for f in ${syms}; do
401 ln -s vim "${EROOT}"/usr/bin/${f} 2>/dev/null
402 done
403 else
404 for f in ${syms}; do
405 if [[ -L "${EROOT}"/usr/bin/${f} && ! -f "${EROOT}"/usr/bin/${f} ]]; then
406 rm -f "${EROOT}"/usr/bin/${f}
407 fi
408 done
409 fi
410
411 # This will still break if you merge then remove the vi package,
412 # but there's only so much you can do, eh? Unfortunately we don't
413 # have triggers like are done in rpm-land.
414 }
415
416 src_install() {
417 local vimfiles=/usr/share/vim/vim${VIM_VERSION/.}
418
419 # Note: Do not install symlinks for 'vi', 'ex', or 'view', as these are
420 # managed by eselect-vi
421 dobin src/vim
422 dosym vim /usr/bin/vimdiff
423 dosym vim /usr/bin/rvim
424 dosym vim /usr/bin/rview
425 if use vim-pager ; then
426 dosym ${vimfiles}/macros/less.sh /usr/bin/vimpager
427 dosym ${vimfiles}/macros/manpager.sh /usr/bin/vimmanpager
428 insinto ${vimfiles}/macros
429 doins runtime/macros/manpager.sh
430 fperms a+x ${vimfiles}/macros/manpager.sh
431 fi
432
433 newbashcomp "${FILESDIR}"/${PN}-completion ${PN}
434 # keep in sync with 'complete ... -F' list
435 bashcomp_alias vim ex vi view rvim rview vimdiff
436
437 # We shouldn't be installing the ex or view man page symlinks, as they
438 # are managed by eselect-vi
439 rm -f "${ED}"/usr/share/man/man1/{ex,view}.1
440 }
441
442 pkg_postinst() {
443 # Update documentation tags (from vim-doc.eclass)
444 update_vim_helptags
445
446 if [[ -z ${REPLACING_VERSIONS} ]] ; then
447 if use X ; then
448 echo
449 elog "The 'X' USE flag enables vim <-> X communication, like"
450 elog "updating the xterm titlebar. It does not install a GUI."
451 fi
452 echo
453 elog "To install a GUI version of vim, use the app-editors/gvim"
454 elog "package."
455 echo
456 elog "Vim 7 includes an integrated spell checker. You need to install"
457 elog "word list files before you can use it. There are ebuilds for"
458 elog "some of these named app-vim/vim-spell-*. If your language of"
459 elog "choice is not included, please consult vim-spell.eclass for"
460 elog "instructions on how to make a package."
461 echo
462 ewarn "Note that the English word lists are no longer installed by"
463 ewarn "default."
464 fi
465
466 # Make convenience symlinks
467 update_vim_symlinks
468 }
469
470 pkg_postrm() {
471 # Update documentation tags (from vim-doc.eclass)
472 update_vim_helptags
473
474 # Make convenience symlinks
475 update_vim_symlinks
476 }