I would think that you could install your libraries and modules under a dedicated application tree to avoid conflicts instead of trying to statically compile. Seems much simpler. After all, you have to at least install your own ncurses, right?
Update: did some research, excuse my delirium.