Hi Brad,
thank you for pointing out the conditions. But they cannot be used to
ignore the symolic link in /usr/include/ to favor the acutal header in
/usr/include/ncurses/. I always end up with /usr/include/ being the
CURSES_INCLUDE_PATH.

> On 7/28/19 4:21 PM, Christoph Grüninger wrote:
>> -include_directories(${CURSES_INCLUDE_PATH})
>> +include_directories(${CURSES_INCLUDE_PATH}/ncurses/)
> 
> Why is that needed given the conditions here:
> 
>   
> https://gitlab.kitware.com/cmake/cmake/blob/v3.15.1/Source/CursesDialog/form/form.h#L38-57
>   
> https://gitlab.kitware.com/cmake/cmake/blob/v3.15.1/Source/Checks/Curses/CheckCurses.c#L1-9
> 
> ?
> 
>> The reason is, that curses.h and ncurses.h are present in /usr/include.
>> Both are symbolic links to /usr/include/ncurses/curses.h.
> 
> What actually goes wrong?

I always end up with /usr/include/ being the CURSES_INCLUDE_PATH.

> That said, it's bad that the mess of conditions in the code I linked above
> is even needed to use FindCurses.  It would be nice to add a policy to
> change the FindCurses module to work in a more sane way.  However, we must
> first determine what the proper behavior should be.  Should consumers
> put the `ncurses/` part of the path in their `#include` lines or not?
> If they do, how do they build against plain curses?

Yes, this would be nice. Currently, I cannot answer your question, as I
am alien to Curses / Ncurses.


Kind regards,
Christoph

-- 
Nous vivons une époque où les pizzas arrivent plus vite que la police.
[Claude Chabrol]
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake-developers

Reply via email to