GCC-3.3 requirement FIXED PROPERLY NOW!

Archives Forums/Linux Discussion/GCC-3.3 requirement FIXED PROPERLY NOW!

TrickyRic(Posted 2008) [#1]
I posted a while ago my walkthrough for getting BlitzMAX running on AMD64, t least for Gentoo GNU/Linux.

http://blitzbasic.com/Community/posts.php?topic=72867

Well my modem died the other week and with little else to do, I got back into game development. I wanted to get the MiniB3D modules going but the well known GCC-3.3 errors popped up once again, so I got looking in the source and came up with a surprisingly simple fix. No need for the often glitchy symlink work-around, here's a proper hack.

Open the src/bmk/bmk_uhl.bmx file up from your BlitzMAX installation tree. In this file there's a reference for Linux, "gcc-3.3 -static". Change this reference to "gcc -static" and, assuming the location of your gcc is in your $PATH, which it should be, this should simply link to the currently selected version your system is using. Save the file and now open bmk.bmx from the same directory, into BlitzMAX. Click to build this file and it should rebuild your bmk binary with the edited source. Once built, move the binary over to the bin directory, replacing the bmk executable already there. Restart BlitzMAX and just for good measure, hit ctrl+D to rebuild all libraries.

If the above works, there shouldn't be any need for the symlink any more :-). Whats more, MiniB3D seems to work perfectly on AMD64, though I did follow the included ReadMe to disable C++ support too.

If a moderator could please sticky this I'm sure it will be useful to others. I'd also appreciate if my previous Gentoo AMD64 guide (Above link) could be added to the installation guides sticky too.

Thanks.


Picklesworth(Posted 2008) [#2]
:O

Damn, I yearn for the day that shared libraries magically stop needing version numbers. Just imagine how many problems it would avoid us!

edit:

No dice with that exact fix in Ubuntu 7.10 :(
Linking:bmk
/usr/bin/ld: skipping incompatible /usr/lib/gcc-lib/x86_64-linux-gnu/3.3.6/./libstdc++.so when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc-lib/x86_64-linux-gnu/3.3.6/./libstdc++.a when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc-lib/x86_64-linux-gnu/3.3.6/libstdc++.so when searching for -lstdc++
/usr/bin/ld: skipping incompatible /usr/lib/gcc-lib/x86_64-linux-gnu/3.3.6/libstdc++.a when searching for -lstdc++
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
Build Error: Failed to link /home/dmccall/Software/BlitzMax/src/bmk/bmk
Process complete


I'll keep fiddling.


skidracer(Posted 2008) [#3]
just replace the reference to g++-3.3 in the same file else you will lose your audio


skidracer(Posted 2008) [#4]
For compatability testing I would very much like to host prebuilt linux binaries of games in the MaxGames googlecode repository:

svn checkout http://maxgames.googlecode.com/svn/trunk/ maxgames-read-only

If someone want to email me working prebuilt gcc4 versions of Mark Incitti's classic VectorTube and VectorZone I'll add them to the downloads section.