2014-02-28 101 views
-1

最近我發現Vim中有許多隱藏的功能。我在哪裏可以找到關於構建Vim的更多信息

因此,我決定重新編譯它(7.4版)以啓用其所有功能。

不幸的是,到目前爲止我見過的文檔主要是關於如何構建一個正常的vim,但不是一個具有全部功能的文檔。

因此,任何人都可以推薦更多關於如何建立這個信息?

順便說一句,我想知道爲什麼啓用了全功能的vim不是默認選擇?

+0

你能形容也許什麼「隱藏功能」你特別努力使? –

+0

那麼,目前我想啓用*剪貼板*和* balloon_eval *。 –

+0

在輸出中。/ configure --help'是一些關於如何添加額外軟件包或可選功能的詳細說明。你有沒有嘗試用它來構建它? – Bort

回答

1

要建立一個全功能的Vim,你必須:

  • 確保你已經安裝了所有必要的開發庫(該./configure步檢查那些與如跳過Gnome的用戶界面,如果你不具備安裝了Gnome庫)
  • pass --with-features=huge;注意:hugebig之間唯一的區別在於分析支持
  • --enable-perlinterp --enable-pythoninterp --enable-python3interp --enable-rubyinterp等,如果你想有一個特定的編程語言集成

您可以驗證所產生的功能通過:version輸出設置。


如果你只是等待在以後的Vim版本引入的新功能,它更容易等待官方的Vim包的更新,通過你的包管理器提供。

2

如果您要查看README in Vim's source code repository,您會發現構建源代碼的所有細節都包含在src/INSTALL file中。這聽起來像你最有可能在可選功能部分感興趣,可以啓用。此外,您可以通過查看src/auto/configure找到可用於configure的可選功能的列表。下面列出了我從源頭抓起剛纔:

--disable-acl   Don't check for ACL support. 
    --disable-darwin  Disable Darwin (Mac OS X) support. 
    --disable-gpm   Don't use gpm (Linux mouse daemon). 
    --disable-gtktest  Do not try to compile and run a test GTK program 
    --disable-largefile  omit support for large files 
    --disable-netbeans  Disable NetBeans integration support. 
    --disable-nls   Don't support NLS (gettext()). 
    --disable-option-checking ignore unrecognized --enable/--with options 
    --disable-selinux Don't check for SELinux support. 
    --disable-sysmouse Don't use sysmouse (mouse in *BSD console). 
    --disable-xsmp   Disable XSMP session management 
    --disable-xsmp-interact Disable XSMP interaction 
    --enable-athena-check If auto-select GUI, check for Athena default=yes 
    --enable-carbon-check If auto-select GUI, check for Carbon default=yes 
    --enable-cscope   Include cscope interface. 
    --enable-fail-if-missing Fail if dependencies on additional features 
    --enable-fontset  Include X fontset output support. 
    --enable-gnome-check If GTK GUI, check for GNOME default=no 
    --enable-gtk2-check  If auto-select GUI, check for GTK+ 2 default=yes 
    --enable-gui=OPTS  X11 GUI default=auto OPTS=auto/no/gtk2/gnome2/motif/athena/neXtaw/photon/carbon 
    --enable-hangulinput Include Hangul input support. 
    --enable-luainterp=OPTS  Include Lua interpreter. default=no OPTS=no/yes/dynamic 
    --enable-motif-check If auto-select GUI, check for Motif default=yes 
    --enable-multibyte  Include multibyte editing support. 
    --enable-mzschemeinterp Include MzScheme interpreter. 
    --enable-nextaw-check If auto-select GUI, check for neXtaw default=yes 
    --enable-perlinterp=OPTS  Include Perl interpreter. default=no OPTS=no/yes/dynamic 
    --enable-python3interp=OPTS Include Python3 interpreter. default=no OPTS=no/yes/dynamic 
    --enable-pythoninterp=OPTS Include Python interpreter. default=no OPTS=no/yes/dynamic 
    --enable-rubyinterp=OPTS  Include Ruby interpreter. default=no OPTS=no/yes/dynamic 
    --enable-sniff   Include Sniff interface. 
    --enable-tclinterp  Include Tcl interpreter. 
    --enable-workshop  Include Sun Visual Workshop support. 
    --enable-xim   Include XIM input support. 
    --with-compiledby=NAME name to show in :version message 
    --with-developer-dir=PATH use PATH as location for Xcode developer tools 
    --with-ex-name=NAME  what to call the Ex executable 
    --with-features=TYPE tiny, small, normal, big or huge (default: normal) 
    --with-global-runtime=DIR global runtime directory in 'runtimepath' 
    --with-gnome   Specify prefix for GNOME files 
    --with-gnome-includes=DIR Specify location of GNOME headers 
    --with-gnome-libs=DIR Specify location of GNOME libs 
    --with-local-dir=PATH search PATH instead of /usr/local for local libraries. 
    --with-lua-prefix=PFX Prefix where Lua is installed. 
    --with-luajit   Link with LuaJIT instead of Lua. 
    --with-mac-arch=ARCH current, intel, ppc or both 
    --with-modified-by=NAME  name of who modified a release version 
    --with-motif-lib=STRING Library for Motif 
    --with-plthome=PLTHOME Use PLTHOME. 
    --with-python-config-dir=PATH Python's config directory 
    --with-python3-config-dir=PATH Python's config directory 
    --with-ruby-command=RUBY name of the Ruby command (default: ruby) 
    --with-tclsh=PATH  which tclsh to use (default: tclsh8.0) 
    --with-tlib=library  terminal library to be used 
    --with-view-name=NAME what to call the View executable 
    --with-vim-name=NAME what to call the Vim executable 
    --with-x    use the X Window System 
    --without-PACKAGE  do not use PACKAGE (same as --with-PACKAGE=no) 
    --without-local-dir  do not search /usr/local for local libraries. 

如果你使用的是官方VIM源的一個分支,您的發行可能有不同的選項。運行configure --help應列出它們,而不要求您通過源代碼進行挖掘。

至於爲什麼這些並不是默認啓用的,這可能是因爲它們被認爲對每個人都不夠用(或者他們需要默認情況下可能不支持的支持庫)。真的,這是vim維護者的問題,而不是SO。

0

如果你檢查Vim的Google Groups郵件列表的檔案,你會發現編譯Vim的剪貼板支持(這是相當新的)很長的線程。

這不是那麼簡單,因爲你想象,但它並非不可克服...

相關問題