BinaryData.cpp does not compile with Xcode 4.4.1


#1

Hello,

I am currently porting a former VS2010 Application (based on Juce) to Mac.
When I try to compile, Xcode shows tons of errors for the BinaryData.cpp file, that the Introjucer created for me:

../../JuceLibraryCode/BinaryData.cpp:2421:14: error: case value evaluates to 3787181599, which cannot be narrowed to type 'int' [-Wc++11-narrowing] case 0xe1bbce1f: numBytes = 795; return Logo_png;
The line is part of the huge switch-statement in GetNamedResource.

Visual c++ compiled this… What am I missing here?
StrangeMan


#2

Re-create the binary data file with the latest introjucer and it’ll sort that out.


#3

Oh, I thought, i already did that by re-saving the project. Well, thanks! I removed one of the files and added it again, and now it works fine.

Sorry for asking such a trivial question here…


#4

Uhhh, sorry I have to come back again.

I don’t know, why XCode stopped complaining about it, but after I fixed several other errors in my code, it came back to these, although i recreated the binary data files.
Now i was thinking my version of “the Introjucer” is outdated and downloaded the source from the website the compile the up-to-date version. When I try to compile it, it stops at exactly at the same binary data file.

whats going on there?


#5

It’s just a compiler warning in the latest llvm. I fixed the introjucer some time ago to generate code that avoids it, so you need to update.


#6

No, its not simply a warning. I attached a screenshot.

My Introjucer is Ver. 3.0.0, thats the one, that can be downloaded from the website. I can’t compile the sources myself, because they suffer from exactly the same problem with Xcode4.4.1. I deleted my BinaryData.cpp File and forced the Introjucer to recreate it. So that one is up-to-date, too.
What else, should I update?


#7

Like I said twice already, get the latest version. You’ll need to use GIT.