Skip to contentSkip to conversation

Fix menuconfig on Solaris

PATCH Applied Tom Rini 2 participants 2 messages Oct 27, 2004 – Oct 30, 2004

lore
Share & tools
lore

Tom Rini

author
#0 lore raw

PATCH 1/1 Fix menuconfig on Solaris

Something occured to me after I sent my first round of Solaris patches, people might want to use 'menuconfig' not just config/oldconfig. The following two bits are needed to get it working (not as colorful as on Linux, but it functions) for me. First, unless CURS_MACROS is defined, scroll(x) doesn't get expanded to wscrl(x, 1). I did some quick grepping on Cygwin and Linux (debian/unstable) and didn't see CURS_MACROS show up anywhere else, but to be safe I put it inside of __sun__. Next this uses libcurses instead of libncurses otherwise we get a bunch of undefined refs to w32attrset, w32addch, acs32map and few more.

scripts/lxdialog/dialog.h +3 -0
@@ -26,6 +26,9 @@
 #include <stdlib.h>
 #include <string.h>
 
+#ifdef __sun__
+#define CURS_MACROS
+#endif
 #include CURSES_LOC
 
 /*
scripts/lxdialog/Makefile +4 -0
@@ -1,5 +1,9 @@
 HOST_EXTRACFLAGS := -DLOCALE 
+ifeq ($(shell uname),SunOS)
+HOST_LOADLIBES   := -lcurses
+else
 HOST_LOADLIBES   := -lncurses
+endif
 
 ifeq (/usr/include/ncurses/ncurses.h, $(wildcard /usr/include/ncurses/ncurses.h))
         HOST_EXTRACFLAGS += -I/usr/include/ncurses -DCURSES_LOC="<ncurses.h>"
Signature · 2 lines
Tom Rini
http://gate.crashing.org/~trini/
Applied
#1 lore raw
Quoted 2 lines · Tom Rini

Something occured to me after I sent my first round of Solaris patches, people might want to use 'menuconfig' not just config/oldconfig.

Applied,

Sam