1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-20 00:21:35 +00:00

Alter language bindings

Separate python2 and python3 bindings[1], to allow each to be enabled
independently or concurrently. py27 is still the default.

As long as I'm messing with language bindings, turn the Tcl and Lua
options off by default. This does NOT in any way affect support for
editing those types of files (including indenting, completion,
highlighting, linting, etc.)---it only affects plugins written in
Tcl or Lua or interactive debugging.

Suggested by:	mat [1]
This commit is contained in:
Adam Weinberger 2017-10-31 17:15:06 +00:00
parent 1d379f47fc
commit 4492438acd
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=453244
2 changed files with 30 additions and 20 deletions

View File

@ -5,6 +5,20 @@ they are unavoidable.
You should get into the habit of checking this file for changes each time
you update your ports collection, before attempting any port upgrades.
20171031:
AFFECTS: users of editors/vim
AUTHOR: adamw@FreeBSD.org
The default vim language bindings have changed. Python 2 and 3 bindings
may now be enabled independently (the default vim package will continue
to depend on python-2.7).
Lua and Tcl bindings have been disabled by default. If you need these
bindings, you'll need to compile vim yourself. Note that bindings are
only for plugins written in those languages, and for interactive
debugging. Editing, indenting, linting, completing, and syntax-highlighting
those languages is NOT affected.
20171026:
AFFECTS: users of devel/universal-ctags
AUTHOR: rodrigo@FreeBSD.org

View File

@ -4,6 +4,7 @@
PORTNAME= vim
PORTVERSION= 8.0.1231
DISTVERSIONPREFIX= v
PORTREVISION= 1
CATEGORIES= editors
MAINTAINER= adamw@FreeBSD.org
@ -37,15 +38,16 @@ MAKE_ARGS+= CC="${CC}" \
VIMRUNTIMEDIR=${PREFIX}/share/vim/${VIM_VER} \
VIMRCLOC=${ETCDIR} \
CONF_OPT_MULTIBYTE=--enable-multibyte \
CONF_TERM_LIB=--with-tlib=ncurses
CONF_TERM_LIB=--with-tlib=ncurses \
CONF_OPT_PYTHON="${CONF_OPT_PYTHON}"
# OPTIONS
OPTIONS_DEFAULT= CSCOPE DEFAULT_VIMRC EXUBERANT_CTAGS GTK2 LUA PERL PYTHON RUBY TCL
OPTIONS_DEFAULT= CSCOPE DEFAULT_VIMRC EXUBERANT_CTAGS GTK2 PERL PYTHON2 RUBY
OPTIONS_DEFINE= CSCOPE DEFAULT_VIMRC EXUBERANT_CTAGS NLS XTERM_SAVE
OPTIONS_SINGLE= UI
OPTIONS_SINGLE_UI= ATHENA CONSOLE GNOME GTK2 GTK3 MOTIF X11
OPTIONS_GROUP= LANGBIND
OPTIONS_GROUP_LANGBIND= LUA PERL PYTHON RUBY TCL
OPTIONS_GROUP_LANGBIND= LUA PERL PYTHON2 PYTHON3 RUBY TCL
OPTIONS_SUB= yes
.if defined(LITE)
@ -129,8 +131,14 @@ PERL_MAKE_ARGS= CONF_OPT_PERL=--enable-perlinterp
PERL_MAKE_ARGS_OFF= CONF_OPT_PERL=--disable-perlinterp
PERL_USES= perl5
PYTHON_MAKE_ARGS_OFF= CONF_OPT_PYTHON="--disable-pythoninterp --disable-python3interp"
PYTHON_USES= python
PYTHON2_VARS= CONF_OPT_PYTHON+=--enable-pythoninterp
PYTHON2_VARS_OFF= CONF_OPT_PYTHON+=--disable-pythoninterp
PYTHON2_BUILD_DEPENDS= python${PYTHON2_DEFAULT}:lang/python${PYTHON2_DEFAULT:S/.//}
PYTHON2_RUN_DEPENDS= ${PYTHON2_BUILD_DEPENDS}
PYTHON3_VARS= CONF_OPT_PYTHON+=--enable-python3interp
PYTHON3_VARS_OFF= CONF_OPT_PYTHON+=--disable-python3interp
PYTHON3_USES= python:3.4+
RUBY_MAKE_ARGS= CONF_OPT_RUBY=--enable-rubyinterp
RUBY_MAKE_ARGS_OFF= CONF_OPT_RUBY=--disable-rubyinterp
@ -140,16 +148,6 @@ TCL_MAKE_ARGS= CONF_OPT_TCL="--enable-tclinterp --with-tclsh=tclsh${TCL_VER}"
TCL_MAKE_ARGS_OFF= CONF_OPT_TCL=--disable-tclinterp
TCL_USES= tcl:85+
.include <bsd.port.pre.mk>
.if ${PORT_OPTIONS:MPYTHON}
.if ${PYTHON_REL} < 3000
MAKE_ARGS+= CONF_OPT_PYTHON="--enable-pythoninterp --disable-python3interp"
.else
MAKE_ARGS+= CONF_OPT_PYTHON="--enable-python3interp --disable-pythoninterp"
.endif
.endif
post-extract:
${INSTALL_DATA} ${FILESDIR}/vietnamese_viscii.vim ${WRKSRC}/runtime/keymap
@ -158,6 +156,8 @@ post-patch:
@${ECHO_CMD} '#define SYS_GVIMRC_FILE "'${ETCDIR}'/gvimrc"' >> ${WRKSRC}/src/feature.h
@${REINPLACE_CMD} -e 's|-liconv|${ICONV_LIB}|g; s|/usr/local|${LOCALBASE}|g' \
${WRKSRC}/src/auto/configure
# Work around qa-check shebang error
@${REINPLACE_CMD} -e 1d ${WRKSRC}/runtime/tools/demoserver.py
pre-configure:
@${CP} ${WRKSRC}/src/config.mk.dist ${WRKSRC}/src/auto/config.mk
@ -185,10 +185,6 @@ post-patch-EXUBERANT_CTAGS-on:
post-patch-LUA-on:
@${REINPLACE_CMD} -e 's|set dummy lua;|set dummy ${LUA_CMD};|g' ${WRKSRC}/src/auto/configure
post-patch-PYTHON-off:
# Work around qa-check shebang error
@${REINPLACE_CMD} -e 1d ${WRKSRC}/runtime/tools/demoserver.py
post-patch-XTERM_SAVE-on:
@${REINPLACE_CMD} -e '/FEAT_XTERM_SAVE/ s|.*|#define FEAT_XTERM_SAVE|' ${WRKSRC}/src/feature.h
@ -202,4 +198,4 @@ post-install-NLS-off:
@${MKDIR} ${STAGEDIR}${DATADIR}/${VIM_VER}/keymap
${INSTALL_DATA} ${WRKSRC}/runtime/keymap/* ${STAGEDIR}${DATADIR}/${VIM_VER}/keymap
.include <bsd.port.post.mk>
.include <bsd.port.mk>