URL: <http://gna.org/bugs/?15627>
Summary: build fails on Solaris due to conflicting type with offset_t redefined in featured_text.h Project: Freeciv Submitted by: None Submitted on: Monday 03/15/2010 at 12:04 CET Category: ai Severity: 3 - Normal Priority: 5 - Normal Status: None Assigned to: None Originator Email: opensola...@free.fr Open/Closed: Open Release: 2.2.0 Discussion Lock: Any Operating System: None Planned Release: _______________________________________________________ Details: In Solaris, offset_t is defined as a long long but Freeciv redefines it as an int in common/featured_text.h. $ grep offset_t /usr/include/sys/types.h typedef longlong_t offset_t; $ grep offset_t freeciv-2.2.0/common/featured_text.h typedef int offset_t; As a result, I am getting this compilation error. libtool: compile: gcc -DHAVE_CONFIG_H -I. -I.. -I../utility -I./aicore -DLOCALEDIR=\"/usr/local/share/locale\" "-DDEFAULT_DATA_PATH=\".:data:~/.freeciv:/usr/local/share/freeciv\"" -Wall -Wpointer-arith -Wcast-align -Wmissing-prototypes -Wmissing-declarations -g -O2 -MT featured_text.lo -MD -MP -MF .deps/featured_text.Tpo -c featured_text.c -o featured_text.o In file included from featured_text.c:34: featured_text.h:96: error: conflicting types for 'offset_t' /usr/sfw/lib/gcc/i386-pc-solaris2.10/3.4.3/include/sys/types.h:233: error: previous declaration of 'offset_t' was here I could build a binary by commenting out the typedef in common/featured_text.h, it worked (see http://blogs.sun.com/openomics/entry/freeciv_2_2_for_solaris) but I do not know whether this can have some side impacts. _______________________________________________________ Reply to this item at: <http://gna.org/bugs/?15627> _______________________________________________ Message sent via/by Gna! http://gna.org/ _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev