URL:
  <http://gna.org/bugs/?11609>

                 Summary: Compilation of beta 2 fails on Mac OS X 10.4
                 Project: Warzone Resurrection Project
            Submitted by: None
            Submitted on: Thursday 05/01/2008 at 00:05 CEST
                Category: None
                Severity: 4 - Important
                Priority: 5 - Normal
                  Status: None
             Assigned to: None
        Originator Email: [EMAIL PROTECTED]
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 2.1_beta2
        Operating System: Mac OS
         Planned Release: None

    _______________________________________________________

Details:

Hi,

I'm trying to compile Warzone on Mac OS X 10.4.11 on an Intel Mac Book Pro (I
installed all necessary libraries with macports) using "./configure; make" but
it fails with the following error:

/usr/bin/gcc-4.0 -std=gnu99 -DHAVE_CONFIG_H -I. -I../..  
-I/opt/local/include -I/usr/X11R6/include  -DNDEBUG
-DDATADIR="\"/opt/local/share/warzone2100\""
-DLOCALEDIR="\"/opt/local/share/locale\"" -DYY_NO_INPUT -I../..
-D_GNU_SOURCE=1 -D_THREAD_SAFE -I/opt/local/include/SDL  
-I/opt/local/include/libpng12   -I/opt/local/include  
-I/opt/local/include/openal   -O2  -g -Wall -MT input.o -MD -MP -MF
.deps/input.Tpo -c -o input.o input.c
In file included from frame.h:33,
                 from input.c:38:
strlfuncs.h:42: error: static declaration of 'strlcpy' follows non-static
declaration
/usr/include/string.h:126: error: previous declaration of 'strlcpy' was here
strlfuncs.h:60: error: static declaration of 'strlcat' follows non-static
declaration
/usr/include/string.h:125: error: previous declaration of 'strlcat' was here

Here is the relevant part of /usr/include/string.h:

size_t   strlcat(char *, const char *, size_t);
size_t   strlcpy(char *, const char *, size_t);

I'm not sure why this error occurs.

To continue compiling I used this "patch" which is of course no solution, but
worked for me (I think).

--- lib/framework/strlfuncs.h.orig      2008-01-05 01:06:40.000000000 +0100
+++ lib/framework/strlfuncs.h   2008-04-23 17:42:02.000000000 +0200
@@ -18,6 +18,8 @@
        Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
 */
 
+#define __INCLUDED_FRAMEWORK_STRLFUNCS_H__
+
 #ifndef __INCLUDED_FRAMEWORK_STRLFUNCS_H__
 #define __INCLUDED_FRAMEWORK_STRLFUNCS_H__

Then I got the following problem:

/usr/bin/gcc-4.0 -std=gnu99  -O2  -g -Wall  -L/opt/local/lib -I/usr/X11R6/lib
-o warzone2100 scriptvals_parser.tab.o scriptvals_lexer.lex.o
level_lexer.lex.o ai.o aiexperience.o astar.o action.o advvis.o atmos.o
bridge.o cheat.o cluster.o cmddroid.o combat.o component.o console.o data.o
design.o difficulty.o display.o droid.o e3demo.o edit3d.o effects.o environ.o
fpath.o feature.o formation.o frontend.o gateway.o gatewayroute.o geometry.o
group.o hci.o init.o intdisplay.o intimage.o intorder.o intelmap.o keybind.o
keymap.o levels.o lighting.o loop.o main.o map.o mapdisplay.o mapgrid.o
mechanics.o message.o miscimd.o move.o multiint.o multimenu.o multiopt.o
multisync.o multibot.o multistat.o objmem.o objects.o order.o radar.o
raycast.o research.o scores.o scriptai.o scriptcb.o scriptextern.o
scriptfuncs.o scriptobj.o scripttabs.o scriptvals.o selection.o stats.o
text.o texture.o transporter.o visibility.o warcam.o wrappers.o aud.o
bucket3d.o clparse.o configuration.o display3d.o drive.o function.o game.o
ingameop.o keyedit.o loadsave.o mission.o multigifts.o multijoin.o
multilimit.o multiplay.o multistruct.o oprint.o power.o projectile.o
seqdisp.o structure.o target.o version.o warzoneconfig.o
../lib/widget/libwidget.a ../lib/sequence/libsequence.a
../lib/sound/libsound.a ../lib/script/libscript.a ../lib/netplay/libnetplay.a
../lib/ivis_opengl/libivis_opengl.a ../lib/ivis_common/libivis_common.a
../lib/gamelib/libgamelib.a ../lib/framework/libframework.a
-Wl,-framework,Cocoa -L/opt/local/lib -lSDLmain -lSDL   -lSDL_net -lphysfs
-L/opt/local/lib -lpng12   -L/opt/local/lib -lvorbisfile -lvorbis -lm -logg  
-I/opt/local/lib -lopenal -lGLC -lGL -lGLU -lpopt  
/usr/bin/ld: Undefined symbols:
_libintl_gettext
_libintl_dcgettext
_libintl_ngettext
_libintl_bindtextdomain
_libintl_textdomain
collect2: ld returned 1 exit status

As it wasn't linking against libintl I could fix this with the following
patch.

--- src/Makefile.in.orig        2008-03-16 04:38:29.000000000 +0100
+++ src/Makefile.in     2008-04-23 17:42:06.000000000 +0200
@@ -316,6 +316,7 @@
        $(top_builddir)/lib/framework/libframework.a $(SDL_LIBS) \
        $(SDL_NET_LIBS) $(PHYSFS_LIBS) $(PNG_LIBS) $(OGGVORBIS_LIBS) \
        $(OPENAL_LIBS) $(OPENGLC_LIBS) $(OPENGL_LIBS) $(POPT_LIBS) \
+       $(LIBINTL) \
        $(am__append_1)
 all: $(BUILT_SOURCES)
        $(MAKE) $(AM_MAKEFLAGS) all-am


With theses "patches" the compilation worked. But when I tried to run the
game no fonts were displayed. This is caused by "lib/ivis_opengl/textdraw.c"
because there is no font "DejaVu Sans Mono" on Mac OS X (at least on my
computer). So the following "patch" worked for me. Maybe there could be a
fallback if the font can't be loaded, as mentioned in
https://gna.org/bugs/?11303.

--- lib/ivis_opengl/textdraw.c  2008-04-23 20:15:35.000000000 +0200
+++ lib/ivis_opengl/textdraw.c  2008-04-23 20:16:55.000000000 +0200
@@ -35,7 +35,7 @@
 #include <SDL_opengl.h>
 # include <GL/glc.h>
 
-static const char font_family[] = "DejaVu Sans Mono";
+static const char font_family[] = "Helvetica";
 static const char font_face_regular[] = "Book";
 static const char font_face_bold[] = "Bold";

Then the text was displayed correctly, but when I tried to run the tutorial
mission all textures were black like in https://gna.org/bugs/?11104. I got no
warnings/errors on the command line mentioning any problems.

During the tutorial I got some weird sound problems (maybe similar to
https://gna.org/bugs/?11353). There is a constant noise and I can't hear any
music or voice (not sure if there should be any during the start of the
tutorial).

If you need any more information just ask.

I hope you can help me with some of these problems. Thanks for your great
game,
Simon





    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?11609>

_______________________________________________
  Message sent via/by Gna!
  http://gna.org/


_______________________________________________
Warzone-dev mailing list
Warzone-dev@gna.org
https://mail.gna.org/listinfo/warzone-dev

Reply via email to