Jump to content
XCOMUFO & Xenocide

Compilation problems


DaiShiva

Recommended Posts

  • Replies 113
  • Created
  • Last Reply

Top Posters In This Topic

Sorry to be a bother, but I still can't get it to compile. I've mostly worked with Java, and when using C++ always used Visual C++.

 

I'm compiling on Windows XP: is the makefile correct in that I need to use "make xmingw=1"?

 

Also are the Expat libraries required? You didn't provide a link but I managed to download some form of them.

 

I believe my path is set correctly as make and gcc --version are both found; do any other folders need to be in the path?

 

One more question, what is the directory structure inside the mingw-libs folder? I currently have each library in its own subdirectory, but it doesn't seem to find them.

 

Maybe sending me the precompiled headers would be the simplest solution.

 

Thanks for your patience, Serge :)

Link to comment
Share on other sites

Adventures of Ufo2000 in MEPIS Linux(a debian-based distro.) 3.4-3

 

Install on a Slackware 10.2 running under WinXP VMWare-player was a success right away. "Obvious" dependencies expat, zlib etc. were already there as they should have and allegro, HawkNL etc. compiled from source like the nice boys they are.

Slackware's kernel was 2.4.31 and had libraries in /usr/include/c++/3.3.6.

 

Then I tried it on MEPIS, allegro refused to compile but apt-get smashed her in. HawkNL compiled ok, sqlite I got through apt-get(not sure if it was the right one) and dumb reported undefined references.

 

Tried to compile U2K with a checkout from trunk and with the 0.7.1031 beta.

 

"make"

 

and

 

"make no_dumbogg=1"

 

Both resulted in plenty of errors, which of first was(these are handwritten, might contain typos):

 

"/usr/lib/gcc/i486-linux-gnu/4.0.3/../../../../include/c++/4.0.3/cstring:85: memcmp has not been declared"

 

and there were others like: "memcmp is not a member of std", "memcmp has not been declared in this scope".

 

I tried adding /usr/lib and /usr/include to PATH but to no effect.

 

Am I a bad person or why doesn't this compile? There's a namespace collision somewhere I'd say.

 

BTW is there a need for install instructions for the dependencies? It might increase the chance of John. T. Random installing the game if he sees right away from the INSTALL-file the simple instructions for compiling the dependencies(mostly just make and make install).

Edited by Raging_Hog
Link to comment
Share on other sites

2Kiv:

I'm compiling on Windows XP: is the makefile correct in that I need to use "make xmingw=1"?

No, xmingw=1 is needed when you are actually compiling it on Linux system, but want to get binary for Windows. Just running "make" should be enough.

 

One more question, what is the directory structure inside the mingw-libs folder? I currently have each library in its own subdirectory, but it doesn't seem to find them.

 

Maybe sending me the precompiled headers would be the simplest solution.

Links are now updated (location of precompiled win32 libraries is now the following: http://ufo2000.xcomufo.com/files/mingw-libs.zip).

 

2Raging_Hog:

Am I a bad person or why doesn't this compile? There's a namespace collision somewhere I'd say.

I have no idea, really. The game can be compiled on a wide variety of linux/unix systems. Without having that MEPIS distributive, it is hard to say what can be wrong. If you investigate this problem and find a way to fix it, we can add this information into distributive specific section in the INSTALL file.

 

BTW is there a need for install instructions for the dependencies? It might increase the chance of John. T. Random installing the game if he sees right away from the INSTALL-file the simple instructions for compiling the dependencies(mostly just make and make install).

Simple instructions are OK, but for longer instructions with troubleshooting information it is better to read libraries documentation and bug their developers :)

Link to comment
Share on other sites

Platform:

Knoppix 3.8 live cd under WinXP VMWare-Player

kernel 2.6.11

/usr/include/c++/3.3

 

Dependencies:

sqlite 3.3.5

HawkNL 1.68

allegro 4.2.0

dumb 0.9.2

 

All dependencies above had to be compiled from source, which they did fine. Other dependencies were already found on the system.

 

First error:

obj/bullet.o(.text+0xfcc): In function `Bullet::move()':

: undefined reference to `play_sample'

 

Other errors include similar undefined references to:

al_assert

getb

text_length

scare_mouse

 

and on and on.

 

Things tried:

make no_dumbogg=1

commenting out the play_sample function in item.h(the first error was

another one in this case)

upgrading the libstdc++5

copying allegro.cfg to /etc

being root

/usr/local/lib was in the /etc/ldconfig already(checked it when installing HawkNL)

/sbin/ldconfig was ran

 

I'd say it doesn't find allegro(well du -h, play_sample is an allegro function). I tried including various directories in the path but to no effect. Might this have happened because of the live cd? It seems to show dirs funny, pwd shows /usr but when using locate it shows /RAMDISK/usr etc. If it's a problem with the live cd then it's not that bad(although some live cds can save the changed data so some people might want to play U2K via live cd).

Link to comment
Share on other sites

Here are quick reference instructions for installing the dependencies.

 

Lines starting with #-char are commands for terminal

 

NOTE: downloads from sourceforge may have problems, so you

might have to try several mirrors when obtaining sources.

 

 

First check that you have all dependencies by checking that

locate shows xxx/lib/xxx.x file (probably these libraries are already installed):

#locate freetype

#locate zlib

#locate expat

#locate vorbis

#locate libpng

 

These are more rare:

#locate allegro

#locate hawknl

#locate sqlite

#locate dumb

 

If you didn't have the latter ones, install them:

(these are instructions for compiling from source)

 

allegro:

Get the source code file(4.0.x)

#./configure

#make

#make install

 

HawkNL:

Get the source code file(1.68)

#tar -xvzf HawkNLxxx.tar.gz

#cp makefile.linux makefile

#make

#make install

 

check that the file /etc/ld.so.conf includes

line "/usr/local/lib"

 

#/sbin/ldconfig

 

sqlite:

Get the source code file(version 3)

#tar -xvzf sqlite-xx.x.x.tar.gz

#./configure

#make

#make install

 

dumb:

Get the source code file(0.9.2)

#tar -xvzf dumb-x.x.tar.gz

#make

Answer Y to the question "Would you like support for allegro?"

Press enter on the prompt for installation prefix

#make install

 

ufo2000:

Get the source code file

#tar -xvzf ufo2000-xxx.x.tar.gz

 

#cd ufo2000-src

#make

 

Troubleshooting:

 

* If something fails, try it as root(#su)

* Check if all the dependencies can be found with the locate-command

* Update the locate database with updatedb, then try locate

* Check that all dependencies are in the path

* Try to compile ufo2000 without sound support: #make no_dumbogg=1

Link to comment
Share on other sites

  • 2 months later...

make

 

root@marvis:~/prog/ufo2000-0.7.1062# make

gcc -MMD -funsigned-char -Wall -Wno-deprecated-declarations -I src/lua -I src/luasqlite3 -DDEBUGMODE -DUFO_SVNVERSION=\"exported\" -O2 -pipe -I/usr/include/freetype2 -DHAVE_FREETYPE -DGLYPH_TARGET=GLYPH_TARGET_ALLEGRO -DGK_NO_LEGACY -DHAVE_DUMBOGG -DHAVE_PNG -DLINUX -I/usr/local/include -c src/dumbogg/dumbogg.c -o obj/dumbogg.o

src/dumbogg/dumbogg.c: In function `dumb_load_ogg':

src/dumbogg/dumbogg.c:160: warning: passing arg 3 of `make_duh' from incompatible pointer type

src/dumbogg/dumbogg.c:160: warning: passing arg 4 of `make_duh' makes integer from pointer without a cast

src/dumbogg/dumbogg.c:160: error: too few arguments to function `make_duh'

src/dumbogg/dumbogg.c: In function `ogg_sigrenderer_get_samples':

src/dumbogg/dumbogg.c:224: warning: implicit declaration of function `dumb_resample'

src/dumbogg/dumbogg.c: In function `ogg_sigrenderer_get_current_sample':

src/dumbogg/dumbogg.c:264: warning: implicit declaration of function `dumb_resample_get_current_sample'

src/dumbogg/dumbogg.c: In function `ogg_start_sigrenderer':

src/dumbogg/dumbogg.c:353: error: too few arguments to function `dumb_reset_resampler'

make: *** [obj/dumbogg.o] Error 1

 

 

 

make -k no_dumbogg=1

obj/music.o(.text+0x2d2): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_start_duh'

obj/music.o(.text+0x2e8): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_duh_get_sigrenderer'

obj/music.o(.text+0x2f0): In function `FS_MusicPlay(char const*)':

: undefined reference to `duh_get_it_sigrenderer'

obj/music.o(.text+0x2fa): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_it_callback_terminate'

obj/music.o(.text+0x302): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_it_set_loop_callback'

obj/music.o(.text+0x30c): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_it_callback_terminate'

obj/music.o(.text+0x312): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_it_set_xm_speed_zero_callback'

obj/music.o(.text+0x32c): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_s3m'

obj/music.o(.text+0x347): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_mod'

obj/music.o(.text+0x362): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_it'

obj/music.o(.text+0x385): In function `FS_MusicPlay(char const*)':

: undefined reference to `unload_duh'

obj/music.o(.text+0x3a0): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_stop_duh'

obj/music.o(.text+0x3e5): In function `FS_MusicPlay(char const*)':

: undefined reference to `unload_duh'

obj/music.o(.text+0x405): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_stop_duh'

obj/music.o(.text+0x4ea): In function `FS_SetMusicVolume(int)':

: undefined reference to `al_duh_set_volume'

obj/music.o(.text+0x173): In function `FS_MusicClose()':

: undefined reference to `dumb_exit'

collect2: ld returned 1 exit status

make: *** [ufo2000] Error 1

make: Target `all' not remade because of errors.

root@marvis:~/prog/ufo2000-0.7.1062#

Link to comment
Share on other sites

slackware 10.2

kernel 2.6.17.6

____________

 

# glxinfo

name of display: :0.0

display: :0 screen: 0

direct rendering: Yes

server glx vendor string: SGI

server glx version string: 1.2

server glx extensions:

GLX_ARB_multisample, GLX_EXT_visual_info, GLX_EXT_visual_rating,

GLX_EXT_import_context, GLX_OML_swap_method, GLX_SGI_make_current_read,

GLX_SGIS_multisample, GLX_SGIX_fbconfig

client glx vendor string: ATI

client glx version string: 1.3

client glx extensions:

GLX_EXT_visual_info, GLX_EXT_visual_rating, GLX_EXT_import_context,

GLX_ARB_get_proc_address, GLX_ARB_multisample,

GLX_ATI_pixel_format_float,

GLX_ATI_render_texture

GLX extensions:

GLX_EXT_visual_info, GLX_EXT_visual_rating, GLX_EXT_import_context,

GLX_ARB_multisample

OpenGL vendor string: ATI Technologies Inc.

OpenGL renderer string: RADEON 9800 Pro Generic

OpenGL version string: 2.0.5879 (8.26.18)

OpenGL extensions:

GL_ARB_multitexture, GL_EXT_texture_env_add,

GL_EXT_compiled_vertex_array,

GL_S3_s3tc, GL_ARB_depth_texture, GL_ARB_fragment_program,

GL_ARB_fragment_program_shadow, GL_ARB_fragment_shader,

GL_ARB_multisample, GL_ARB_occlusion_query, GL_ARB_point_parameters,

GL_ARB_point_sprite, GL_ARB_shader_objects, GL_ARB_shading_language_100,

GL_ARB_shadow, GL_ARB_shadow_ambient, GL_ARB_texture_border_clamp,

GL_ARB_texture_compression, GL_ARB_texture_cube_map,

GL_ARB_texture_env_add, GL_ARB_texture_env_combine,

GL_ARB_texture_env_crossbar, GL_ARB_texture_env_dot3,

GL_ARB_texture_mirrored_repeat, GL_ARB_transpose_matrix,

GL_ARB_vertex_blend, GL_ARB_vertex_buffer_object, GL_ARB_vertex_program,

GL_ARB_vertex_shader, GL_ARB_window_pos, GL_ARB_draw_buffers,

GL_ATI_draw_buffers, GL_ATI_element_array, GL_ATI_envmap_bumpmap,

GL_ATI_fragment_shader, GL_ATI_map_object_buffer,

GL_ATI_separate_stencil,

GL_ATI_texture_env_combine3, GL_ATI_texture_float,

GL_ATI_texture_mirror_once, GL_ATI_vertex_array_object,

GL_ATI_vertex_attrib_array_object, GL_ATI_vertex_streams,

GL_ATIX_texture_env_combine3, GL_ATIX_texture_env_route,

GL_ATIX_vertex_shader_output_point_size, GL_EXT_abgr, GL_EXT_bgra,

GL_EXT_blend_color, GL_EXT_blend_func_separate, GL_EXT_blend_minmax,

GL_EXT_blend_subtract, GL_EXT_clip_volume_hint,

GL_EXT_draw_range_elements, GL_EXT_fog_coord, GL_EXT_framebuffer_object,

GL_EXT_multi_draw_arrays, GL_EXT_packed_pixels, GL_EXT_point_parameters,

GL_EXT_rescale_normal, GL_EXT_secondary_color,

GL_EXT_separate_specular_color, GL_EXT_shadow_funcs,

GL_EXT_stencil_wrap,

GL_EXT_texgen_reflection, GL_EXT_texture3D,

GL_EXT_texture_compression_s3tc, GL_EXT_texture_cube_map,

GL_EXT_texture_edge_clamp, GL_EXT_texture_env_combine,

GL_EXT_texture_env_dot3, GL_EXT_texture_filter_anisotropic,

GL_EXT_texture_lod_bias, GL_EXT_texture_mirror_clamp,

GL_EXT_texture_object, GL_EXT_texture_rectangle, GL_EXT_vertex_array,

GL_EXT_vertex_shader, GL_HP_occlusion_test, GL_NV_blend_square,

GL_NV_occlusion_query, GL_NV_texgen_reflection, GL_SGI_color_matrix,

GL_SGIS_generate_mipmap, GL_SGIS_texture_border_clamp,

GL_SGIS_texture_edge_clamp, GL_SGIS_texture_lod,

GL_SUN_multi_draw_arrays

glu version: 1.3

glu extensions:

GLU_EXT_nurbs_tessellator, GLU_EXT_object_space_tess

 

visual x bf lv rg d st colorbuffer ax dp st accumbuffer ms cav

id dep cl sp sz l ci b ro r g b a bf th cl r g b a ns b eat

----------------------------------------------------------------------

0x23 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x24 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x25 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x26 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x27 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 1 0 None

0x28 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 1 0 None

0x29 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 1 0 None

0x2a 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 1 0 None

0x2b 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x2c 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x2d 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x2e 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x2f 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 2 1 None

0x30 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 2 1 None

0x31 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 2 1 None

0x32 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 2 1 None

0x33 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x34 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x35 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x36 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x37 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 4 1 None

0x38 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 4 1 None

0x39 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 4 1 None

0x3a 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 4 1 None

0x3b 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x3c 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x3d 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x3e 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x3f 24 tc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 6 1 None

0x40 24 tc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 6 1 None

0x41 24 tc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 6 1 None

0x42 24 tc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 6 1 None

0x43 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x44 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x45 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x46 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x47 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 1 0 None

0x48 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 1 0 None

0x49 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 1 0 None

0x4a 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 1 0 None

0x4b 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x4c 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x4d 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x4e 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x4f 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 2 1 None

0x50 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 2 1 None

0x51 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 2 1 None

0x52 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 2 1 None

0x53 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x54 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x55 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x56 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x57 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 4 1 None

0x58 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 4 1 None

0x59 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 4 1 None

0x5a 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 4 1 None

0x5b 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x5c 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 16 16 16 16 1 0 None

0x5d 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x5e 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 16 16 16 16 1 0 None

0x5f 24 dc 0 32 0 r y . 8 8 8 8 0 24 8 0 0 0 0 6 1 None

0x60 24 dc 0 32 0 r . . 8 8 8 8 0 24 8 0 0 0 0 6 1 None

0x61 24 dc 0 32 0 r y . 8 8 8 8 0 24 0 0 0 0 0 6 1 None

0x62 24 dc 0 32 0 r . . 8 8 8 8 0 24 0 0 0 0 0 6 1 None

___________________________________-

alsa-driver-1.0.9b_2.4.31-i486-1.tgz

glibc-solibs-2.3.5-i486-5.tgz

__________________

processor : 0

vendor_id : AuthenticAMD

cpu family : 15

model : 39

model name : AMD Athlon 64 Processor 3700+

stepping : 1

cpu MHz : 2298.694

cache size : 1024 KB

fdiv_bug : no

hlt_bug : no

f00f_bug : no

coma_bug : no

fpu : yes

fpu_exception : yes

cpuid level : 1

wp : yes

flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca

cmov pat pse36 clflush mmx fxsr sse sse2 syscall nx mmxext fxsr_opt lm

3dnowext 3dnow up pni lahf_lm ts fid vid ttp tm stc

bogomips : 4605.53

______________________________

cat /proc/pci /proc/pci: No such file or directory -----------------------********************

radeon 9800 pro

asus a8v deluxe viak800pro

2 G kingston 1Gx2

Link to comment
Share on other sites

Wrong DUMB library version (too new), alternatively you can recompile the game with make 'no_dumbogg=1'.

 

still get compile error with that

 

d/ld package

dumb .9.3

dumbogg

get ( make sure ) libogg libvorbis - no help

 

same errors

Link to comment
Share on other sites

i did a hack -

search music - remove all offending lines

but the client crashed on launch...

 

 

i did a hack -

search music - remove all offending lines

but the client crashed on launch...

 

 

hotseat works

perhaps i was just impatient , or soomething ..

minor compile errrors should be easy to fix

 

trying to play myself now ....

 

i am playing myself now...

so maybe i was just impatient ... so impatient ...

my d/l speed is 350

 

anyway ..

what i did was search Music

// out all offending lines

clean up syntax with a ;//

and thats it..

 

i might try to make a patch for u ...

 

im playing a Russain noob now- he beat me first time - lets see if i can win round two.

he threw his gun at me ....

i win Hooah

 

ok i found the older dumb

it looks like it is working

nope didnt work - with dumb dumb-0.9.1.tar

 

src/dumbogg/dumbogg.c:339: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:339: error: `DUMB_RESAMPLER' undeclared (first use in this function)

src/dumbogg/dumbogg.c:340: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:347: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:353: warning: implicit declaration of function `dumb_reset_resampler'

src/dumbogg/dumbogg.c:353: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:353: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:357: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c: In function `ogg_end_sigrenderer':

src/dumbogg/dumbogg.c:375: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:377: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:379: error: dereferencing pointer to incomplete type

src/dumbogg/dumbogg.c:380: error: dereferencing pointer to incomplete type

make: *** [obj/dumbogg.o] Error 1

 

try again ---

nope

 

ction `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_s3m'

obj/music.o(.text+0x347): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_mod'

obj/music.o(.text+0x362): In function `FS_MusicPlay(char const*)':

: undefined reference to `dumb_load_it'

obj/music.o(.text+0x385): In function `FS_MusicPlay(char const*)':

: undefined reference to `unload_duh'

obj/music.o(.text+0x3a0): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_stop_duh'

obj/music.o(.text+0x3e5): In function `FS_MusicPlay(char const*)':

: undefined reference to `unload_duh'

obj/music.o(.text+0x405): In function `FS_MusicPlay(char const*)':

: undefined reference to `al_stop_duh'

obj/music.o(.text+0x4ea): In function `FS_SetMusicVolume(int)':

: undefined reference to `al_duh_set_volume'

obj/music.o(.text+0x173): In function `FS_MusicClose()':

: undefined reference to `dumb_exit'

collect2: ld returned 1 exit status

make: *** [ufo2000] Error 1

 

same error

 

unless somehow the newer dumb screwed up by not allowing a regression...

 

_____________________________________________________

 

 

recompile svn with --ssl

get trunk

make - no

make no dumb - same old samee old - error same

 

patch create

 

ufo2000-0.7.1062

 

that was weird - do a make no dumbogg

and ony had to add the altered main.cpp and music.cpp

 

see if i can make a patch

Edited by commander
Link to comment
Share on other sites

Wrong DUMB library version (too new), alternatively you can recompile the game with make 'no_dumbogg=1'.

 

still get compile error with that

 

d/ld package

dumb .9.3

dumbogg

get ( make sure ) libogg libvorbis - no help

 

same errors

 

ok says i can upload -- thet extension

ill just put it in here

_______________________________

 

Index: src/main.cpp

===================================================================

--- src/main.cpp (revision 1063)

+++ src/main.cpp (working copy)

@@ -332,13 +332,13 @@

*/

int initgame()

{

- FS_MusicPlay(F(cfg_get_setup_music_file_name()));

+ // FS_MusicPlay(F(cfg_get_setup_music_file_name()));

if (!net->init())

{

- FS_MusicPlay(NULL);

+ // FS_MusicPlay(NULL);

return 0;

}

- FS_MusicPlay(NULL);

+ //FS_MusicPlay(NULL);

 

install_timers(speed_unit, speed_bullet, speed_mapscroll);

//mouse_callback = mouser_proc;

@@ -924,8 +924,9 @@

console<<"initvideo"<<std::endl;

initvideo();

 

- FS_MusicInit();

- FS_SetMusicVolume(cfg_get_music_volume());

+ //FS_MusicInit();

+ //FS_SetMusic

+ //Volume(cfg_get_music_volume());

 

LOCK_VARIABLE(CHANGE); LOCK_FUNCTION(mouser_proc);

LOCK_VARIABLE(MOVEIT); LOCK_VARIABLE(ANIMATION); LOCK_FUNCTION(timer_handler);

@@ -1013,7 +1014,7 @@

Map::freepck();

Soldier::freepck();

 

- FS_MusicClose();

+ // FS_MusicClose();

 

soundSystem::getInstance()->shutdown();

closevideo();

@@ -1822,11 +1823,11 @@

if (net->gametype == GAME_TYPE_HOTSEAT)

{

if (win == loss) {

- FS_MusicPlay(F(cfg_get_lose_music_file_name()));

+ //FS_MusicPlay(F(cfg_get_lose_music_file_name()));

back = back_lose;

strcpy(winner, _("DRAW!"));

} else {

- FS_MusicPlay(F(cfg_get_win_music_file_name()));

+ //FS_MusicPlay(F(cfg_get_win_music_file_name()));

back = back_win;

if (win) {

if (turn % 2 == 0) strcpy(winner, _("PLAYER 2 WINS!") );

@@ -1839,11 +1840,11 @@

} else {

// Only go to the top case if it's an exclusive win.

if ((win && (!loss))) {

- FS_MusicPlay(F(cfg_get_win_music_file_name()));

+ //FS_MusicPlay(F(cfg_get_win_music_file_name()));

back = back_win;

strcpy(winner, _("YOU WIN!") );

} else {

- FS_MusicPlay(F(cfg_get_lose_music_file_name()));

+ //FS_MusicPlay(F(cfg_get_lose_music_file_name()));

back = back_lose;

if (!win) strcpy(winner, _("YOU LOSE!") );

else strcpy(winner, _("DRAW!") );

@@ -2025,8 +2026,8 @@

break;

case KEY_ASTERISK: // ?? ToDo: Sound+Music on/off

//soundSystem::getInstance()->play(SS_WINDOW_OPEN_2);

- FS_MusicPlay(NULL);

- g_console->printf(COLOR_SYS_FAIL, _("Music OFF") );

+ //FS_MusicPlay(NULL);

+ g_console->printf(COLOR_SYS_FAIL, _("Musick OFF") );

break;

case KEY_F1:

help( HELP_ENDGAME );

@@ -2046,7 +2047,7 @@

CHANGE = 1;

}

}

- FS_MusicPlay(NULL);

+ //FS_MusicPlay(NULL);

}

 

#ifdef WIN32

@@ -2138,9 +2139,9 @@

MouseRange *temp_mouse_range_ptr;

lua_message( "Start: gameloop" );

if ((rand() % 2) == 1)

- FS_MusicPlay(F(cfg_get_combat2_music_file_name()));

+ ; //FS_MusicPlay(F(cfg_get_combat2_music_file_name()));

else

- FS_MusicPlay(F(cfg_get_combat1_music_file_name()));

+ ; //FS_MusicPlay(F(cfg_get_combat1_music_file_name()));

 

clear_keybuf();

GAMELOOP = 1;

@@ -2610,7 +2611,7 @@

update_visibility();

}

 

- FS_MusicPlay(NULL);

+ //FS_MusicPlay(NULL);

 

GAMELOOP = 0;

 

@@ -2948,9 +2949,9 @@

showtip();

break;

case MAINMENU_GEOSCAPE:

- FS_MusicPlay(F(cfg_get_editor_music_file_name()));

+ //FS_MusicPlay(F(cfg_get_editor_music_file_name()));

geoscape();

- FS_MusicPlay(NULL);

+ //FS_MusicPlay(NULL);

continue;

case MAINMENU_HOTSEAT:

h = sethotseatplay();

__________________________________________________________

Link to comment
Share on other sites

In order to compile the game you have 2 options:

1. install DUMB 0.9.2, version 0.9.3 is not compatible with the game!

2. compile the game without music support, in order to do that just run 'make no_dumbogg=1', you may have to run 'make clean' before that to clean up stale object files

 

All these instructions are available in INSTALL file that is distributed with the game. Is everything clear now?

Link to comment
Share on other sites

In order to compile the game you have 2 options:

1. install DUMB 0.9.2, version 0.9.3 is not compatible with the game!

2. compile the game without music support, in order to do that just run 'make no_dumbogg=1', you may have to run 'make clean' before that to clean up stale object files

 

All these instructions are available in INSTALL file that is distributed with the game. Is everything clear now?

 

sure -- says i already installed 0.9.2 - checking - done --- again ..

 

i guess the dumb was not installed properly

 

trying make ....

and that worked too - must have been a bad dumb install

 

thanks Serge

 

working

works too - see if it runs

all working now

Link to comment
Share on other sites

  • 4 weeks later...

Trying to compile 0.7.1062 on a Debian system. Using g++ 4.1.2 20060729 and all of the required libraries are installed. 'make server' gets quite a ways into it, then dies at this:

 

gcc -MMD -funsigned-char -Wall -Wno-deprecated-declarations -I src/lua -I src/luasqlite3 -DDEBUGMODE -DUFO_SVNVERSION=\"exported\" -O2 -pipe -I/usr/include/freetype2 -DHAVE_FREETYPE -DGLYPH_TARGET=GLYPH_TARGET_ALLEGRO -DGK_NO_LEGACY -DHAVE_DUMBOGG -DHAVE_PNG -DLINUX -I/usr/include -c src/glyphkeeper/glyph.c -o obj/glyph.o

src/glyphkeeper/glyph.c:20:10: error: #include expects "FILENAME" or <FILENAME>

In file included from src/glyphkeeper/glyph.c:271:

src/glyphkeeper/glyph_face.c: In function 'gk_face_driver_name':

src/glyphkeeper/glyph_face.c:41: error: dereferencing pointer to incomplete type

src/glyphkeeper/glyph_face.c:41: error: dereferencing pointer to incomplete type

src/glyphkeeper/glyph_face.c:42: error: dereferencing pointer to incomplete type

In file included from src/glyphkeeper/glyph.c:283:

src/glyphkeeper/glyph_rend.c: In function 'rend_remove_size_object':

src/glyphkeeper/glyph_rend.c:205: warning: implicit declaration of function 'FT_Done_Size'

src/glyphkeeper/glyph_rend.c: In function 'gk_rend_set_face':

src/glyphkeeper/glyph_rend.c:289: warning: implicit declaration of function 'FT_New_Size'

src/glyphkeeper/glyph_rend.c: In function 'gk_rend_set_size_subpixel':

src/glyphkeeper/glyph_rend.c:312: warning: implicit declaration of function 'FT_Activate_Size'

src/glyphkeeper/glyph_rend.c: In function 'rend_update_matrix':

src/glyphkeeper/glyph_rend.c:357: warning: implicit declaration of function 'FT_Matrix_Multiply'

src/glyphkeeper/glyph_rend.c: In function 'rend_workout':

src/glyphkeeper/glyph_rend.c:507: error: dereferencing pointer to incomplete type

src/glyphkeeper/glyph_rend.c:508: error: dereferencing pointer to incomplete type

src/glyphkeeper/glyph_rend.c:510: error: dereferencing pointer to incomplete type

src/glyphkeeper/glyph.c: In function 'gk_face_driver_name':

src/glyphkeeper/glyph_face.c:43: warning: control reaches end of non-void function

make: *** [obj/glyph.o] Error 1

 

this line appears to be the culprit:

#include FT_INTERNAL_OBJECTS_H

 

but I can't make heads or tails of it...

Link to comment
Share on other sites

this line appears to be the culprit:

#include FT_INTERNAL_OBJECTS_H

 

but I can't make heads or tails of it...

Seems like you are having problems with freetype2 library

 

Well, I'm using Freetype2 version 2.2.1. The actual library itself is labeled as such: libfreetype.so.6.3.10

 

The only thing I could find in /usr/include was the following in /usr/include/freetype2/freetype/config/ftheader.h:

 

/*

* Include internal headers definitions from <freetype/internal/...>

* only when building the library.

*/

#ifdef FT2_BUILD_LIBRARY

#define FT_INTERNAL_INTERNAL_H <freetype/internal/internal.h>

#include FT_INTERNAL_INTERNAL_H

#endif /* FT2_BUILD_LIBRARY */

 

 

#endif /* __FT2_BUILD_H__ */

 

 

/* END */

 

I used the following command while my CWD was /usr/include: rgrep FT_INTERNAL *

Edited by FooBar
Link to comment
Share on other sites

Nevertheless it is a problem with freetype2 library. I know that many distributions have separate package for binary (should be preinstalled almost everywhere) and separate package for headers and other stuff needed for development. Check if you have something like this installed (but don't know for sure as I don't use debian myself).

 

Also it it does not help, please check if you can run 'freetype-config' and please paste output of 'freetype-config --cflags --libs'.

 

In the worst case please try building the game without ttf fonts support: 'make no_ttf=1' (but do 'make clean' before that).

 

Hope this helps.

Link to comment
Share on other sites

Now I'm running SimplyMEPIS 6.0 (Ubuntu Dapper-based distro)

Kernel 2.6.15-26-386

 

Ufo2k compiled ok after these tricks:

 

I went through all the dependencies (including the "obvious" ones) with Synaptic and briskly installed development files for all of them and atleast zlib. With defaults, dumb is version 0.9.3 and I couldn't find a way to install it via Synaptic so did it like men, from the source.

 

Ufo2000 didn't find the NL.so.1.6 -file before I copied it from /usr/local/lib (HawkNL default install dir) to /usr/lib.

 

During HawkNL install, I also had to remove libNL*-files in /usr/local/lib because it tried to make symlinks of existing files (or something like that) and complained a lot.

 

And after exiting the game the screen goes bit weird leaving the resolution as the games and not showing everything. This is easily fixed from System Configuration->Peripherals->Display and switching resolution. I'll get a svn checkout some beautiful day and see if the problem shows up there.

 

Hopefully this prevents someone from swallowing the shotgun.

Edited by Raging_Hog
Link to comment
Share on other sites

  • 5 months later...

>Also it it does not help, please check if you can run 'freetype-config' and please paste output of 'freetype-config --cflags --libs'.

 

freetype-config --cflags --libs :

-I/usr/include/freetype2

-lfreetype -lz

 

 

 

 

>In the worst case please try building the game without ttf fonts support: 'make no_ttf=1' (but do 'make clean' before that).

 

 

gcc -MMD -funsigned-char -Wall -Wno-deprecated-declarations -I src/lua -I src/luasqlite3 -DDEBUGMODE -DUFO_SVNVERSION=\"1069M\" -O2 -pipe -I/usr/include/freetype2 -DHAVE_FREETYPE -DGLYPH_TARGET=GLYPH_TARGET_ALLEGRO -DGK_NO_LEGACY -DHAVE_DUMBOGG -DHAVE_PNG -DLINUX -I/usr/include -c src/glyphkeeper/glyph.c -o obj/glyph.o

src/glyphkeeper/glyph.c:20:10: error: #include expects "FILENAME" or <FILENAME>

In file included from src/glyphkeeper/glyph.c:271:

src/glyphkeeper/glyph_face.c: In function 'gk_face_driver_name':

src/glyphkeeper/glyph_face.c:41: error: dereferencing pointer to incomplete type

Link to comment
Share on other sites

>In the worst case please try building the game without ttf fonts support: 'make no_ttf=1' (but do 'make clean' before that).

 

gcc -MMD -funsigned-char -Wall -Wno-deprecated-declarations -I src/lua -I src/luasqlite3 -DDEBUGMODE -DUFO_SVNVERSION=\"1069M\" -O2 -pipe -I/usr/include/freetype2 -DHAVE_FREETYPE -DGLYPH_TARGET=GLYPH_TARGET_ALLEGRO -DGK_NO_LEGACY -DHAVE_DUMBOGG -DHAVE_PNG -DLINUX -I/usr/include -c src/glyphkeeper/glyph.c -o obj/glyph.o

src/glyphkeeper/glyph.c:20:10: error: #include expects "FILENAME" or

In file included from src/glyphkeeper/glyph.c:271:

src/glyphkeeper/glyph_face.c: In function 'gk_face_driver_name':

src/glyphkeeper/glyph_face.c:41: error: dereferencing pointer to incomplete type

Apparently you did not use 'no_ttf=1' make option, otherwise you would not have -DHAVE_FREETYPE defined.

Link to comment
Share on other sites

True. Could you please post working version numbers for libraries ?

Right now I have allegro 4.2.0, hawknl 1.68 and freetype 2.1.10 installed, that's the minimal set of dependencies to build and run the game.

 

As for freetype problems, it you checked another thread, you should know that they were fixed already :) I tested both freetype 2.1.10 and 2.3.1 and they seem to work fine. If you are still having problems, feel free to report them and I'll try to help.

 

PS. I hope to drop hawknl dependency eventually

Link to comment
Share on other sites

I compiled on linux, at length. However the make install command was evidently broken. I looked into the makefile, and what I saw can't possibly be right. Its executing subversion commands (even though I didn't get it from svn)

 

On a sidenote, please think of dropping dumbogg as well. My distro doesn't even have the old version of the dumb library that it works with.

Link to comment
Share on other sites

I compiled on linux, at length. However the make install command was evidently broken. I looked into the makefile, and what I saw can't possibly be right. Its executing subversion commands (even though I didn't get it from svn)

This 'make install' target was added for half finished debian packages creation (check this thread for more details: http://www.xcomufo.com/forums/index.php?showtopic=242025301). Don't use this option or fix it.

 

On a sidenote, please think of dropping dumbogg as well. My distro doesn't even have the old version of the dumb library that it works with.

This is already planned :)

Link to comment
Share on other sites

I compiled on linux, at length. However the make install command was evidently broken. I looked into the makefile, and what I saw can't possibly be right. Its executing subversion commands (even though I didn't get it from svn)

This 'make install' target was added for half finished debian packages creation (check this thread for more details: http://www.xcomufo.com/forums/index.php?showtopic=242025301). Don't use this option or fix it.

 

On a sidenote, please think of dropping dumbogg as well. My distro doesn't even have the old version of the dumb library that it works with.

This is already planned :)

 

http://62.2.177.13/stuff/

 

There id built debian packages and some patches

Link to comment
Share on other sites

  • 1 month later...

First off, I've already got the source to compile on this machine using MinGW-- except, I didn't do it with subversion... I used the source archive off of sourceforge.net.

 

Now I have two problems:

 

1. I can't get subversion to checkout the source code. It got about half of it, and now it keeps telling me "REPORT request failed on '/svnroot/ufo2000/!svn/vcc/default'" and then "Could not read response body : Secure connection truncated". The first couple times I just typed checkout again and it resumed... so I figure that this is a loss of connection due to my slow (56k) internet connection. Is there a workaround?

2. Being rather partial to the .NET language, I'd like to get it working in MSVC++8. I *think* I'm close, because it's finding all the headers (I added MinGW to the list of header paths), but it talks about invalid preprocessor instructions. Is there something I forgot to do?

 

EDIT:

 

Okay, so I just kept restarting the checkout until it finished, and now I have the latest revision checked out on my harddisk.

 

As for #2, am sending an email to the mailing list for help.

Edited by ZeldaFreak
Link to comment
Share on other sites

Is ufo2000.xcomufo.com gonna be up anymore? If not, it'd be really handy if the libs were mirrored somewhere else... (and it would be prudent otherwise too, just in case.)
Link to comment
Share on other sites

I have dumb, hawk-nl and allegro, I don't know what files I should put and where, the compiler of course complains that it can't find allegro.h, since there's a #include <allegro.h> and the makefile isn't helpful either as allegro is mentioned in very few places...

 

edit: I realize I'd have to flirt with allegro, I'd have to somehow enable the allegro config command:

INCLUDES = ${shell allegro-config --cflags}

Edited by bamb
Link to comment
Share on other sites

  • 1 month later...
...

2. Being rather partial to the .NET language, I'd like to get it working in MSVC++8. I *think* I'm close, because it's finding all the headers (I added MinGW to the list of header paths), but it talks about invalid preprocessor instructions. Is there something I forgot to do?

The sources are quite portable and should be compilable with MSVC or any other C++ compiler, probably with a few tweaks. MSVC support is just not maintained as it would require taking extra care to keep it up to date while MinGW uses the same build system as unix/linux. In addition, automatic crashreporting system will not work with MSVC (it contains nonportable compiler dependent code).

 

As for #2, am sending an email to the mailing list for help.

What mailing list?

Edited by Serge
Link to comment
Share on other sites

Thanks for the reply! I never actually sent anything to the mailing list-- if I remember right (as I posted that a while ago) I got it to compile in MSYS (or one of those other acronymed applications starting with M) and so I wasn't worried about it... but now I am working on a different project for XCOM:EU, so I am no longer in need of help. But thank you for the response, anyhow!

 

~Zeldafreak

Link to comment
Share on other sites

  • 2 months later...
Guest Azrael

After struggling for some hours with Kratos, I managed to use Make, but I get the following errors:

 

$ make
Type 'svnversion --help' for usage.
mkdir obj-win32
g++ -MMD -funsigned-char -Wall -Wno-deprecated-declarations -I src/lua -I src/luasqlite3 -DDEBUGMODE -O2 -pipe -DHAVE_FREETYPE -DGLYPH_TARGET=GLYPH_TARGET_ALLEGRO -DGK_NO_LEGACY -DHAVE_DUMBOGG -DHAVE_PNG -DWIN32 -DALLEGRO_STATICLINK -I mingw-libs/include -L mingw-libs/lib -c src/bullet.cpp -o obj-win32/bullet.o
In file included from src/stdafx.h:19,
			 from src/bullet.cpp:22:
src/jpgalleg/jpgalleg.h:23:21: warning: allegro.h: No such file or directory
In file included from src/stdafx.h:19,
			 from src/bullet.cpp:22:
src/jpgalleg/jpgalleg.h:68: syntax error before `*' token
src/jpgalleg/jpgalleg.h:69: syntax error before `*' token
src/jpgalleg/jpgalleg.h:70: syntax error before `*' token
src/jpgalleg/jpgalleg.h:71: syntax error before `*' token
src/jpgalleg/jpgalleg.h:73: `AL_CONST' was not declared in this scope
src/jpgalleg/jpgalleg.h:73: parse error before `char'
src/jpgalleg/jpgalleg.h:74: `AL_CONST' was not declared in this scope
src/jpgalleg/jpgalleg.h:74: parse error before `char'
src/jpgalleg/jpgalleg.h:74: `save_jpg_ex' declared as function returning a 
  function
src/jpgalleg/jpgalleg.h: In function `int save_jpg_ex(...)':
src/jpgalleg/jpgalleg.h:74: parse error before `)' token
src/jpgalleg/jpgalleg.h:75: type specifier omitted for parameter `BITMAP'
src/jpgalleg/jpgalleg.h:75: parse error before `*' token
src/jpgalleg/jpgalleg.h:76: type specifier omitted for parameter `BITMAP'
src/jpgalleg/jpgalleg.h:76: parse error before `*' token
src/jpgalleg/jpgalleg.h:76: `save_memory_jpg_ex' declared as function returning 
  a function
src/jpgalleg/jpgalleg.h: In function `int save_memory_jpg_ex(...)':
src/jpgalleg/jpgalleg.h:76: parse error before `)' token
In file included from src/stdafx.h:20,
			 from src/bullet.cpp:22:
src/fpasprite/fpasprite.h:17:21: warning: allegro.h: No such file or directory
src/fpasprite/fpasprite.h:31:2: #error Can not define int32 type
In file included from src/stdafx.h:20,
			 from src/bullet.cpp:22:
src/fpasprite/fpasprite.h:34: syntax error before `;' token
src/fpasprite/fpasprite.h:46: `BITMAP' undeclared (first use this function)
src/fpasprite/fpasprite.h:46: (Each undeclared identifier is reported only once 
  for each function it appears in.)
src/fpasprite/fpasprite.h:46: `dst' undeclared (first use this function)
src/fpasprite/fpasprite.h:46: `src' undeclared (first use this function)
src/fpasprite/fpasprite.h:46: parse error before `,' token
src/fpasprite/fpasprite.h:52: syntax error before `*' token
src/fpasprite/fpasprite.h:54: syntax error before `*' token
src/fpasprite/fpasprite.h:59: `ALPHA_SPRITE' undeclared (first use this 
  function)
src/fpasprite/fpasprite.h:59: `spr' undeclared (first use this function)
src/fpasprite/fpasprite.h:59: variable or field `destroy_alpha_sprite' declared 
  void
src/fpasprite/fpasprite.h:71: parse error before `,' token
In file included from src/stdafx.h:23,
			 from src/bullet.cpp:22:
src/agup/agup.h:16: parse error before `*' token
src/agup/agup.h:18: type specifier omitted for parameter `DATAFILE'
src/agup/agup.h:18: parse error before `*' token
src/agup/agup.h:19: syntax error before `*' token
src/agup/agup.h:21: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:21: parse error before `*' token
src/agup/agup.h:22: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:22: parse error before `*' token
src/agup/agup.h:23: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:23: parse error before `*' token
src/agup/agup.h:24: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:24: parse error before `*' token
src/agup/agup.h:25: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:25: parse error before `*' token
src/agup/agup.h:26: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:26: parse error before `*' token
src/agup/agup.h:27: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:27: parse error before `*' token
src/agup/agup.h:28: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:28: parse error before `*' token
src/agup/agup.h:29: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:29: parse error before `*' token
src/agup/agup.h:30: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:30: parse error before `*' token
src/agup/agup.h:31: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:31: parse error before `*' token
src/agup/agup.h:32: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:32: parse error before `*' token
src/agup/agup.h:33: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:33: parse error before `*' token
src/agup/agup.h:34: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:34: parse error before `*' token
src/agup/agup.h:35: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:35: parse error before `*' token
src/agup/agup.h:36: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:36: parse error before `*' token
src/agup/agup.h:37: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:37: parse error before `*' token
src/agup/agup.h:38: type specifier omitted for parameter `DIALOG'
src/agup/agup.h:38: parse error before `*' token
src/agup/agup.h:40: syntax error before `*' token
src/agup/agup.h:41: syntax error before `*' token
src/agup/agup.h:42: syntax error before `*' token
src/agup/agup.h:43: syntax error before `*' token
src/agup/agup.h:44: syntax error before `*' token
src/agup/agup.h:45: syntax error before `*' token
src/agup/agup.h:46: syntax error before `*' token
In file included from src/stdafx.h:32,
			 from src/bullet.cpp:22:
c:/mingw/include/time.h: In function `int __iscsym(int)':
c:/mingw/include/time.h:99: non-local function `time_t 
  mktime(__iscsym(int)::tm*)' uses local type `__iscsym(int)::tm'
c:/mingw/include/time.h:111: non-local function `char* asctime(const 
  __iscsym(int)::tm*)' uses local type `const __iscsym(int)::tm'
c:/mingw/include/time.h:113: non-local function `__iscsym(int)::tm* 
  gmtime(const time_t*)' uses local type `__iscsym(int)::tm'
c:/mingw/include/time.h:114: non-local function `__iscsym(int)::tm* 
  localtime(const time_t*)' uses local type `__iscsym(int)::tm'
c:/mingw/include/time.h:117: non-local function `size_t strftime(char*, 
  unsigned int, const char*, const __iscsym(int)::tm*)' uses local type `const 
  __iscsym(int)::tm'
c:/mingw/include/time.h:119: non-local function `size_t wcsftime(wchar_t*, 
  unsigned int, const wchar_t*, const __iscsym(int)::tm*)' uses local type `
  const __iscsym(int)::tm'
c:/mingw/include/time.h:188: non-local function `wchar_t* _wasctime(const 
  __iscsym(int)::tm*)' uses local type `const __iscsym(int)::tm'
In file included from src/bullet.cpp:22:
src/stdafx.h:33:16: warning: nl.h: No such file or directory
src/stdafx.h:37:21: warning: allegro.h: No such file or directory
src/stdafx.h:38:38: warning: allegro/internal/aintern.h: No such file or directory
src/stdafx.h:40:22: warning: winalleg.h: No such file or directory
In file included from src/stdafx.h:45,
			 from src/bullet.cpp:22:
c:/mingw/include/sys/stat.h:157: non-local function `int _fstat(int, 
  __iscsym(int)::_stat*)' uses local type `__iscsym(int)::_stat'
c:/mingw/include/sys/stat.h:159: non-local function `int _stat(const char*, 
  __iscsym(int)::_stat*)' uses local type `__iscsym(int)::_stat'
c:/mingw/include/sys/stat.h:162: non-local function `int _fstati64(int, 
  __iscsym(int)::_stati64*)' uses local type `__iscsym(int)::_stati64'
c:/mingw/include/sys/stat.h:163: non-local function `int _stati64(const char*, 
  __iscsym(int)::_stati64*)' uses local type `__iscsym(int)::_stati64'
c:/mingw/include/sys/stat.h:165: non-local function `int _wstat(const wchar_t*, 
  __iscsym(int)::_stat*)' uses local type `__iscsym(int)::_stat'
c:/mingw/include/sys/stat.h:166: non-local function `int _wstati64(const 
  wchar_t*, __iscsym(int)::_stati64*)' uses local type `
  __iscsym(int)::_stati64'
c:/mingw/include/sys/stat.h:174: non-local function `int fstat(int, 
  __iscsym(int)::stat*)' uses local type `__iscsym(int)::stat'
c:/mingw/include/sys/stat.h:176: non-local function `int stat(const char*, 
  __iscsym(int)::stat*)' uses local type `__iscsym(int)::stat'
In file included from src/stdafx.h:46,
			 from src/bullet.cpp:22:
c:/mingw/include/stdlib.h: In function `float wcstof(const wchar_t*, 
  wchar_t**)':
c:/mingw/include/stdlib.h:398: non-local function `wcstof(const wchar_t*, 
  wchar_t**)::div_t div(int, int)' uses local type `wcstof(const wchar_t*, 
  wchar_t**)::div_t'
c:/mingw/include/stdlib.h:399: non-local function `wcstof(const wchar_t*, 
  wchar_t**)::ldiv_t ldiv(long int, long int)' uses local type `wcstof(const 
  wchar_t*, wchar_t**)::ldiv_t'
c:/mingw/include/stdlib.h: In function `void _Exit(int)':
c:/mingw/include/stdlib.h:488: non-local function `_Exit(int)::lldiv_t 
  lldiv(long long int, long long int)' uses local type `_Exit(int)::lldiv_t'
In file included from c:/mingw/include/c++/3.2.3/iosfwd:45,
			 from c:/mingw/include/c++/3.2.3/ios:44,
			 from c:/mingw/include/c++/3.2.3/ostream:45,
			 from c:/mingw/include/c++/3.2.3/iostream:45,
			 from src/stdafx.h:56,
			 from src/bullet.cpp:22:
c:/mingw/include/c++/3.2.3/bits/stringfwd.h: In function `wchar_t* ulltow(long 
  long unsigned int, wchar_t*, int)':
c:/mingw/include/c++/3.2.3/bits/stringfwd.h:54: parse error before `<' token
c:/mingw/include/c++/3.2.3/bits/stringfwd.h:58: explicit specialization in 
  non-namespace scope `wchar_t* ulltow(long long unsigned int, wchar_t*, int)'
c:/mingw/include/c++/3.2.3/bits/stringfwd.h:58: `char_traits' is not a template
c:/mingw/include/c++/3.2.3/bits/stringfwd.h:60: syntax error before `;' token
c:/mingw/include/c++/3.2.3/cstddef:51: confused by earlier errors, bailing out
make: *** [obj-win32/bullet.o] Error 1

 

Compiling using everything posted by Serge in the Compilation Instructions thread under Windows XP.

Link to comment
Share on other sites

Guest Azrael
Do you have the libraries zip that has allegro? It's the allegro problem, looks like that.

 

Compiling using everything posted by Serge in the Compilation Instructions thread
Link to comment
Share on other sites

Compiling using everything posted by Serge in the Compilation Instructions thread

 

Including the following part too?

... To successfully compile the game you will also need a set of additional libraries (Allegro, Expat, ...). A good news is that we already have them compiled and packaged. Download http://ufo2000.xcomufo.com/files/mingw-libs.zip and extract it to ufo2000 sources directory. You will get mingw-libs subdirectory with all the needed libraries ready for use.

 

The directory structure should look like this:

...

Please check if 'allegro.h' file is present in 'mingw-libs/include' directory. The compiler can't find this file according to its error messages.

Link to comment
Share on other sites

Guest Azrael
Compiling using everything posted by Serge in the Compilation Instructions thread

 

Including the following part too?

... To successfully compile the game you will also need a set of additional libraries (Allegro, Expat, ...). A good news is that we already have them compiled and packaged. Download http://ufo2000.xcomufo.com/files/mingw-libs.zip and extract it to ufo2000 sources directory. You will get mingw-libs subdirectory with all the needed libraries ready for use.

 

The directory structure should look like this:

...

Please check if 'allegro.h' file is present in 'mingw-libs/include' directory. The compiler can't find this file according to its error messages.

The compiled Allegro libraries and others were outdated, Natchwolf provided the updated libraries today and I was able to build successfully :)

Link to comment
Share on other sites

Guest Azrael

Can anyone tell me what kind of compile errors are these? (i.e. what do they mean, I'm not yet familiar with this compiler).

 

In file included from src/cell.h:26,
			 from src/map.h:26,
			 from src/bullet.cpp:28:
src/place.h:35: declaration of `struct Item::Place'
src/item.h:37: changes meaning of `Place' from `struct Place'
In file included from src/soldier.h:29,
			 from src/cell.h:27,
			 from src/map.h:26,
			 from src/bullet.cpp:28:
src/skin.h:52: storage class specified for field `g_skins'
src/skin.h:53: storage class specified for field `g_skins_count'
In file included from src/cell.h:27,
			 from src/map.h:26,
			 from src/bullet.cpp:28:
src/soldier.h:111: declaration of `struct Item::Soldier'
src/global.h:264: changes meaning of `Soldier' from `struct Soldier'
src/bullet.cpp:37: cannot declare member `Bullet::hit_bullet' within `Item'
src/bullet.cpp:37: cannot declare member `Bullet::hit_laser' within `Item'
src/bullet.cpp:37: cannot declare member `Bullet::hit_plasma' within `Item'
src/bullet.cpp:37: cannot declare member `Bullet::hit_punch' within `Item'
src/bullet.cpp:39: cannot declare member function `Bullet::GetPersistenceID' 
  within `Item'
src/bullet.cpp:39: `persist::Engine& Item::operator>>(persist::Engine&, 
  Bullet*&)' must take exactly one argument
src/bullet.cpp:39: `persist::Engine& Item::operator<<(persist::Engine&, const 
  Bullet*)' must take exactly one argument
src/bullet.cpp:39: invalid use of undefined type `class Item'
src/item.h:48: forward declaration of `class Item'
src/bullet.cpp:39: invalid data member initialization
src/bullet.cpp:39: (use `=' to initialize static data members)
src/bullet.cpp:39: cannot declare member `Bullet::RegistrationForBullet' within 
  `Item'
src/bullet.cpp:42: cannot declare member function `Bullet::Bullet' within `Item
  '
src/bullet.cpp:59: cannot declare member function `Bullet::Bullet' within `Item
  '
src/bullet.cpp:67: cannot declare member function `Bullet::punch' within `Item'
src/bullet.cpp:99: cannot declare member function `Bullet::fire' within `Item'
src/bullet.cpp:114: cannot declare member function `Bullet::beam' within `Item'
src/bullet.cpp:155: cannot declare member function `Bullet::thru' within `Item'
src/bullet.cpp:168: cannot declare member function `Bullet::aimedthrow' within 
  `Item'
src/bullet.cpp:182: cannot declare member function `Bullet::hitcell' within `
  Item'
src/bullet.cpp:204: cannot declare member function `Bullet::move' within `Item'
src/bullet.cpp:349: cannot declare member function `Bullet::draw_bullet_trace' 
  within `Item'
src/bullet.cpp:393: cannot declare member function `Bullet::draw' within `Item'
src/bullet.cpp:576: cannot declare member function `Bullet::showline' within `
  Item'
src/bullet.cpp:639: cannot declare member function `Bullet::showthrow' within `
  Item'
src/bullet.cpp:695: cannot declare member function `Bullet::calc_throw' within 
  `Item'
src/bullet.cpp:724: cannot declare member function `Bullet::explodable' within 
  `Item'
src/bullet.cpp:733: cannot declare member function `Bullet::incendiary' within 
  `Item'
src/bullet.cpp:740: cannot declare member function `Bullet::detonate' within `
  Item'
src/bullet.cpp:745: cannot declare member function `Bullet::hitman' within `
  Item'
src/bullet.cpp:784: cannot declare member function `Bullet::affect_morale' 
  within `Item'
src/bullet.cpp:818: cannot declare member function `Bullet::Write' within `Item
  '
src/bullet.cpp:827: cannot declare member function `Bullet::Read' within `Item'
src/bullet.cpp:836: parse error at end of input
make: *** [obj-win32/bullet.o] Error 1

 

I reverted my modifications to bullet.cpp and yet I'm getting these errors.

 

Only files I've made modifications to: Item.h, Item.cpp, Soldier.cpp and probably Soldier.h.

Link to comment
Share on other sites

A try from my side (although I guess I shouldn't be talking because I don't even know which "include"s each file includes xD):

 

src/bullet.cpp:836: parse error at end of input
That probably means that there's a syntax error somewhere, I guess near the start (around line, say, 28? :wink1:). Usually, when a syntax error occurs, a lot of errors show up from that point and after :o, so imo make sure the file is syntactically correct

 

In addition, notice this:

 

src/bullet.cpp:39: invalid use of undefined type `class Item'
So, just recall what you changed in that class. IIt seems that most of the errors in the log are connected in a way or another with that class (and Bullet class)

 

In addition:

src/soldier.h:111: declaration of `struct Item::Soldier'

src/global.h:264: changes meaning of `Soldier' from `struct Soldier'

Hmmm

 

So, I guess you just made a lot of small changes, and thinks are a bit messed up right now : \

Edited by kafros
Link to comment
Share on other sites

Guest Azrael
A try from my side (although I guess I shouldn't be talking because I don't even know which "include"s each file includes xD):

 

src/bullet.cpp:836: parse error at end of input
That probably means that there's a syntax error somewhere, I guess near the start (around line, say, 28? :wink1:). Usually, when a syntax error occurs, a lot of errors show up from that point and after :o, so imo make sure the file is syntactically correct

 

In addition, notice this:

 

src/bullet.cpp:39: invalid use of undefined type `class Item'
So, just recall what you changed in that class. IIt seems that most of the errors in the log are connected in a way or another with that class (and Bullet class)

 

In addition:

src/soldier.h:111: declaration of `struct Item::Soldier'

src/global.h:264: changes meaning of `Soldier' from `struct Soldier'

Hmmm

 

So, I guess you just made a lot of small changes, and thinks are a bit messed up right now : \

Read up, I did not change anything in Bullet.cpp, there should not be an error there.

And as for Soldier and the rest, the errors coming up are not from the lines I modified, but obviously my changes are the ones generating problems, I'm just not seeing where, there should be none in Bullet.cpp.

Link to comment
Share on other sites

A try from my side (although I guess I shouldn't be talking because I don't even know which "include"s each file includes xD):

 

src/bullet.cpp:836: parse error at end of input
That probably means that there's a syntax error somewhere, I guess near the start (around line, say, 28? :wink1:). Usually, when a syntax error occurs, a lot of errors show up from that point and after :o, so imo make sure the file is syntactically correct

 

In addition, notice this:

 

src/bullet.cpp:39: invalid use of undefined type `class Item'
So, just recall what you changed in that class. IIt seems that most of the errors in the log are connected in a way or another with that class (and Bullet class)

 

In addition:

src/soldier.h:111: declaration of `struct Item::Soldier'

src/global.h:264: changes meaning of `Soldier' from `struct Soldier'

Hmmm

 

So, I guess you just made a lot of small changes, and thinks are a bit messed up right now : \

Read up, I did not change anything in Bullet.cpp, there should not be an error there.

And as for Soldier and the rest, the errors coming up are not from the lines I modified, but obviously my changes are the ones generating problems, I'm just not seeing where, there should be none in Bullet.cpp.

 

Make a problem in one place and it can easily link to other files. If you aint changed anything, just try ignoring it for now and see if you can fix the stuff you broke in the soldier file. BTW nice to see somone taking up the chanllange of programming again.

Link to comment
Share on other sites

In file included from src/cell.h:26,
                from src/map.h:26,
                from src/bullet.cpp:28:
src/place.h:35: declaration of `struct Item::Place'
src/item.h:37: changes meaning of `Place' from `struct Place'

 

That's the important part. First errors are usually the source of the problem.

 

You screwed the item object, under "Item.h"

Since item.h is included by Bullet.cpp, it calls the errors that occurred in Item, from the use of bullet.

 

Looks like it's a bad use of "struct" keyword but it might be something else, related to this.

Edited by nachtwolf
Link to comment
Share on other sites

Guest Azrael
In file included from src/cell.h:26,
                from src/map.h:26,
                from src/bullet.cpp:28:
src/place.h:35: declaration of `struct Item::Place'
src/item.h:37: changes meaning of `Place' from `struct Place'

 

That's the important part. First errors are usually the source of the problem.

 

You screwed the item object, under "Item.h"

Since item.h is included by Bullet.cpp, it calls the errors that occurred in Item, from the use of bullet.

 

Looks like it's a bad use of "struct" keyword but it might be something else, related to this.

Aye, fixed it by doing my changes one by one and more carefully, watching compiler messages, thanks :)

Link to comment
Share on other sites

  • 3 weeks later...

I've just downloaded the source from svn, and installed the necessary components to compile under Windows, but I get an error when linking:

/mingw/lib/libbfd.a(cache.o):cache.c:(.text+0x35d): undefined reference to `unlink_if_ordinary'
collect2: ld returned 1 exit status
make: *** [ufo2000.exe] Error 1

 

I think I followed the instructions on the website. I installed Mingw32, svn, msys, and the updated mingw32-libraries. (But, it's always possible I goofed somewhere)

 

If anybody knows where my missing library is, let me know.

 

Thanks,

PaulH

Link to comment
Share on other sites

Code tags are empty on my screen too at the beginning, but text appear after few seconds.

If text is still unreadable I have copied it from PaulH post and pasted it here:

 

code:

 

/mingw/lib/libbfd.a(cache.o):cache.c:(.text+0x35d): undefined reference to `unlink_if_ordinary'

collect2: ld returned 1 exit status

make: *** [ufo2000.exe] Error 1

Edited by Intri
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×
×
  • Create New...