Complete.Org: Mailing Lists: Archives: freeciv-dev: September 2004:
[Freeciv-Dev] (PR#10345) ftwl/win32 compile error
Home

[Freeciv-Dev] (PR#10345) ftwl/win32 compile error

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] (PR#10345) ftwl/win32 compile error
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Sun, 26 Sep 2004 06:55:18 -0700
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=10345 >

mapview.c: In function `is_float':
mapview.c:957: warning: implicit declaration of function `localeconv'
mapview.c:957: warning: assignment makes pointer from integer without a cast
mapview.c:958: error: dereferencing pointer to incomplete type
mapview.c:962: error: dereferencing pointer to incomplete type
make[4]: *** [mapview.o] Error 1
make[4]: Leaving directory `/home/Administrator/freeciv/client/gui-ftwl'

The function is_float() will not work if --disable-nls is used.

Since I'm not exactly sure what this function does, this patch is a shot
in the dark:

Index: mapview.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-ftwl/mapview.c,v
retrieving revision 1.4
diff -u -b -B -r1.4 mapview.c
--- mapview.c   16 Sep 2004 08:53:08 -0000      1.4
+++ mapview.c   26 Sep 2004 13:21:07 -0000
@@ -950,9 +950,10 @@
 {
   char *p;
   char *copy = mystrdup(str);
-  struct lconv *locale_data;
   double res;
+#ifdef NLS
   int i;
+  struct lconv *locale_data;

   locale_data = localeconv();
   assert(strlen(locale_data->decimal_point) == 1);
@@ -962,6 +963,7 @@
       copy[i] = locale_data->decimal_point[0];
     }
   }
+#endif

Also, freetype is not linked in (missing -lfreetype in linking stage),
when trying to compile ftwl=dx.

gcc  -g -O2 -Werror -Wall -Wpointer-arith -Wcast-align
-Wmissing-prototypes            ssing-declarations   -o civclient.exe
audio_winmm.o attribute.o citydlg_           on.o cityrepdata.o
civclient.o chatline_common.o connectdlg_common.o climisc
limap.o clinet.o control.o goto.o helpdata.o mapctrl_common.o
mapview_common           essagewin_common.o packhand.o packhand_gen.o
plrdlg_common.o options.o repod           common.o text.o tilespec.o
audio.o audio_none.o ../utility/libcivutility.a .
ility/ftwl/libftwl.a ../common/libcivcommon.a ../common/aicore/libaicore.a
a           s/libagents.a gui-ftwl/libguiclient.a
../utility/libcivutility.a ../utility/           /libftwl.a
../common/libcivcommon.a ../common/aicore/libaicore.a agents/liba
s.a gui-ftwl/libguiclient.a -lpng -lddraw   -lwinmm -lz  -lwsock32

$ freetype-config --libs
-Lc:/progra~1/FreeType/lib -lfreetype -lz

In configure.ac: FTWL_LIBS=" -lpng -lddraw "`freetype-config --libs`
and: CLIENT_LIBS="$CLIENT_LIBS $FTWL_LIBS"

But in root Makefile: CLIENT_LIBS =   -lpng -lddraw

I do not understand how this can be.

  - Per




[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#10345) ftwl/win32 compile error, Per I. Mathisen <=