Problems compiling T2D on Linux
by John Aegard · in Torque Game Builder · 05/31/2005 (10:13 pm) · 1 replies
I get a compiler error when I try to make T2D on my Fedora Core 3 linux box. Here's the complete flow:
[johnzo@schiff SDK]$ gcc -v
Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=i386-redhat-linux
Thread model: posix
gcc version 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)
[johnzo@schiff SDK]$ uname -a
Linux schiff.johnzo.com 2.6.10-1.770_FC3 #1 Thu Feb 24 14:00:06 EST 2005 i686 athlon i386 GNU/Linux
johnzo@schiff SDK]$ make -f mk/configure.mk COMPILER=GCC3 BUILD=DEBUG OS=LINUX
Current Configuration: this config is VALID
OS: LINUX
COMPILER: GCC3
BUILD: DEBUG
DIR.OBJ: out
To change the current configuration type:
make -f mk/configure.mk {arguments, ...}
required arguments:
OS={WIN32 BEOS LINUX OpenBSD FreeBSD Solaris}
COMPILER={CW6 VC6 GCC2 GCC3}
BUILD={DEBUG RELEASE}
optional arguments:
DIR.OBJ={path to store intermediate obj files}
Note: all arguments are case sensitive.
johnzo@schiff SDK]$ make
--> Compiling audio/audio.cc
In file included from ./audio/audioBuffer.h:16,
from ./audio/audioDataBlock.h:13,
from ./audio/audio.h:13,
from audio/audio.cc:6:
./core/resManager.h: In member function 'void Resource::unlock()':
./core/resManager.h:255: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h: In member function 'void Resource::purge()':
./core/resManager.h:263: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h:265: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h: In member function 'void Resource::_unlock()':
./core/resManager.h:278: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
audio/audio.cc: In function 'int loopingImageSort(const void*, const void*)':
audio/audio.cc:161: warning: converting to 'int' from 'float'
audio/audio.cc: In function 'int streamingSourceSort(const void*, const void*)':
audio/audio.cc:193: warning: converting to 'int' from 'float'
audio/audio.cc: In function 'AUDIOHANDLE alxCreateSource(const Audio::Description*, const char*, const MatrixF*, AudioSampleEnvironment*)':
audio/audio.cc:707: warning: converting to non-pointer type 'ALuint' from NULL
audio/audio.cc: In function 'ALuint alxGetWaveLen(ALuint)':
audio/audio.cc:2092: warning: converting to 'ALuint' from 'F64'
make[1]: *** [out.GCC3.DEBUG/audio/audio.obj] Error 1
make: *** [default] Error 2
[johnzo@schiff SDK]$ gcc -v
Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=i386-redhat-linux
Thread model: posix
gcc version 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)
[johnzo@schiff SDK]$ uname -a
Linux schiff.johnzo.com 2.6.10-1.770_FC3 #1 Thu Feb 24 14:00:06 EST 2005 i686 athlon i386 GNU/Linux
johnzo@schiff SDK]$ make -f mk/configure.mk COMPILER=GCC3 BUILD=DEBUG OS=LINUX
Current Configuration: this config is VALID
OS: LINUX
COMPILER: GCC3
BUILD: DEBUG
DIR.OBJ: out
To change the current configuration type:
make -f mk/configure.mk {arguments, ...}
required arguments:
OS={WIN32 BEOS LINUX OpenBSD FreeBSD Solaris}
COMPILER={CW6 VC6 GCC2 GCC3}
BUILD={DEBUG RELEASE}
optional arguments:
DIR.OBJ={path to store intermediate obj files}
Note: all arguments are case sensitive.
johnzo@schiff SDK]$ make
--> Compiling audio/audio.cc
In file included from ./audio/audioBuffer.h:16,
from ./audio/audioDataBlock.h:13,
from ./audio/audio.h:13,
from audio/audio.cc:6:
./core/resManager.h: In member function 'void Resource
./core/resManager.h:255: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h: In member function 'void Resource
./core/resManager.h:263: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h:265: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
./core/resManager.h: In member function 'void Resource
./core/resManager.h:278: error: invalid use of undefined type 'struct ResManager'
./core/resManager.h:38: error: forward declaration of 'struct ResManager'
audio/audio.cc: In function 'int loopingImageSort(const void*, const void*)':
audio/audio.cc:161: warning: converting to 'int' from 'float'
audio/audio.cc: In function 'int streamingSourceSort(const void*, const void*)':
audio/audio.cc:193: warning: converting to 'int' from 'float'
audio/audio.cc: In function 'AUDIOHANDLE alxCreateSource(const Audio::Description*, const char*, const MatrixF*, AudioSampleEnvironment*)':
audio/audio.cc:707: warning: converting to non-pointer type 'ALuint' from NULL
audio/audio.cc: In function 'ALuint alxGetWaveLen(ALuint)':
audio/audio.cc:2092: warning: converting to 'ALuint' from 'F64'
make[1]: *** [out.GCC3.DEBUG/audio/audio.obj] Error 1
make: *** [default] Error 2
About the author
Torque Owner Hans Sjunnesson
I managed to get the first version of T2D to compile under linux by downloading the HEAD of TGE SDK from CVS and manually transfering the changes that was put into HEAD into T2D. But for the second release (was that 1.0.2 or something?) I got other errors and stuff just didn't work. So I thought I'd wait until T2D got more merged with TGE HEAD.
As it stands right now, I'm unable to compile the newer version of T2D with my new GCC on Linux, and since I don't have a Linux executable, I'm working with the old version.