Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
361 views
in Technique[技术] by (71.8m points)

c++ - wxWidgets-2.9.4include and libgcc_libmswu No such file or directory error on CodeBlocks

I'm trying to learn C++ programming with wxWidgets and CodeBlocks (with MinGW) and earlier today I succeeded in installing the software (after some trouble) to my Windows 7 computer with the guidance given to me in this post:

wxWidget 2.8.12 not working in Codeblocks

Later on the same day, I did the exact same steps on another Windows 7 machine and after creating a wxWidgets project and trying to compile and run it I got the following errors:

wxWidgets-2.9.4include: No such file or directory
wxWidgets-2.9.4libgcc_libmswu: No such file or directory

I have checked and these folders really do exist on those locations...so what seems to be the problem here again?...on the earlier post user asanth kumar guided me that if the steps given in the guide don't get the job done, then I'm missing an important compiler search path in my build options.

Ok, so what do I do? Where do I enter the search path? What is the search path, etc. I'm very new with wxWidgets and CodeBlocks so I don't know very much terminology. If anyone should know what to do, could you please give me like step by step instruction what to do e.g. like Click Project --> Build options --> ... and so on

I have used the latest CodeBlocks (12.11) and wxWidgets (2.9.4) installers

Thank you for any help :)

UPDATE:

here is the build log: (I'm using CodeBlocks 12.11 and wxWidgets 2.9.4)

   -------------- Build: Debug in TEST (compiler: GNU GCC Compiler)---------------

windres.exe -I"C:UsersJonneOmat ohjelmatwxWidgets-2.9.4include" -I"C:UsersJonneOmat ohjelmatwxWidgets-2.9.4libgcc_libmswu"  -J rc -O coff -i C:UsersJonneDOCUME~1CODEBL~1TEST
esource.rc -o objDebug
esource.res
gcc: error: ohjelmatwxWidgets-2.9.4include: No such file or directory
gcc: error: ohjelmatwxWidgets-2.9.4libgcc_libmswu: No such file or directory
windres.exe: preprocessing failed.
Process terminated with status 1 (0 minutes, 0 seconds)
3 errors, 0 warnings (0 minutes, 0 seconds)

Here is also a picture where you can see Build options, global variables and build log on my CodeBlocks:

enter image description here

NOTICE FUTURE READERS: Install wxWidgets to a directory without whitespace in the path name. The problems in this post was because the directory path had spaces in it

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

When you create a wxWidgets project.Have you did this?

File->New->Project->wxWidgets Project->Click Go->Click on Next->click on the suitable wxWidgets 2...version->click Next->Give project Name->Click on Next->Click on Next

After that the Following below Screen comes in the Wizard. Give the wxWidgets Location(Path where You installed the wxWidgets 2.9.4)

Specifying the Location of wxWidgets in CodeBlocks in wxWidgets Project

Compiler configuration

library Settings

Mode of application

After that click on Finish.

  • For Environment Variable Path Setting

  • Follow the Below Steps:

    Right click on MyComputer->Click on Advanced Systems settings->click on Environment Variables->click on New->Give variable name=Path and variable value="C:Program Files (x86)CodeBlocksMinGWin" -> click ok

Environment Settings

`

  • Try The Following Steps.It will work.

Updates about Build settings:

COMPILER RESOURCE COMPILER LINKER


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...