You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was looking around to find a TUI library for C++, and I ended up here. I was trying this fork of tvision out yesterday and I noticed that all applications would segfault after compilation.
After debugging I found out that I need to link tinfow after ncursesw for it to work.
Activity
magiblot commentedon Sep 5, 2020
Hi Atjon, thanks for finding out!
From what I can see, in many Linux systems there is no
tinfow, justtinfo. Sotinfowshould be only linked when available.Can you check if the following works for you?
if (TV_PLATF EQUAL TV_PLATF_UNIX) find_library(NCURSESW ncursesw REQUIRED) if (NCURSESW) list(APPEND LIBS ${NCURSESW}) target_compile_definitions(tvision PRIVATE HAVE_NCURSES) + find_library(TINFOW tinfow) + if (TINFOW) + list(APPEND LIBS ${TINFOW}) + endif() endif() # Optional dependencies find_library(GPM gpm) if (GPM) list(APPEND LIBS ${GPM}) target_compile_definitions(tvision PRIVATE HAVE_GPM) endif() endif()Cheers.
Fix compilation with older CMake/GCC and link in tinfow
magiblot commentedon Sep 5, 2020
Alternatively, just upgrade to the latest commit and try again.
AtjonTV commentedon Sep 5, 2020
Jap, its working. Thanks!