Gentoo Archives: gentoo-commits

From: Tim Harder <radhermit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-editors/vim-core/
Date: Wed, 14 Aug 2019 23:59:45
Message-Id: 1565827099.a598488e2a28c21a4a63274ad7e023be6e29da7a.radhermit@gentoo
1 commit: a598488e2a28c21a4a63274ad7e023be6e29da7a
2 Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
3 AuthorDate: Wed Aug 14 23:38:40 2019 +0000
4 Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
5 CommitDate: Wed Aug 14 23:58:19 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a598488e
7
8 app-editors/vim-core: version bump to 8.1.1846
9
10 Signed-off-by: Tim Harder <radhermit <AT> gentoo.org>
11
12 app-editors/vim-core/Manifest | 1 +
13 app-editors/vim-core/vim-core-8.1.1846.ebuild | 225 ++++++++++++++++++++++++++
14 2 files changed, 226 insertions(+)
15
16 diff --git a/app-editors/vim-core/Manifest b/app-editors/vim-core/Manifest
17 index 6ba358e2d5b..88f7734b453 100644
18 --- a/app-editors/vim-core/Manifest
19 +++ b/app-editors/vim-core/Manifest
20 @@ -1,2 +1,3 @@
21 DIST vim-8.0.0938-gentoo-patches.tar.bz2 2316 BLAKE2B 05a87f32fc5cc65e7f5e4e5a87c654b2040ad39f1555ddde7e0e6f473dc8b520916a795406bb6bbeaf5e7ae8748aacebe7a9679461e48802e69417e945eea827 SHA512 a6062be5e6a5c5b437081312df5742353242b5171bf26da04aa6ca216d2b142b2411a88bc1edd460d28e00a59a210c8e1729e801fac6f1efd86bb2e437a56a2b
22 DIST vim-8.1.1486.tar.gz 14318109 BLAKE2B 6054df175a32e9ed36873802a4a669cc46e034bac879cb829e45ece53f9440e97cccad47e370ebdef8dc1bb963e8e8c84bd517a3a6561705786dcab7e2368d21 SHA512 0a521d74c60f2a32e8a11e16f256e2e99fb9c00f478cd8d7a9328315abbd445796153f03884ab2b240905260317809a33afb64627b9a71ac8d6db1cbd4026d20
23 +DIST vim-8.1.1846.tar.gz 14415116 BLAKE2B 59c2864519e100f9bc2617dd7b31a8cc17ff20fc87a761eba653e91a70688c3b4a5f05c527acaf6d075830d23c7ef8842595b6558eac2ab5209029153f1adb10 SHA512 d5a5cb7733f3190915e2b1389fea48d119afef27eac6f04ac3967f57e894cab811727a694c6837bb5acef9997cd56018d4b37efeb413c654012aaaea02bf7c7a
24
25 diff --git a/app-editors/vim-core/vim-core-8.1.1846.ebuild b/app-editors/vim-core/vim-core-8.1.1846.ebuild
26 new file mode 100644
27 index 00000000000..08bf83307d7
28 --- /dev/null
29 +++ b/app-editors/vim-core/vim-core-8.1.1846.ebuild
30 @@ -0,0 +1,225 @@
31 +# Copyright 1999-2019 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=6
35 +VIM_VERSION="8.1"
36 +inherit estack vim-doc flag-o-matic bash-completion-r1 prefix desktop gnome2-utils
37 +
38 +if [[ ${PV} == 9999* ]] ; then
39 + inherit git-r3
40 + EGIT_REPO_URI="https://github.com/vim/vim.git"
41 + EGIT_CHECKOUT_DIR=${WORKDIR}/vim-${PV}
42 +else
43 + SRC_URI="https://github.com/vim/vim/archive/v${PV}.tar.gz -> vim-${PV}.tar.gz
44 + https://dev.gentoo.org/~radhermit/vim/vim-8.0.0938-gentoo-patches.tar.bz2"
45 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
46 +fi
47 +
48 +DESCRIPTION="vim and gvim shared files"
49 +HOMEPAGE="https://vim.sourceforge.io/ https://github.com/vim/vim"
50 +
51 +SLOT="0"
52 +LICENSE="vim"
53 +IUSE="nls acl minimal"
54 +
55 +DEPEND="sys-devel/autoconf"
56 +# avoid icon file collision bug #673880
57 +RDEPEND="!!<app-editors/gvim-8.1.0648"
58 +PDEPEND="!minimal? ( app-vim/gentoo-syntax )"
59 +
60 +S=${WORKDIR}/vim-${PV}
61 +
62 +pkg_setup() {
63 + # people with broken alphabets run into trouble. bug 82186.
64 + unset LANG LC_ALL
65 + export LC_COLLATE="C"
66 +
67 + # Gnome sandbox silliness. bug #114475.
68 + mkdir -p "${T}"/home || die "mkdir -p failed"
69 + export HOME="${T}"/home
70 +}
71 +
72 +src_prepare() {
73 + if [[ ${PV} != 9999* ]] ; then
74 + # Gentoo patches to fix runtime issues, cross-compile errors, etc
75 + eapply "${WORKDIR}"/patches
76 + fi
77 +
78 + # Fixup a script to use awk instead of nawk
79 + sed -i \
80 + -e '1s|.*|#!'"${EPREFIX}"'/usr/bin/awk -f|' \
81 + "${S}"/runtime/tools/mve.awk || die "sed failed"
82 +
83 + # See #77841. We remove this file after the tarball extraction.
84 + rm -v "${S}"/runtime/tools/vimspell.sh || die "rm failed"
85 +
86 + # Read vimrc and gvimrc from /etc/vim
87 + echo '#define SYS_VIMRC_FILE "'${EPREFIX}'/etc/vim/vimrc"' >> "${S}"/src/feature.h
88 + echo '#define SYS_GVIMRC_FILE "'${EPREFIX}'/etc/vim/gvimrc"' >> "${S}"/src/feature.h
89 +
90 + # Use exuberant ctags which installs as /usr/bin/exuberant-ctags.
91 + # Hopefully this pattern won't break for a while at least.
92 + # This fixes bug 29398 (27 Sep 2003 agriffis)
93 + sed -i 's/\<ctags\("\| [-*.]\)/exuberant-&/g' \
94 + "${S}"/runtime/doc/syntax.txt \
95 + "${S}"/runtime/doc/tagsrch.txt \
96 + "${S}"/runtime/doc/usr_29.txt \
97 + "${S}"/runtime/menu.vim \
98 + "${S}"/src/configure.ac || die 'sed failed'
99 +
100 + # Don't be fooled by /usr/include/libc.h. When found, vim thinks
101 + # this is NeXT, but it's actually just a file in dev-libs/9libs
102 + # This fixes bug 43885 (20 Mar 2004 agriffis)
103 + sed -i 's/ libc\.h / /' "${S}"/src/configure.ac || die 'sed failed'
104 +
105 + # gcc on sparc32 has this, uhm, interesting problem with detecting EOF
106 + # correctly. To avoid some really entertaining error messages about stuff
107 + # which isn't even in the source file being invalid, we'll do some trickery
108 + # to make the error never occur. bug 66162 (02 October 2004 ciaranm)
109 + find "${S}" -name '*.c' | while read c; do
110 + echo >> "$c" || die "echo failed"
111 + done
112 +
113 + # Try to avoid sandbox problems. Bug #114475.
114 + if [[ -d "${S}"/src/po ]]; then
115 + sed -i -e \
116 + '/-S check.vim/s,..VIM.,ln -s $(VIM) testvim \; ./testvim -X,' \
117 + "${S}"/src/po/Makefile || die "sed failed"
118 + fi
119 +
120 + cp -v "${S}"/src/config.mk.dist "${S}"/src/auto/config.mk || die "cp failed"
121 +
122 + # Bug #378107 - Build properly with >=perl-core/ExtUtils-ParseXS-3.20.0
123 + sed -i -e \
124 + "s:\\\$(PERLLIB)/ExtUtils/xsubpp:${EPREFIX}/usr/bin/xsubpp:" \
125 + "${S}"/src/Makefile || die 'sed for ExtUtils-ParseXS failed'
126 +
127 + eapply_user
128 +}
129 +
130 +src_configure() {
131 + local myconf
132 +
133 + # Fix bug 37354: Disallow -funroll-all-loops on amd64
134 + # Bug 57859 suggests that we want to do this for all archs
135 + filter-flags -funroll-all-loops
136 +
137 + # Fix bug 76331: -O3 causes problems, use -O2 instead. We'll do this for
138 + # everyone since previous flag filtering bugs have turned out to affect
139 + # multiple archs...
140 + replace-flags -O3 -O2
141 +
142 + # Fix bug 18245: Prevent "make" from the following chain:
143 + # (1) Notice configure.ac is newer than auto/configure
144 + # (2) Rebuild auto/configure
145 + # (3) Notice auto/configure is newer than auto/config.mk
146 + # (4) Run ./configure (with wrong args) to remake auto/config.mk
147 + sed -i 's# auto/config\.mk:#:#' src/Makefile || die "Makefile sed failed"
148 +
149 + # Remove src/auto/configure file.
150 + rm -v src/auto/configure || die "rm configure failed"
151 +
152 + emake -j1 -C src autoconf
153 +
154 + # This should fix a sandbox violation (see bug 24447). The hvc
155 + # things are for ppc64, see bug 86433.
156 + for file in /dev/pty/s* /dev/console /dev/hvc/* /dev/hvc*; do
157 + if [[ -e "${file}" ]]; then
158 + addwrite $file
159 + fi
160 + done
161 +
162 + # Let Portage do the stripping. Some people like that.
163 + export ac_cv_prog_STRIP="$(type -P true ) faking strip"
164 +
165 + # Keep Gentoo Prefix env contained within the EPREFIX
166 + use prefix && myconf+=" --without-local-dir"
167 +
168 + econf \
169 + --with-modified-by=Gentoo-${PVR} \
170 + --enable-gui=no \
171 + --without-x \
172 + --disable-darwin \
173 + --disable-perlinterp \
174 + --disable-pythoninterp \
175 + --disable-rubyinterp \
176 + --disable-gpm \
177 + --disable-selinux \
178 + $(use_enable nls) \
179 + $(use_enable acl) \
180 + ${myconf}
181 +}
182 +
183 +src_compile() {
184 + emake -j1 -C src auto/osdef.h objects
185 + emake tools
186 +}
187 +
188 +src_test() { :; }
189 +
190 +src_install() {
191 + local vimfiles=/usr/share/vim/vim${VIM_VERSION/.}
192 +
193 + dodir /usr/{bin,share/{man/man1,vim}}
194 + emake -C src \
195 + installruntime \
196 + installmanlinks \
197 + installmacros \
198 + installtutor \
199 + installtutorbin \
200 + installtools \
201 + install-languages \
202 + DESTDIR="${D}" \
203 + BINDIR="${EPREFIX}"/usr/bin \
204 + MANDIR="${EPREFIX}"/usr/share/man \
205 + DATADIR="${EPREFIX}"/usr/share
206 +
207 + keepdir ${vimfiles}/keymap
208 +
209 + # default vimrc is installed by vim-core since it applies to
210 + # both vim and gvim
211 + insinto /etc/vim/
212 + newins "${FILESDIR}"/vimrc-r5 vimrc
213 + eprefixify "${ED}"/etc/vim/vimrc
214 +
215 + if use minimal; then
216 + # To save space, install only a subset of the files.
217 + # Helps minimalize the livecd, bug 65144.
218 + eshopts_push -s extglob
219 +
220 + rm -rv "${ED}${vimfiles}"/{compiler,doc,ftplugin,indent} || die "rm failed"
221 + rm -rv "${ED}${vimfiles}"/{macros,print,tools,tutor} || die "rm failed"
222 + rm -v "${ED}"/usr/bin/vimtutor || die "rm failed"
223 +
224 + local keep_colors="default"
225 + ignore=$(rm -fr "${ED}${vimfiles}"/colors/!(${keep_colors}).vim )
226 +
227 + local keep_syntax="conf|crontab|fstab|inittab|resolv|sshdconfig"
228 + # tinkering with the next line might make bad things happen ...
229 + keep_syntax="${keep_syntax}|syntax|nosyntax|synload"
230 + ignore=$(rm -fr "${ED}${vimfiles}"/syntax/!(${keep_syntax}).vim )
231 +
232 + eshopts_pop
233 + fi
234 +
235 + newbashcomp "${FILESDIR}"/xxd-completion xxd
236 +
237 + # install gvim icon since both vim/gvim desktop files reference it
238 + doicon -s scalable "${FILESDIR}"/gvim.svg
239 +}
240 +
241 +pkg_postinst() {
242 + # update documentation tags (from vim-doc.eclass)
243 + update_vim_helptags
244 +
245 + # update icon cache
246 + gnome2_icon_cache_update
247 +}
248 +
249 +pkg_postrm() {
250 + # Update documentation tags (from vim-doc.eclass)
251 + update_vim_helptags
252 +
253 + # update icon cache
254 + gnome2_icon_cache_update
255 +}