User forums > Using Code::Blocks

Importing Dev-Cpp project files from wxDevCpp with wxpack

(1/1)

jfpjr:
I was having trouble importing DevCpp project and found that the Dev Project file from wxDevCpp with wxPack installed for gcc and vc has 2 profile sections. In this section is the lib and compiler option. These were not be read by the import routine in devcpploader.cpp. I had to add

 dev->SetPath(_T("/Profile1"));

before the line :
   
 dev->Read(_T("CppCompiler"), &tmp, _T(""));

in order to get the libs and other options. Not a full fix just quick one to get it working.

XP sp2
wxwidgets 2.8
Feb 3 svn

jfpjr:
A little update to prev comment,

I have added some checks so that it should not interfere with the original Dev-Cpp project files.

    m_pProject->SetTitle(title);

    //I added these lines to get compiler options
    //for wxDevCpp as it has 2 Profiles MingW and
    //Visual C++
    dev->Read(_T("ProfilesCount"), &tmp, _T(""));
    if (!tmp.IsEmpty())
    {
        dev->SetPath(_T("/Profile1"));
        dev->Read(_T("ProfileName"), &tmp, _T(""));
        if (!tmp.IsSameAs(_T("MingW 3.4.2")))
            dev->SetPath(_T("/Profile2"));
    }

    dev->Read(_T("CppCompiler"), &tmp, _T(""));

after loading you still have to set Compiler and linker paths.

stahta01:
I would suggest submitting this as a patch at Berlios.

http://wiki.codeblocks.org/index.php?title=Creating_a_patch_to_submit_to_BerliOS_%28Patch_Tracker%29

Tim S

Navigation

[0] Message Index

Go to full version