vim: ./configure and it’s fucking cache

July 7th, 2011 — 01:51 pm

If while configuring vim‘s Makefile you have any problem with missing dependencies I give you and advice:

After installing those dependencies, delete $VIM_SOURCE/src/config.cache or there’ll be variables set on that file that’ll fool ./configure into thinking that those dependencies are still missing.

Fuck yeah!!

Comment » | tweaks, vim

mac: Install MacVim

July 6th, 2011 — 05:38 pm

Today, trying to compile MacVim I ran into a problem with some shared libraries:

Undefined symbols:
  "_iconv_close", referenced from:
      _buf_write in fileio.o
      _readfile in fileio.o
      _readfile in fileio.o

The problem has to do with lib search path. I don’t know yet why isn’t used the system path (under /usr/lib) rather than the one used by macports.

Well, the thing is that the libiconv2.dylib under /opt/local/lib doesn’t have the _iconv_close function (among others):

[madtrick { lib } ]pwd
[madtrick { lib } ]nm libiconv.2.dylib | grep "iconv_close"
000163f0 T _libiconv_close

While libiconv.2.dylib on /usr/lib does:

[madtrick { lib } ]pwd
[madtrick { lib } ]nm libiconv.2.dylib | grep "iconv_close"
0000b905 T _iconv_close
0000fcce T _libiconv_close

So to fix this problem you have several choices:

  • Deactivate libiconv on macports (and all its dependencies)
  • Prepend a lib path

I went for the second one:

LDFLAGS="-L/usr/lib" ./configure _your_options_here_

There you go : )

4 comments » | mac, tweaks

git: bash-completion

July 4th, 2011 — 06:10 pm

Looking for a way to easyly know if there’s something changed on my git repos I found out that git itself ships a bash script that perfectly satisfy my needs.

Introducing: __git_ps1


Include a call to __git_ps1 in your promt string (for example in bash):

PS1='[\u@\h \W$(__git_ps1 " (%s)")]\$ '

This will show the current branch on your prompt.


__git_ps1 allows to customize its output using environment variables. Here is a list of avaliable options:

  • GIT_PS1_SHOWDIRTYSTATE.  When set to something not empty, __git_ps1 will display unstaged (*) and staged (+) next to the branch name.
  • GIT_PS1_SHOWSTASHSTATE.  When set to something no empty, __git_ps1 will display $ next to the branch name when something is staged.
  • GIT_PS1_SHOWUNTRACKEDFILES.  When set to something no empty, __git_ps1 will display % next to the branch name when there’re untracked files.
  • GIT_PS1_SHOWUPSTREAM.  This cat take several (comma separated) values: auto, verbose, legacy, git and svn. __git_ps1 will show the difference between HEAD and its upstream.

Export them if your shell dotfile before calling __git_ps1.

Comment » | bash, git, tweaks

mac: tabswitching in Visor

July 4th, 2011 — 05:44 pm

I tryed Visor, a quake-like terminal for Mac OS, in the past but left it because there wasn’t an easy way to switch between tabs.

Until now…

Today I found TerminalTabSwitching. A plugin to enable cmd + <tab_number> switching on

I’m a bit happier : )

Comment » | mac, tweaks

jetty: Shit happens!!

April 9th, 2011 — 01:11 pm

For the impatient readers:

Don’t set Jetty’s <stopPort> to the same <port> where Jetty is running or you might run into some nasty-hard-to-debug problem.

Continue reading »

25 comments » | java, programacion, shit

Nach oben

« Previous Entries