Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Nov 2005 12:11:40 GMT
From:      Kostik Belousov <kostikbel@gmail.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/89065: [patch] games/quakeforge does not respond to keyboard input
Message-ID:  <200511151211.jAFCBeuT027555@www.freebsd.org>
Resent-Message-ID: <200511151220.jAFCKM7D023251@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         89065
>Category:       ports
>Synopsis:       [patch] games/quakeforge does not respond to keyboard input
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Nov 15 12:20:21 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Kostik Belousov
>Release:        6.0-STABLE
>Organization:
-
>Environment:
FreeBSD deviant.kiev.zoral.com.ua 6.0-STABLE FreeBSD 6.0-STABLE #34: Wed Nov  2 11:48:22 EET 2005     root@deviant.kiev.zoral.com.ua:/usr/obj/usr/src/sys/DEVIANT  i386
>Description:
After ports recompilation for 6.0 (upgrade from 5-STABLE) I noticed that
quakeforge start and plays the demo, but completely ignores any keyboard input.
Besides that, it reports that plugin /usr/local/lib/quakeforge/console_client.so
cannot be loaded.

Investigation had shown that the plugin is used to drive the game menu, and the
reason it cannot be loaded is that the main executable of the game does not export
the symbol Key_Progs_Init.

Symbol is absent since build links final exe from some static libraries, and
.o with Key_Progs_Init is (for some reasons) not referenced by exe.
As a workaround, I propose to add an explicit reference for the symbol.

Proper fix would be something like -Wl,--whole-archive switch for final link,
but this does not work due to libtool only allows to put switches at the start
of the command line. And cc links libgcc.a twice, that leads to duplicate
symbol definitions.

>How-To-Repeat:
              
>Fix:
              
cat /usr/ports/games/quakeforge/files/patch-nq_source_sys__unix.c

$FreeBSD$

--- nq/source/sys_unix.c.orig
+++ nq/source/sys_unix.c
@@ -69,6 +69,9 @@
        fcntl (0, F_SETFL, fcntl (0, F_GETFL, 0) & ~O_NONBLOCK);
 }
 
+extern void Key_Progs_Init (progs_t *pr);
+void (*x)() = Key_Progs_Init;
+
 int
 main (int c, const char *v[])
 {
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200511151211.jAFCBeuT027555>