News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

SMFL not working in Code::Blocks

Started by pwnedu46, July 30, 2011, 08:48:15 PM

Previous topic - Next topic

pwnedu46

When I get to the dialog box that says "Please select SMFL's location:," I enter it, and click next. Then, and error message titled "Script Error" appears that says "The path you entered seems valid, but this wizard can't locate the following SMFL's include file: Audio.hpp in it." When I opened the folder and went to
SMFL-1.6 > include > SMFL > Audio, the file is there.

Any help would be appreciated. I'm trying to move away from the console into GUIs, but this isn't helping.

[self-moved from Using Code::Blocks to this forum. I thought I was in this forum when I posted it.]

[attachment deleted by admin]

MortenMacFly

Quote from: pwnedu46 on July 30, 2011, 08:48:15 PM
Any help would be appreciated. I'm trying to move away from the console into GUIs, but this isn't helping.
SFML changes it's paths with every version it seems. You'll need to change the wizard accordingly. To do so, right-.click on the wizard and select "edit". Then change the following passages accordingly:

        if (dir_nomacro_inc.IsEmpty())
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Audio.hpp"), _T("SFML's include")))
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Config.hpp"), _T("SFML's include")))
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Graphics.hpp"), _T("SFML's include")))
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Network.hpp"), _T("SFML's include")))
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/System.hpp"), _T("SFML's include")))
            return false;
        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Window.hpp"), _T("SFML's include")))
            return false;

For example, change:

        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Audio.hpp"), _T("SFML's include")))
            return false;

...to:

        if (!VerifyFile(dir_nomacro_inc, _T("SFML/Audio/Audio.hpp"), _T("SFML's include")))
            return false;

...and so on.

I think such change won't make it into trunk, as this would break compatibility with older version. You could (however) do it better with an OR clause to support all path layouts. Patches are welcome.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]