Project Generator 0.9.0 Import Issues

Thank you all so much for 0.9.0. I’m looking forward to using it.

In porting a project to 0.9.0, i attempted to use the new Project Generator’s Import function. Initially, i just copied the project folder from 0.8.4 into the new 0.9.0 directory and tried to compile. I got identical errors: invalid deployment target for -stdlib=libc++ (requires OS X 10.7 or later) for both ofApp.cpp files and for addon files, including several ofxGui.

I then attempted to use the Project Generator’s Import function. Selecting the project directory, including the correct addons (some had not been added to addons.make) and updating. When i tried to compile, I ran into the same errors as before.

I then used the project generator to create a new project, copied the old /src files over and it worked perfectly.

xcode 6.4
osx 10.10.3

I’m sure I missed some info. Let me know what else you need. Thanks!

I just tested updating a 0.8.4 project for 0.9.0 and although I had to clean it, it built fine.

I haven’t seen this behavior, if you have a 0.8.4 project that doesn’t update properly, can you upload it and I’ll take a look ?


(I have noticed that it helped to delete the .app file itself – I’m getting some rsync errors if the old .app in the bin folder is still there on an 0.8.4 project updated to 0.9.0 … but beyond that not seeing errors compiling older code updated to 0.9.0…)

Thanks for this. Unfortunately, I’m working in someone’s private repo and not allowed to upload the whole project. I will give it a shot with another project and see if I get similar errors.

sure! for sure cleaning helps (but it means you recompile OF). In my experience just deleting the .app is enough, so I’ve been skipping cleaning for now. Apparently there’s some sort of issue with older .apps in the bin folder and 0.9.0 projects…

FWIW… i ran into the same issue with the ofxTessellationShader example. I imported/outputed with PG, cleaned and deleted app. It worked. Thanks for this.

When I updated to 0.9.0 (from a nightly build) I ran the updater in order to add an addon.

This removed the Build Phase to copy the data folder into *.app/Content/Resources

I think its a bug in the project updater but I didn’t have time to confirm this. Just listing my suspicion here.

I certainly didn’t change anything about the xcode project myself, and it was closed when I ran Project generator.

To explain how the PG works – the project generator “update” function looks at the addons.make (to figure out what addons to add) and the src folder, but it basically replaces your project file with a new file based on a template, which is why other settings you’ve made are getting lost. I think down the line to help in cases like yours, we can look at how to add specific “per project” info similar to the addons.make file, so that customizations wont get lost on an update.

one of the bigger issues generally is that generally on OSX the xcproj file is realy hard to parse in a cross platform way. There are good osx specific tools if you just want to add an addon to a project (ie which will not overwrite your xcodeproj file.

Project.xcconfig is great, a nice simple text file. I would prefer to use that most of the time where possible.
Could PG put the addons paths there ? That’s much easier to manipulate. (and git shows the file as changed)

I’ve used ofxCodeMenu in XCode before, it worked great.

I’m still a bit confused about what addons.make does. I thought I read that its used only if you are doing Makefile builds, but not XCode.

there’s a lot of parts to an addon – src files, libs to link against, include paths, etc – I think it’s not possible to do that all the xconfig file – some things could be done there, but it gets tricky with addons that involve frameworks, or other non traditional things. Also, many people may be used to dragging and dropping in addons in xcode, we prefer to show files in the sidebar…

addons.make is a list of the addons a project uses. PG and make both use this. Think about is as metadata that the PG can read/write and that make reads.

all that said – the pg repo is here:

feel free to file issues, PRs, etc.

1 Like