Hello, QEMU's -curses option is not enabled because configure script requires the information of ncurses by pkg-config.
The diff specifies the place of ncurses library to enable QEMU's curses support. ok or comment? -- SASANO Takayoshi (JG1UAA) <u...@mx5.nisiq.net> Index: Makefile =================================================================== RCS file: /cvs/ports/emulators/qemu/Makefile,v retrieving revision 1.159 diff -u -p -r1.159 Makefile --- Makefile 10 Apr 2017 13:13:02 -0000 1.159 +++ Makefile 14 Apr 2017 13:49:20 -0000 @@ -78,6 +78,7 @@ CONFIGURE_ARGS= --prefix=${PREFIX} \ --host-cc="${CC}" \ --extra-cflags="${EXTRA_CFLAGS}" \ --extra-ldflags="${EXTRA_LDFLAGS}" \ + --enable-curses \ --disable-bsd-user \ --disable-gcrypt \ --disable-smartcard \ Index: patches/patch-configure =================================================================== RCS file: /cvs/ports/emulators/qemu/patches/patch-configure,v retrieving revision 1.50 diff -u -p -r1.50 patch-configure --- patches/patch-configure 22 Dec 2016 09:05:06 -0000 1.50 +++ patches/patch-configure 14 Apr 2017 13:49:20 -0000 @@ -1,7 +1,64 @@ $OpenBSD: patch-configure,v 1.50 2016/12/22 09:05:06 ajacoutot Exp $ ---- configure.orig Tue Dec 6 22:54:54 2016 -+++ configure Sat Dec 10 23:54:52 2016 -@@ -4740,10 +4740,6 @@ fi +--- configure.orig Fri Mar 31 23:07:03 2017 ++++ configure Fri Apr 14 06:19:09 2017 +@@ -2924,54 +2924,8 @@ fi + ########################################## + # curses probe + if test "$curses" != "no" ; then +- if test "$mingw32" = "yes" ; then +- curses_inc_list="$($pkg_config --cflags ncurses 2>/dev/null):" +- curses_lib_list="$($pkg_config --libs ncurses 2>/dev/null):-lpdcurses" +- else +- curses_inc_list="$($pkg_config --cflags ncursesw 2>/dev/null):-I/usr/include/ncursesw:" +- curses_lib_list="$($pkg_config --libs ncursesw 2>/dev/null):-lncursesw:-lcursesw" +- fi +- curses_found=no +- cat > $TMPC << EOF +-#include <locale.h> +-#include <curses.h> +-#include <wchar.h> +-int main(void) { +- const char *s = curses_version(); +- wchar_t wch = L'w'; +- setlocale(LC_ALL, ""); +- resize_term(0, 0); +- addwstr(L"wide chars\n"); +- addnwstr(&wch, 1); +- add_wch(WACS_DEGREE); +- return s != 0; +-} +-EOF +- IFS=: +- for curses_inc in $curses_inc_list; do +- IFS=: +- for curses_lib in $curses_lib_list; do +- unset IFS +- if compile_prog "$curses_inc" "$curses_lib" ; then +- curses_found=yes +- QEMU_CFLAGS="$curses_inc $QEMU_CFLAGS" +- libs_softmmu="$curses_lib $libs_softmmu" +- break +- fi +- done +- if test "$curses_found" = yes ; then +- break +- fi +- done +- unset IFS +- if test "$curses_found" = "yes" ; then +- curses=yes +- else +- if test "$curses" = "yes" ; then +- feature_not_found "curses" "Install ncurses devel" +- fi +- curses=no +- fi ++ curses=yes ++ libs_softmmu="-lncurses $libs_softmmu" + fi + + ########################################## +@@ -4740,10 +4694,6 @@ fi if test "$gcov" = "yes" ; then CFLAGS="-fprofile-arcs -ftest-coverage -g $CFLAGS" LDFLAGS="-fprofile-arcs -ftest-coverage $LDFLAGS" @@ -12,7 +69,7 @@ $OpenBSD: patch-configure,v 1.50 2016/12 fi ########################################## -@@ -4892,7 +4888,7 @@ if test \( "$cpu" = "i386" -o "$cpu" = "x86_64" \) -a +@@ -4892,7 +4842,7 @@ if test \( "$cpu" = "i386" -o "$cpu" = "x86_64" \) -a # Different host OS linkers have different ideas about the name of the ELF # emulation. Linux and OpenBSD use 'elf_i386'; FreeBSD uses the _fbsd # variant; and Windows uses i386pe.