[SOLVED] Resource files must have the same version number

CodeLite installation/troubleshooting forum
nezos
CodeLite Veteran
Posts: 59
Joined: Wed Dec 31, 2014 6:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

[SOLVED] Resource files must have the same version number

Post by nezos »

Hi, after i upgraded to version 8 i get this error message when i launch my program:

Resource files must have same version number.

It is a program written in C++ and uses wxWidgets. Any idea what to look for?

---------------------------------------------------------------------------
Check last message for solution.
Last edited by nezos on Sun Jul 26, 2015 1:00 am, edited 2 times in total.
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by eranif »

Do you use XRC in your program?
If so, remove the version number form the XRC files

Eran
Make sure you have read the HOW TO POST thread
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by eranif »

BTW, usually these warnings are harmless (I got some of them in CodeLite itself, in the 'Trace' tab)
Building in release mode will make them go away.

Can you capture some of them in debug mode? and show the backtrace here?
They are probably generated by wxCrafter (the XRC files) and then converted into C++.

Eran
Make sure you have read the HOW TO POST thread
nezos
CodeLite Veteran
Posts: 59
Joined: Wed Dec 31, 2014 6:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by nezos »

I found seven .xrc files in the project's folder, remove the version (some had it some didn't) but the message still appears. Any other ideas?
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by eranif »

nezos wrote:I found seven .xrc files in the project's folder, remove the version (some had it some didn't) but the message still appears. Any other ideas?
The backtrace ?
It might give me a hint if it is embedded in the code by wxCrafter

Eran
Make sure you have read the HOW TO POST thread
nezos
CodeLite Veteran
Posts: 59
Joined: Wed Dec 31, 2014 6:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by nezos »

How do i get the backtrace?
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by eranif »

run your program under gdb.
once the assertion hits, get the backtrace from gdb

Eran
Make sure you have read the HOW TO POST thread
nezos
CodeLite Veteran
Posts: 59
Joined: Wed Dec 31, 2014 6:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by nezos »

Hi Eran, nothing noteworthy appears on gdb logs, but i bumped on a post saying that:

"I was getting "Resource files must have same version number!" errors with one of my dialogues. It turns out it was saved by an older version of DialogBlocks and didn't contain a version number. After re-generating the file, things
worked."

This was an old post for 2.5 version. Is there a chance that i really need to add the version? And what version do you think would be correct?

Found also code in GitHub referring to this message. It has to do with wxWidgets but i am not sure what version it expects.

https://github.com/wxWidgets/wxWidgets/ ... xmlres.cpp
nezos
CodeLite Veteran
Posts: 59
Joined: Wed Dec 31, 2014 6:36 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Resource files must have the same version number

Post by nezos »

Although i added to my xrc files version="2.5.3.0" it didn't change anything, i still get the message.

I then checked in Codelite by opening one by one my wxcp files and the version was 2.3.0.1 . I changed all the xrc files to this version, still nothing.

The http://docs.wxwidgets.org/trunk/overview_xrcformat.html specification for XRC says that it is optional to define a version, but it seems somehow that it is being checked. Why does the runtime code check the version ???
DavidGH
CodeLite Plugin
Posts: 819
Joined: Wed Sep 03, 2008 7:26 pm
Contact:

Re: Resource files must have the same version number

Post by DavidGH »

Hi,

I just tried an old xrc project, created long before CL 8.0, in the current CL using wx3.0.2. It ran fine. FWIW the xrc version was 2.3.0.1.

Try using the New Project wizard to create a new 'Executable (wxWidgets + XRC frame)' project. Do you have the same problem there?

Otherwise, as Eran said, please post the backtrace (not the log) you get if you Pause the debugger when the error message fires. You can copy it from the 'Call Stack' pane of the Debugger View.

Regards,

David
Post Reply