Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I checked out latest vim7 from cvs repository.

cvs -z3 -d:pserver:anonymous@vim.cvs.sf.net:/cvsroot/vim checkout vim7

I tried:

./configure --enable-xterm_clipboard

but I got -

WARNING: unrecognized options --enable-xterm_clipboard

I tried:

./configure --with-x

but I got -

configure: error: unrecognized option: --with_x.

Can someone please tell me the correct way to configure with xterm_clipboard support?

Edit

I tried ./configure --with-feature=normal --with-x --with-gui in the src directory, but got WARNING: unrecognized options --with-feature, --with-gui at the end.

share|improve this question

4 Answers 4

up vote 4 down vote accepted

by looking at src/feature.h you can see that:

#ifdef FEAT_GUI
# ifndef FEAT_CLIPBOARD
#  define FEAT_CLIPBOARD
#  ifndef FEAT_VISUAL
#   define FEAT_VISUAL
#  endif
# endif
#endif

#if defined(FEAT_NORMAL) && defined(FEAT_VISUAL) \
    && (defined(UNIX) || defined(VMS)) \
    && defined(WANT_X11) && defined(HAVE_X11)
# define FEAT_XCLIPBOARD
# ifndef FEAT_CLIPBOARD
#  define FEAT_CLIPBOARD
# endif
#endif
  • having --with-features=normal
  • having --enable-gui
  • having --with-x

you should get your xterm-clipboard

share|improve this answer
    
works flawless on my server right now. –  akira Jan 20 '11 at 6:43
    
Thanks, this is useful. However as I said, --with-x is giving error at top level, --with-feature, --with-gui are giving error if I run configure in src directory. –  JP19 Jan 20 '11 at 6:43
    
are you doing configure at top level? –  JP19 Jan 20 '11 at 6:44
    
yes. cvs yada yada; cd vim7; ./configure --with-x –  akira Jan 20 '11 at 6:48
1  
did you notice i fixed --with-features and --enable-gui (instead of --with-gui)? –  akira Jan 20 '11 at 7:54

On Ubuntu, the flags above worked for me, but I also had to install the xorg-dev package

sudo apt-get install xorg-dev

./configure --with-x --enable-gui=auto  --with-features=huge
share|improve this answer

To easiest way to get vim working with xterm_clipboard is:

sudo apt-get install vim-gnome
share|improve this answer
1  
is this just for Ubuntu? –  Eric Brotto Jun 22 '12 at 11:36
1  
This enables support for xterm_clipboard also for the console version of vim (on Ubuntu systems). –  Tim Oct 17 '13 at 16:28

It looks like you aren't running configure in the src directory, but rather one level up. If you do chdir src; configure --with-x it should work okay.

But keep in mind two points:

  1. With Vim, the preferred way of modifying configure options is to modify src/Makefile
  2. The default is to enable the GUI, and thus +xterm_clipboard, and as far as I know you can't have +xterm_clipboard without the GUI being compiled in.
share|improve this answer
    
Yes, indeed I was running it at top level as usually thats recommended. I will try in src directory. (and also see the Makefile - I don't know changes there are preferred for vim). –  JP19 Jan 20 '11 at 6:38
    
@Heptite: you can have clipboard without the gui, all you need is X. folks working mostly in xterm would be very unhappy otherwise :) –  akira Jan 20 '11 at 6:50
    
@akira: I have edited my post to clarify my statement: I believe you must have a GUI compiled in to have the +xterm_clipboard feature available. –  Heptite Jan 20 '11 at 20:05
    
your statement was clear, and i thought mine was clear as well: you do not need --enable-gui to have +xterm_clipboard: here, selfcompiled seconds ago: "VIM - Vi IMproved 7.2 (2008 Aug 9, compiled Jan 21 2011 08:17:30) ... Normal version without GUI. ... +xsmp_interact +xterm_clipboard -xterm_save". all thats needed to have +xterm_clipboad is './configure --with-x --with-features=normal' –  akira Jan 21 '11 at 7:20
    
Ah, I stand (sit) corrected. It's been a long time since I've bothered to compile Vim without a GUI. –  Heptite Jan 21 '11 at 10:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.