4

I'm working on porting my code over to Mac which compiles fine on my 64bit Windows machine. Apparently one of the libraries I am utilizing (Awesomium) isn't compiled to 64bit code, so I have to compile my code as a 32bit binary.

I'm getting an error when trying to compile 32bit binary with GCC 4.8.

In file included from /opt/local/include/gcc48/c++/random:50:0,
                 from /opt/local/include/gcc48/c++/bits/stl_algo.h:67,
                 from /opt/local/include/gcc48/c++/algorithm:63,
                 from /Library/Frameworks/SFML.framework/Headers/System/Utf.hpp:32,
                 from /Library/Frameworks/SFML.framework/Headers/System.hpp:43,
                 from /Library/Frameworks/SFML.framework/Headers/Window.hpp:32,
                 from /Users/ryan/projects/ArchaicEngine/ArchaicEngine/includes/ArchaicEngine/Graphics/RenderWindow.h:4,
                 from /Users/ryan/projects/ArchaicEngine/ArchaicEngine/src/Graphics/RenderWindow.cpp:1:
/opt/local/include/gcc48/c++/bits/random.h:106:26: error: expected unqualified-id before '__int128'
       { typedef unsigned __int128 type; };

Basically SFML includes <algorithm> which then includes <random> which uses __int128 which is unavailable to 32bit binaries. How can I get this to compile?

5
  • GCC's official statement on support is, basically, roll your own: gcc.gnu.org/onlinedocs/gcc/_005f_005fint128.html Commented Oct 30, 2012 at 22:35
  • Other solutions involve using some kind of bigint library... see stackoverflow.com/questions/1188939/… Commented Oct 30, 2012 at 22:36
  • Of course, you could also try to get Awesomium to build under 64-bit. Commented Oct 30, 2012 at 22:36
  • Ah okay. Looking back now, I was using 32bit SFML library ton windows. I'll just have to link to 32bit SFML on the mac and it should work. Commented Oct 30, 2012 at 23:15
  • A possible answer present at: __int128 error when compiling 32 bit Commented Apr 19, 2016 at 23:30

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.