Is it possible to use the fish shell with cygwin? I wasn't able to compile the source in cygwin, and I didn't find any precompiled packages. Is there a good reason for not having fish in cygwin?
Here's how I managed to compile fish in Cygwin.
Step 1: Check that all dependencies are installed
First, make sure we have the following cygwin packages:
autoconf(not a really a dependency of fish, but we need it for a later step)
Step 2: Download and extract the latest source
$ tar zxvf fish-1.23.1.tar.gz -C /usr/local/src/ $ cd /usr/local/src/fish-1.23.1/
Step 3: Edit
configure.ac to remove checks for
Now for some reason,
./configure cannot detect
libiconv properly. To get around the problem we remove the check for it (we'll specify the lib manually later). To do so, we edit
configure.ac and remove checks for
iconv_open. Searching for
iconv_open reveals 3 occurences; we comment them all out. So, from:
AC_SEARCH_LIBS( iconv_open, iconv, ....)
We change to:
#AC_SEARCH_LIBS( iconv_open, iconv, ....)
Step 4: Rebuild and run
Next, we rebuild the
./configure script by running
autoconf then run the configure script:
$ autoconf && ./configure
Step 5: Edit
Makefile to include correct path to
Another problem I faced was with
curses.h -- gcc couldn't find it. A quick search revealed that it's in
Makefile has a hardcoded include path for it in
CFLAGS, but it points to
So, we edit
Makefile and change:
CFLAGS = -I/usr/local/include/ncurses -std=c99 ....
CFLAGS = -I/usr/include/ncurses -std=c99 ...
Step 6: Export
LDFLAGS to link in
libiconv, and we're ready to compile/install.
Finally, we export the necessary
LDFLAGS to link in
iconv, then compile and install!
$ export LDFLAGS="-liconv" $ make && make install
$ fish Welcome to fish, the friendly interactive shell Type help for instructions on how to use fish me@home /u/l/s/fish-1.23.1>