Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation #48

Closed
cridenour opened this issue Jan 17, 2018 · 7 comments
Closed

Documentation #48

cridenour opened this issue Jan 17, 2018 · 7 comments

Comments

@cridenour
Copy link
Contributor

First, thanks for a great library - I always like to model out simulations in Python and always dread having to translate that to another language.

I've tried a couple times with varying levels of success on 64-bit Linux to build the project working following the README.md and I'm not sure all the examples and tests are up to date for the latest GDNative file formats - which makes total sense since it's a moving target.

I'm thinking about taking a stab at updating the examples / README as a PR now that we're closer to 3.0 (and saw your latest PR was merged) but wanted to make sure I don't do work that's already in progress.

If you're already working on these things, no worries! And if there is anything else I can do to help, let me know.

@touilleMan
Copy link
Owner

Hi there !

Thanks for offering your help ;-)

I've tried a couple times with varying levels of success on 64-bit Linux to build the project working following the README.md

As you say the project is currently not really stabilized due to GDNative API being developed in the same time. However this is getting better since we've almost reached the final Godot 3.0.

Considering building for yourself the project I would recommend you to follow what's done on travis/appveyor (this way you get to know which Godot-python commit compile with which Godot commit). Obviously the final 3.0 would easier this a lot by providing a single gdnative wrapper archive containing both include headers and the static library for each architectures (comparing to now where we have to curl the godot's github build repo for a specific library version&architecture).

I'm thinking about taking a stab at updating the examples / README as a PR now that we're closer to 3.0 (and saw your latest PR was merged) but wanted to make sure I don't do work that's already in progress.

I'm not working on documentation (most of my time on the project right now is dedicated to suffer on the windows version...) so I'll be really happy if you start working on this part.

Considering the tests&examples folders. The tests/bindings is the only project I'm running really frequently so I'm sure it is up to date. Then I'm trying to keep examples/pong up to date. Then there is the others which I planned to update once the library is stabilized, so you can work on them if you want ;-)

@cridenour
Copy link
Contributor Author

Great! The travis file was a definite help on the new build system. Using the released pegged in the SConstruct got everything to build nice and easy!

That said, running

scons platform=x11-64 test

builds everything fine, but errors out with

ERROR: open_dynamic_library: Method/Function Failed, returning ERR_CANT_OPEN

Any ideas?

--

P.S. My overall plan is to get build instructions as part of the README.md from a clean Ubuntu docker container. Then do the same for Windows once you are free from that hell!

@touilleMan
Copy link
Owner

My guess is either Godot cannot find libpythonscript.so (so you should check the symlinks and the pythonscript.gdnlib in the project) or libpython3.so cannot be loaded here:

// Make sure the shared library has all it symbols loaded
// (strange bug with libpython3.6 otherwise...)
{
const wchar_t *wpath = godot_string_wide_str(options->active_library_path);
char path[300];
wcstombs(path, wpath, 300);
dlopen(path, RTLD_NOW | RTLD_GLOBAL);

You should put a breakpoint there to find that out (and check if you got information about pythonscript loading in Godot output log)

@cridenour
Copy link
Contributor Author

Ah, looks like another moving target issue.

Error: tests/bindings/pythonscript/libpythonscript.so: undefined symbol: godot_char_string_destroy

I'll play around with later builds.

@cridenour
Copy link
Contributor Author

Have both tests and example working again with the 20180113-2 build on my branch here. Will start on some of the docs this weekend!

@touilleMan
Copy link
Owner

Error: tests/bindings/pythonscript/libpythonscript.so: undefined symbol: godot_char_string_destroy

godot_char_string_* has been added very recently to Godot main codebase. You must be using an old version... (the patch is from 2018-01-10, not even sure it is in rc1)

@touilleMan
Copy link
Owner

Closing the issue now that #49 have been merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants