Not logged inGosu Forums
Forum back to libgosu.org Help Search Register Login
Up Topic Gosu / Extending Gosu / Gosu development documentation?
- - By spajus Date 2014-07-13 03:02
Is there any documentation available that would walk through setting up the development environment, building the project from source, running tests, etc., so it would be easier to start contributing to Gosu? There are issues with help-wanted label: (https://github.com/jlnr/gosu/issues?labels=help-wanted), but no info about how to build everything. For instance, this is what I get when I try to compile it intuitively using provided Rake tasks (on Mac):


➜  gosu git:(master) ✗ rake compile
cd tmp/universal.x86_64-darwin13/gosu/2.0.0
make
compiling ../../../../ext/gosu/gosu_wrap.cxx
../../../../ext/gosu/gosu_wrap.cxx:2181:10: fatal error: 'Gosu/Gosu.hpp' file not found
#include <Gosu/Gosu.hpp>
         ^
1 error generated.
make: *** [gosu_wrap.o] Error 1
rake aborted!
Command failed with status (2): [make...]
/Library/Ruby/Gems/2.0.0/gems/rake-compiler-0.9.2/lib/rake/extensiontask.rb:152:in block (2 levels) in define_compile_tasks'
/Library/Ruby/Gems/2.0.0/gems/rake-compiler-0.9.2/lib/rake/extensiontask.rb:151:in
block in define_compile_tasks'
Tasks: TOP => compile => compile:universal.x86_64-darwin13 => compile:gosu:universal.x86_64-darwin13 => copy:gosu:universal.x86_64-darwin13:2.0.0 => tmp/universal.x86_64-darwin13/gosu/2.0.0/gosu.bundle
(See full trace by running task with --trace)
Parent - - By jlnr (dev) Date 2014-07-13 10:24 Edited 2014-07-13 10:37
Not yet, but making Gosu easier to hack is definitely a priority! Thanks for checking out the github labels. The plan is to add a hacking guide & a front page link to both the guide, and the help-wanted tickets soon.

For testing things in Ruby, I usually do something like this:

export GOSU_RELEASE_VERSION=0.8.0.pre7 # or whatever version you want to use for testing
rake gem && sudo gem install pkg/gosu-$GOSU_RELEASE_VERSION.gem && ruby my_test_script.rb


If you are changing Gosu's Ruby interface, you also have to run rake swig in-between, to regenerate the Ruby wrapper from gosu.swg.

And then I just use the up-arrow to repeat the last step. This takes like a minute though, so for faster, C++-based development, I always keep an Xcode project of the Tutorial game around that includes the Gosu source files as well. Xcode is smart enough only to recompile the files that have actually changed, which brings the feedback loop down to a second. But for that I don't know the instructions off the top of my head. =/
Parent - By spajus Date 2014-07-13 12:39
Thanks, this was helpful, I was able to build it!
Up Topic Gosu / Extending Gosu / Gosu development documentation?

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill