Monday, June 23, 2008

Tabbed terminal under Cygwin using mrxvt tabs (pre xorg-server-1.5.3)

UPDATED: a more recent version of Cygwin/X breaks the procedure below, for a more up to date procedure go here I'm only leaving this post here for people to read the comments below it which may help someone. And now you get a blinking link, because people felt like they should still leave comments here ... years after the new post on this subject. Well, comments have been turned off for this post.


mrxvt is a multi-tabbed terminal emulator that does not depend on various toolkits in Gnome or KDE. And even though the download page of the materm wiki says "Cygwin - currently not available" ... You can get mrxvt up and running under Cygwin as follows:

UPDATED: a more recent version of Cygwin/X breaks the procedure below, for a more up to date procedure go here This post remains here mainly for the comments below.

1) Download the latest stable version of mrxvt from here to the root directory of the c: drive.
2) In a cygwin bash shell do the following:


$ cd c:/
$ tar -zxf mrxvt-0.4.2.tgz
$ cd mrxvt-0.4.2
$ ./bootstrap.sh
$ ./configure --enable-everything --disable-debug
$ make
$ make install
$ startxwin.sh
$ mrxvt -fn fixed -fg green -bg black -g 150x45 -ls &

NOTE: Many other packages are required to be installed under cygwin for this procedure above to get mrxvt up and running ... here are a few off the top of my head:

1) Cygwin base install
2) gcc
3) make
4) autoconf
5) automake
6) the entire X11 category of packages (or at least xorg-x11-devel)
7) all of the cygwin rxvt packages

By the way, try switching between tabs by using either SHIFT RIGHT/LEFT ARROW (the KDE default) ... or CTRL PAGE-UP/DOWN (the Gnome terminal default)

UPDATE: if you get the following error when configuring the mxrvt package:
checking for X... no
configure: error: Mrxvt requires the X Window System libraries and headers.
Then you will need to make sure you installed make and the xorg-x11-devel package from cygwin.

Hope that helps.

UPDATE: a more recent version of Cygwin/X breaks the procedure above, for a more up to date procedure go here. This post remains here mainly for the comments below.

13 comments:

junger said...

I'm trying to build it, but it insists I don't have X Window System libraries and headers available.
I've installed every X package I can find; what am I missing?

Vernon Singleton said...

You do not say what your exact error message is, and after which command you get the error, so I will take a wild guess from among the 10^30 errors available in the universe.

If you are getting an error about a header file from a library you can go here:
http://cygwin.com/packages/

and search all of the cygwin packages for the header file it wants, and it will tell you what package you need to install.

Hope that helps.

junger said...

Sorry for the lack of context:

$ ./configure --enable-everything --disable-debug
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... no
checking whether to enable maintainer-specific portions of Makefiles... no
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-cygwin
checking for gcc... gcc
checking for C compiler default output file name... a.exe
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... .exe
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... none
checking dependency style of gcc... none
checking whether make sets $(MAKE)... (cached) no
checking for a BSD-compatible install... /usr/bin/install -c
checking how to run the C preprocessor... gcc -E
checking for X... no
configure: error: Mrxvt requires the X Window System libraries and headers.

Vernon Singleton said...

It looks like you will need this package:

xorg-x11-devel

junger said...

Thanks for hanging in there with me.

I have that package and more: xorg-x11-base, xorg-x11-bin, xorg-x11-bin-dlls, xorg-x11-bin-lndir, xorg-x11-devel, xorg-x11-etc, xorg-x11-libs-data, xorg-x11-xwin, plus most of the font-related packages.

Maybe I don't have something on my path?

Vernon Singleton said...

You may be right ... try adding /usr/X11R6/bin to your path.

junger said...

Finally figured it all out. Even though I *thought* I had 'make' installed, it turns out I didn't.

Quick install, and it all works great.

Dave said...

Hi Vernon,

I'm also having some issues with X window.


My configure output is as follows:
[/cygdrive/c/mrxvt-0.4.2]$ ./configure --enable-everything --disable-debug
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-cygwin
checking for gcc... gcc
checking for C compiler default output file name... a.exe
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... .exe
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... none
checking whether make sets $(MAKE)... (cached) yes
checking for a BSD-compatible install... /usr/bin/install -c
checking how to run the C preprocessor... gcc -E
checking for X... no
configure: error: Mrxvt requires the X Window System libraries and headers.

In the Cygwin setup I've got every package under the X11 category installed as well as the following:

gcc-core (3.4.4-3)
gcc-g++ (3.4.4-3)

make (3.81-2)

autoconf:Wrapper scripts for autoconf commands (4-1)
autoconf2.13-3
autoconf2.61-1

automake:Wrapper scripts for automake and aclocal (2-1)
automake1.10.1-1
automake1.4p6-4
automake1.5-2
automake1.6.3-3
automake1.7.9-3
automake1.8.5-3
automake1.9.6-2

rxvt:VT102 terminal emulator for both X and Windows (20050409-7)
rxvt-unicode-common: An improved version of rxvt requiring an Xserver (7.7-6)
rxvt-unicode-X: An improved version of rxvt requiring an Xserver (7.7-6)


I also have /usr/X11R6/bin in my $PATH variable.


Any advice? Thanks.

Dave said...

never mind...got it going. just required reinstalling a heap of the packages. something interesting to note is you can edit the startxwin.bat file in C:\cygwin\usr\X11R6\bin to open the tabbed terminal from one windows shortcut. replace the line "%RUN% xterm -e /usr/bin/bash -l" with:


REM %RUN% xterm -e /usr/bin/bash -l

%RUN% mrxvt -fn fixed -fg white -bg black -g 150x45 -ls &

cheers

Muhammad said...

[/cygdrive/c/mrxvt-0.4.2]$ ./bootstrap.sh
+ aclocal
./bootstrap.sh: line 25: aclocal: command not found
+ autoheader
./bootstrap.sh: line 26: autoheader: command not found
+ automake --add-missing --copy
./bootstrap.sh: line 27: automake: command not found
+ autoconf
./bootstrap.sh: line 29: autoconf: command not found


what's wrong ? Help me !

Vernon Singleton said...

@Muhammad

You probably should not try to use this procedure above anymore. For a more up to date procedure go here

Hope that helps.

Anonymous said...

Hello,

I got the same problem
"configure: error: Mrxvt requires the X Window" and I fixed it with the following steps:
- I installed xorg-x11-devel (available when you click obsolete packages)
- $ ./configure --x-includes=/usr/X11R6/include/ --x-libraries=/usr/X11R6/lib

And it did work :-)
Franck

Anonymous said...

Hi Vernon,

On my cygwin, configure gave:

configure: error: cannot guess build type; you must specify one

I ran

./configure --enable-everything --disable-debug --build=i686-pc-cygwin

It worked.

Thanks

noman