User forums > Using Code::Blocks

wx/app.h: No such file or directory but app.h is in the included library

<< < (2/3) > >>

marinoernestoch:

--- Quote from: stahta01 on August 16, 2020, 03:15:47 pm ---Post the Build log!
http://wiki.codeblocks.org/index.php/FAQ-Compiling_(errors)#Q:_How_do_I_troubleshoot_a_compiler_problem.3F

--- End quote ---

I had given it a look earlier

Miguel Gimenez:
You must use:
   in Base: C:\Program Files\wxWidgets-3.1.4
   in Include: (blank)
   in Lib: (blank)

In Project Build Option Debug = $(#wx.lib)\gcc_lib\mswud
In Project Build Option Release = $(#wx.lib)\gcc_lib\mswu

This error


--- Code: ---gcc: error: Files\wxWidgets-3.1.4\lib\gcc_lib\mswud: No such file or directory
--- End code ---

is because of the space in "Program Files", you must change wxWidgets' location to a folder without spaces in the absolute path (or local characters like Ñ).

Please use code tags when posting logs.

marinoernestoch:
Sorry Miguel for the code tags.


--- Quote from: Miguel Gimenez on August 16, 2020, 04:41:23 pm ---You must use:
   in Base: C:\Program Files\wxWidgets-3.1.4
   in Include: (blank)
   in Lib: (blank)

In Project Build Option Debug = $(#wx.lib)\gcc_lib\mswud
In Project Build Option Release = $(#wx.lib)\gcc_lib\mswu


--- End quote ---

After editing it does not find wx/setup.h which is in the library C:\Program Files\wxWidgets-3.1.4\include\wx\msw.


--- Quote from: Miguel Gimenez on August 16, 2020, 04:41:23 pm ---is because of the space in "Program Files", you must change wxWidgets' location to a folder without spaces in the absolute path (or local characters like Ñ).

--- End quote ---
So do I have to reinstall xwWidgets?

Miguel Gimenez:

--- Quote ---After editing it does not find wx/setup.h
--- End quote ---

The compilation of wxWidgets creates a copy of setup.h under $(#wx.lib)/gcc_lib/mswu/wx and other under $(#wx.lib)/gcc_lib/mswud/wx, that's why these paths must be in the Compiler Search Directories (without the last /wx part).


--- Quote ---So do I have to reinstall xwWidgets?
--- End quote ---

No, just move the folder (for example to C:\Libraries\wxWidgets...) and change the wx global variable to reflect the new path.

marinoernestoch:
Good evening Miguel.
You've been of great help to me. :D
I made several tests.
Basically I only left $(#wx.include) in Global Compiler Settings both Search Directories Compiler and Resource Compiler. Instead in Project Build Option Debug and Project Build Option Release I left only $(#wx.lib)\gcc_lib\mswud and $(#wx.lib)\gcc_lib\mswu respectively.
(But I didn't understand the difference between  Compiler and Resouce compiler of Search directories in Global compiler setting).
With both C:\Program Files\wxWidgets-3.1.4 and C:\wxWidgets-3.1.4 I have overcome the problems I have found so far.

But now, for the modules defined in the debug link, I get: "" C:/Program Files/MinGW-w64/bin/../lib/gcc/x86_64-w64-mingw32/9.2.0/../ .. /../../x86_64-w64-mingw32/bin/ld.exe:skipping incompatibleC:\Program Files\ wxWidgets-3.1.4\lib\gcc_lib/libwxmsw31u.a when searching for -lwxmsw31u ""
Will it be a software level problem?
I know that Compiler / Linker errors are NOT Code :: Blocks errors.
But someone can direct me on the analysis of the problem.
Thank you

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version