Hi!

lynx-2.8.8rel1 doesn't build when USE_KEYMAPS is not defined.

clang -DHAVE_CONFIG_H   -DLOCALEDIR=\"/usr/pkg/share/locale\"  -I.  -I..  
-Ichrtrans  -I./chrtrans  -I..  -I../src  -I.././WWW/Library/Implementation     
-I/usr/include/openssl -I/usr/include  -D_NETBSD_SOURCE  -D_XOPEN_SOURCE=500 
-O2 -I/usr/include -c LYCurses.c
LYCurses.c:1183:15: warning: implicit declaration of function 
'lynx_initialize_keymaps' is invalid in C99 [-Wimplicit-function-declaration]
    if (-1 == lynx_initialize_keymaps()) {
              ^
1 warning generated.
...
Linking and creating Lynx executable
clang -DHAVE_CONFIG_H   -DLOCALEDIR=\"/usr/pkg/share/locale\"  -I.  -I..  
-Ichrtrans  -I./chrtrans  -I..  -I../src  -I.././WWW/Library/Implementation     
-I/usr/include/openssl -I/usr/include  -D_NETBSD_SOURCE  -D_XOPEN_SOURCE=500 
-O2 -I/usr/include -L/usr/lib -Wl,-R/usr/lib -Wl,-R/usr/pkg/lib -o lynx  
LYebcdic.o  LYClean.o LYShowInfo.o LYEdit.o LYStrings.o LYMail.o  HTAlert.o 
GridText.o LYGetFile.o LYMain.o LYMainLoop.o  LYCurses.o LYBookmark.o 
LYmktime.o LYUtils.o LYOptions.o  LYReadCFG.o LYSearch.o LYHistory.o LYForms.o 
LYPrint.o  LYrcFile.o LYDownload.o LYNews.o LYKeymap.o HTML.o  HTFWriter.o 
HTInit.o DefaultStyle.o LYUpload.o  LYLeaks.o LYexit.o LYJump.o LYList.o 
LYCgi.o  LYTraversal.o LYEditmap.o LYCharSets.o LYCharUtils.o  LYMap.o 
LYCookie.o LYStyle.o LYHash.o LYPrettySrc.o  TRSTable.o parsdate.o UCdomap.o 
UCAux.o UCAuto.o  LYSession.o LYExtern.o LYLocal.o 
.././WWW/Library/Implementation/libwww.a -lz -lcurses -lssl -lcrypto -lintl
LYCurses.o: In function `restart_curses':
LYCurses.c:(.text+0xf11): undefined reference to `lynx_initialize_keymaps'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

The attached patch fixes this.

Cheers,
 Thomas
$NetBSD: patch-src_LYCurses.c,v 1.1 2014/02/20 10:07:35 wiz Exp $

Fix build without keymaps support.

--- src/LYCurses.c.orig 2013-11-29 00:52:56.000000000 +0000
+++ src/LYCurses.c
@@ -1180,10 +1180,12 @@ void restart_curses(void)
     keypad(LYwin, TRUE);
     lynx_enable_mouse(1);
 
+#if defined(USE_KEYMAPS)  
     if (-1 == lynx_initialize_keymaps()) {
        endwin();
        exit_immediately(EXIT_FAILURE);
     }
+#endif
     if (has_colors()) {
        start_color();
     }
_______________________________________________
Lynx-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lynx-dev

Reply via email to