Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have installed ncurses package from source, and now I have

$HOME/local/include/ncurses/curses.h
$HOME/local/include/ncurses/ncurses.h

on my filesystem. I have also set up the search pathes so that

$ echo $C_INCLUDE_PATH
$HOME/local/include:
$ echo $CPLUS_INCLUDE_PATH
$HOME/local/include:

(i have eddited the output of echo to replace home path with $HOME)

however, when i ./configure another package i get

checking ncurses.h usability... no
checking ncurses.h presence... no

what's the problem that the system cannot detect curses installation?

share|improve this question
    
make sure your two paths you mentioned at the start do not have the inlcude typo on the filesystem. –  lynxlynxlynx Jul 1 '12 at 19:37
    
@lynxlynxlynx i fixed the typo in the question, thanks for pointing out –  behzad.nouri Jul 1 '12 at 19:45
add comment

1 Answer

up vote 6 down vote accepted

configure scripts produce config.log (in the same folder) files which contain all the details on the tests it ran. They're not particularly easy to read, but open it up and search for "checking ncurses.h usability". Look at what went wrong with the small test program it tried to compile.

My guess is, it doesn't care about $C_INCLUDE_PATH and you'll need to pass it to the build system in a different matter. configure options (eg. --includedir=$HOME/local/include) and $CFLAGS + $CXXFLAGS + $CPPFLAGS (adding -I$HOME/local/include) come to mind.

share|improve this answer
    
I did ./configure CFLAGS=-I/home/w381833/local/include/ncurses CXXFLAGS=-I/home/w381833/local/include/ncurses and I got configure: WARNING: curses.h: accepted by the compiler, rejected by the preprocessor! configure: WARNING: curses.h: proceeding with the compiler's result. I think i am doing something wrong or that something is missing in here –  behzad.nouri Jul 1 '12 at 20:07
3  
add CPPFLAGS=-I/home/w381833/local/include/ncurses (for the preprocessor). –  lynxlynxlynx Jul 1 '12 at 20:10
    
perfect, worked like charm, thanks @lynxlynxlynx –  behzad.nouri Jul 1 '12 at 20:26
add comment

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.