Re: Irrlicht Port

#261
It seems to not like the lib directories. Freetype needs to be repathed to freetype2/freetype/ (as opposed to just freetype/), and AL/al.h had to be changed to just al.h

Probably a config issue, but I'm not sure what I'm looking for.

EDIT: Added this, fixed path issues:

Code: Select all

<Add directory="FreeType/include/freetype2" />
Now getting this:

Code: Select all

directory\irrlicht-files\devenvironment\3dworld\player.cpp|16|error: 'to_string' is not a member of 'std'|
EDIT EDIT: Googled it, need GCC 4.8.0 or higher, currently running 4.7.4 which has the to_string bug. Can't DL it right now but I'll get back to work trying to compile this asap so I can write up a noob guide to compiling, and I'll see if I can help any way possible. It'll be a good way to learn C++ :)
SCP - Box of Horrors v0.8.0b
Twitter
Github Profile

Re: Irrlicht Port

#264
InnocentSam wrote:Googled it, need GCC 4.8.0 or higher, currently running 4.7.4 which has the to_string bug.
If you're developing on windows and you aren't using MSVC, I'd highly recommend getting Mingw-w64(Found here: http://mingw-w64.sourceforge.net/index.php); it's a much better port of GCC IMO.
It'll be a good way to learn C++ :)
The best way to learn how C/C++ compilation works is to drop the IDE for a few days to learn how g++ is actually invoked and how makefiles work.
SyphenTV wrote:It's a Piece of Coding. If I get the Password wrong, it still gives me the Option to delete my files, even though it shouldn't. XD
Pay attention to what sections of your program are affected by the if/else conditionals, your last assignment to 'name' isn't inside any condidional. Indent your code, it will make fixing your issue a lot easier. PM me if you have any other questions about programming in general.
M-x dingus-mode

Re: Irrlicht Port

#265
SyphenTV wrote:
Spoiler
Image
That hurts to read; use IDEal, it auto-indents :)
MonocleBios wrote:
InnocentSam wrote:Googled it, need GCC 4.8.0 or higher, currently running 4.7.4 which has the to_string bug.
If you're developing on windows and you aren't using MSVC, I'd highly recommend getting Mingw-w64(Found here: http://mingw-w64.sourceforge.net/index.php); it's a much better port of GCC IMO.
I am using Mingw-w64, but I'm using the version that uses 4.7.4 GCC. For some reason that was the main download I found from their page, despite it being outdated.
MonocleBios wrote:
It'll be a good way to learn C++ :)
The best way to learn how C/C++ compilation works is to drop the IDE for a few days to learn how g++ is actually invoked and how makefiles work.
Yes I will need to learn how compilation works otherwise in the proverbial programming hurdle race, I'll trip over when the gun is fired. I would however like to learn C++ the language as well, and this seems like a good opportunity to do so.
SCP - Box of Horrors v0.8.0b
Twitter
Github Profile

Re: Irrlicht Port

#266
MonocleBios wrote: Pay attention to what sections of your program are affected by the if/else conditionals, your last assignment to 'name' isn't inside any condidional. Indent your code, it will make fixing your issue a lot easier. PM me if you have any other questions about programming in general.

Hm. Okay. Thanks. I'll try it out after school today. I'l PM you if anything goes wrong. :D
InnocentSam wrote: That hurts to read; use IDEal, it auto-indents
hmm. Interesting. Thanks.

Re: Irrlicht Port

#267
InnocentSam wrote:EDIT EDIT: Googled it, need GCC 4.8.0 or higher, currently running 4.7.4 which has the to_string bug. Can't DL it right now but I'll get back to work trying to compile this asap so I can write up a noob guide to compiling, and I'll see if I can help any way possible. It'll be a good way to learn C++ :)
You could replace to_string with an ostringstream. It requires a few more lines of code but it works.

Re: Irrlicht Port

#268
juanjpro wrote:
InnocentSam wrote:EDIT EDIT: Googled it, need GCC 4.8.0 or higher, currently running 4.7.4 which has the to_string bug. Can't DL it right now but I'll get back to work trying to compile this asap so I can write up a noob guide to compiling, and I'll see if I can help any way possible. It'll be a good way to learn C++ :)
You could replace to_string with an ostringstream. It requires a few more lines of code but it works.
I'd prefer to keep your existing code as original as possible so that any additions are easier to copy over.
SCP - Box of Horrors v0.8.0b
Twitter
Github Profile

Re: Irrlicht Port

#269
InnocentSam wrote:I'd prefer to keep your existing code as original as possible so that any additions are easier to copy over.
You can use a combination of templates and preprocessor magic to use ostringstream without modifying the original code.

Code: Select all

#define GCC_VERSION (__GNUC__ * 10000           \
                     + __GNUC_MINOR__ * 100     \
                     + __GNUC_PATCHLEVEL__)

#if GCC_VERSION < 40800
    #define to_string(x) temp_to_string(x)
#endif

namespace std
{
    #include <sstream>
    template <typename T>
    string temp_to_string(T num)
    {
        ostringstream ss;
        ss << num;
        return ss.str();
    }
}
M-x dingus-mode

Re: Irrlicht Port

#270
Okay, so I updated my compiler to 4.9.0 but now I'm getting a lot of undefined references. They all start with either "_" or "__"

Example:

Code: Select all

obj\Debug\3dworld\3dworld.o:3dworld.cpp|| undefined reference to `__gxx_personality_sj0'|
obj\Debug\3dworld\3dworld.o:3dworld.cpp|| undefined reference to `_Unwind_SjLj_Register'|
Over 1300 errors before it just finally gives up. Tried googling it but everyone has different methods that they used to fix it, and many either don't apply to me or don't work. Thoughts?

EDIT: Strangely, I've got "version : MinGW-W64-builds-4.2.0" but also "args : --mode=gcc-4.9.0", in addition to a "C:\mingw\lib\gcc\x86_64-w64-mingw32\4.9.0" folder.
SCP - Box of Horrors v0.8.0b
Twitter
Github Profile