Getting TGE 1.4 to compile under Linux on AMD64 Box
by Kuju Manila · in Technical Issues · 09/20/2006 (12:19 am) · 13 replies
Hello.
Can anyone please help me figure out on how to compile TGE 1.4 on my AMD64 boxes? To simplify the matter, here is a summary of what I have and have done so far:
-=My Machine=-
- AMD Athlon64 Dual Core x2 4200+ (Opteron)
- 1GB PC533 DDR2
- Gainward GF6800GS Bliss 512MB 256BIT
- MSI K8N NEO4 Platinum PCI-E/7.1/SATA/F
-=My Linux Distro and other Linux Stuff=-
Gentoo 2.6.17-r8 x86_64
GCC 3.4.4
-=What I have tried so far=-
1) Tried to modify conf.UNIX.mk to get rid of the -mcpu deprecation and changed my -march to k8. No go.
2) http://www.garagegames.com/mg/forums/result.thread.php?qt=18420 Here, I tried their patch (from the wiki site) but it didn't patch successfully since obviously it's for TGE 1.3 but I analyzed their patch and applied their modifications to my conf.UNIX.mk file. It compiled most of the files but it stopped on an error on x86UNIXCPUInfo but fixed using this http://www.garagegames.com/mg/forums/result.thread.php?qt=23104
3) Now compiling again, would make it stop on x86UNIXFont saying that FT_something is not declared. I googled it and found a fix just by installing freetype. However, compiling again would now reach me to this point:
I checked platformX86UNIX/x86UNIXFont.h and I'm pretty sure it wasn't there? Is there really such thing on your TGE? Or is it I'm just missing any linux libraries.
Can anyone please help me figure out on how to compile TGE 1.4 on my AMD64 boxes? To simplify the matter, here is a summary of what I have and have done so far:
-=My Machine=-
- AMD Athlon64 Dual Core x2 4200+ (Opteron)
- 1GB PC533 DDR2
- Gainward GF6800GS Bliss 512MB 256BIT
- MSI K8N NEO4 Platinum PCI-E/7.1/SATA/F
-=My Linux Distro and other Linux Stuff=-
Gentoo 2.6.17-r8 x86_64
GCC 3.4.4
-=What I have tried so far=-
1) Tried to modify conf.UNIX.mk to get rid of the -mcpu deprecation and changed my -march to k8. No go.
2) http://www.garagegames.com/mg/forums/result.thread.php?qt=18420 Here, I tried their patch (from the wiki site) but it didn't patch successfully since obviously it's for TGE 1.3 but I analyzed their patch and applied their modifications to my conf.UNIX.mk file. It compiled most of the files but it stopped on an error on x86UNIXCPUInfo but fixed using this http://www.garagegames.com/mg/forums/result.thread.php?qt=23104
3) Now compiling again, would make it stop on x86UNIXFont saying that FT_something is not declared. I googled it and found a fix just by installing freetype. However, compiling again would now reach me to this point:
Quote:
platformX86UNIX/x86UNIXFont.cc:25:41: platformX86UNIX/x86UNIXFont.h: No such file or directory
platformX86UNIX/x86UNIXFont.cc: In function 'PlatformFont* createPlatformFont(const char*, U32, U32)':
platformX86UNIX/x86UNIXFont.cc:358: error: 'x86UNIXFont' has not been declared
platformX86UNIX/x86UNIXFont.cc: At global scope:
platformX86UNIX/x86UNIXFont.cc:376: error: 'x86UNIXFont' has not been declared
platformX86UNIX/x86UNIXFont.cc:378: error: ISO C++ forbids declaration of 'x86UNIXFont' with no type
platformX86UNIX/x86UNIXFont.cc:382: error: expected constructor, destructor, or type conversion before '::' token
platformX86UNIX/x86UNIXFont.cc:382: error: expected ',' or ';' before '::' token
platformX86UNIX/x86UNIXFont.cc:390: error: 'x86UNIXFont' is not a class or namespace
platformX86UNIX/x86UNIXFont.cc: In function 'bool create(const char*, U32, U32)':
platformX86UNIX/x86UNIXFont.cc:424: error: 'baseline' undeclared (first use this function)
platformX86UNIX/x86UNIXFont.cc:424: error: (Each undeclared identifier is reported only once for each function it appears in.)
platformX86UNIX/x86UNIXFont.cc:426: error: 'height' undeclared (first use this function)
platformX86UNIX/x86UNIXFont.cc:428: error: 'mFontName' undeclared (first use this function)
platformX86UNIX/x86UNIXFont.cc: At global scope:
platformX86UNIX/x86UNIXFont.cc:444: error: 'x86UNIXFont' is not a class or namespace
platformX86UNIX/x86UNIXFont.cc:446: error: non-member function 'bool isValidChar(UTF16)' cannot have 'const' method qualifier
platformX86UNIX/x86UNIXFont.cc:464: error: 'x86UNIXFont' is not a class or namespace
platformX86UNIX/x86UNIXFont.cc:466: error: non-member function 'bool isValidChar(const UTF8*)' cannot have 'const' method qualifier
platformX86UNIX/x86UNIXFont.cc:476: error: 'x86UNIXFont' is not a class or namespace
platformX86UNIX/x86UNIXFont.cc:478: error: non-member function 'PlatformFont::CharInfo& getCharInfo(UTF16)' cannot have 'const' method qualifier
platformX86UNIX/x86UNIXFont.cc: In function 'PlatformFont::CharInfo& getCharInfo(UTF16)':
platformX86UNIX/x86UNIXFont.cc:500: error: 'mFontName' undeclared (first use this function)
platformX86UNIX/x86UNIXFont.cc: At global scope:
platformX86UNIX/x86UNIXFont.cc:659: error: 'x86UNIXFont' is not a class or namespace
platformX86UNIX/x86UNIXFont.cc:661: error: non-member function 'PlatformFont::CharInfo& getCharInfo(const UTF8*)' cannot have 'const' method qualifier
platformX86UNIX/x86UNIXFont.cc:666:1: warning: no newline at end of file
make[1]: *** [out.GCC3.DEBUG/platformX86UNIX/x86UNIXFont.obj] Error 1
make: *** [default] Error 2
I checked platformX86UNIX/x86UNIXFont.h and I'm pretty sure it wasn't there? Is there really such thing on your TGE? Or is it I'm just missing any linux libraries.
#2
The first error is the one to attend:
That file is MIA...
www.garagegames.com/mg/forums/result.thread.php?qt=35922
09/20/2006 (4:16 am)
This probably should go in the private SDK forums instead of here...The first error is the one to attend:
platformX86UNIX/x86UNIXFont.cc:25:41: platformX86UNIX/x86UNIXFont.h: No such file or directory
That file is MIA...
www.garagegames.com/mg/forums/result.thread.php?qt=35922
#3
09/21/2006 (12:23 am)
Don't mix 1.3 and 1.4 platform files. 64 bit doesn't work and won't for a while. Compile for 32 bit.
#4
Just to be sure I did
#make clean
According to my GCC, it's 4.1 so, I set OS=LINUX COMPILER=GCC4 BUILD=DEBUG
#make -f mk/configure.mk OS=LINUX COMPILER=GCC4 BUILD=DEBUG
Now, I get the error:
--> Compiling collision/convexBrush.cc
In file included from ./math/mathTypes.h:10,
from ./math/mMath.h:38,
from ./collision/abstractPolyList.h:10,
from ./collision/convexBrush.h:9,
from collision/convexBrush.cc:1:
./console/dynamicTypes.h:123:7: warning: no newline at end of file
./collision/optimizedPolyList.h:37: error: extra qualification 'OptimizedPolyList::Poly::' on member 'Poly'
make[1]: *** [out.GCC4.DEBUG/collision/convexBrush.obj] Error 1
make: *** [default] Error 2
What should I do?
09/21/2006 (1:01 am)
Ok, I got torque from the CVS, I also have this other machine with exact same specs above, except it uses SUSE 10.1 32bit x86 edition.Just to be sure I did
#make clean
According to my GCC, it's 4.1 so, I set OS=LINUX COMPILER=GCC4 BUILD=DEBUG
#make -f mk/configure.mk OS=LINUX COMPILER=GCC4 BUILD=DEBUG
Now, I get the error:
--> Compiling collision/convexBrush.cc
In file included from ./math/mathTypes.h:10,
from ./math/mMath.h:38,
from ./collision/abstractPolyList.h:10,
from ./collision/convexBrush.h:9,
from collision/convexBrush.cc:1:
./console/dynamicTypes.h:123:7: warning: no newline at end of file
./collision/optimizedPolyList.h:37: error: extra qualification 'OptimizedPolyList::Poly::' on member 'Poly'
make[1]: *** [out.GCC4.DEBUG/collision/convexBrush.obj] Error 1
make: *** [default] Error 2
What should I do?
#6
My status so far:
After a few compiles here and there, the new error that came up is from x86UNIXFileio.cc, which says in line 1189, the Game object is not a local member. I remarked that small checking code chunk and compiled. Now, I arrived to an error
I am using SuSE 10.1 and according to YaST2 I already have ogg, vorbis, and theora.
09/21/2006 (6:24 pm)
Tony, and David, thanks for the straightforward replies so far. It's been very helpful.My status so far:
After a few compiles here and there, the new error that came up is from x86UNIXFileio.cc, which says in line 1189, the Game object is not a local member. I remarked that small checking code chunk and compiled. Now, I arrived to an error
Quote:
--> Compiling platformX86UNIX/x86UNIXUtils.cc
make[1]: ../lib/xiph/linux/checklinks.sh: Command not found
make[1]: *** [out.GCC4.DEBUG/torqueDemo_DEBUG.bin] Error 127
make: *** [default] Error 2
I am using SuSE 10.1 and according to YaST2 I already have ogg, vorbis, and theora.
#7
09/21/2006 (10:10 pm)
One major thing that you are going to run into if you are trying to truly compile Torque with 64 bit libraries (it's hard to tell if you simply want to be able to compile on a 64 bit machine using 32 bit libs, or actually produce a 64 bit based executable) is that there is some assembly language code that will also need to be re-written. The problem is, as of my last research (which I admit is almost a year ago now), there were no publically available 64 bit versions of nasm, which made it difficult to re-implement this section of the code unless you had access to a private version of one.
#8
Like for instance, I have this weird error I can't overcome:
I discovered that the checklinks.sh file is in Torque_folder/lib/xiph/linux/ directory but it keeps on saying command not found. I even tried editing CHECK_LINK_FILE from engine/targets.torque.mk and the LINKS.LIBS.VORBIS from mk/conf.UNIX.mk and still Command not found error but it's there and there are permissions are already set too!
I am really getting disappointed that I used my money on this engine that's so advertised very well just finding out that problems are hidden within private sdk forums. For god's sake, it won't even compile "out of the box." I do admit that it mostly favors Windows but it didn't say that it has problems with Linux at all.
09/21/2006 (10:57 pm)
I actually am using a full 32bit Linux environment and libraries now (as I have described my new setup on the 4th post above this one. I just seem to have problems compiling this 32bit version of Torque where some few people are successful in doing.Like for instance, I have this weird error I can't overcome:
Quote:
--> Compiling platformX86UNIX/x86UNIXUtils.cc
make[1]: ../lib/xiph/linux/checklinks.sh: Command not found
make[1]: *** [out.GCC4.DEBUG/torqueDemo_DEBUG.bin] Error 127
make: *** [default] Error 2
I discovered that the checklinks.sh file is in Torque_folder/lib/xiph/linux/ directory but it keeps on saying command not found. I even tried editing CHECK_LINK_FILE from engine/targets.torque.mk and the LINKS.LIBS.VORBIS from mk/conf.UNIX.mk and still Command not found error but it's there and there are permissions are already set too!
I am really getting disappointed that I used my money on this engine that's so advertised very well just finding out that problems are hidden within private sdk forums. For god's sake, it won't even compile "out of the box." I do admit that it mostly favors Windows but it didn't say that it has problems with Linux at all.
#9
I'm guessing here that you don't have checklinks.sh flagged as an executable. Just take it out if that's not the case.
Garagegames doesn't support linux, they haven't for a while. It's a purely community supported effort and we've got mailing lists for stuff like this.
09/21/2006 (11:22 pm)
>make[1]: ../lib/xiph/linux/checklinks.sh: Command not foundI'm guessing here that you don't have checklinks.sh flagged as an executable. Just take it out if that's not the case.
Garagegames doesn't support linux, they haven't for a while. It's a purely community supported effort and we've got mailing lists for stuff like this.
#10
09/22/2006 (9:40 am)
Move this subject to private forums.
#11
10/11/2006 (8:06 am)
Where are the private forums? I can't compile the CVS version on linux (centos 4.3).
#13
NASM has been updated to support the full x86-64 architecture extension, and is fully supported since NASM 2.00.
03/22/2009 (10:02 am)
@Stephen, looks like NASM v2.x provides support for 64 bit architectures, from their website:NASM has been updated to support the full x86-64 architecture extension, and is fully supported since NASM 2.00.
Kuju Manila
Default Studio Name
4) Still stuck at #3 I tried the 32bit on 64bit approach, which I emerged emul-linux* libraries and modified the
.mk to use the gcc32 and g++32 compilers. Still, no go.
As I have seen in the forum threads above, this issue has been around since 2004. I should expect that by now there's a solid solution to this. Can anyone please help me? I would appreciate it also if someone would provide steps using command line as I am just new to linux.