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

Example won't compile #76

Closed
LefterisJP opened this issue May 29, 2015 · 5 comments · Fixed by #77
Closed

Example won't compile #76

LefterisJP opened this issue May 29, 2015 · 5 comments · Fixed by #77
Assignees
Labels

Comments

@LefterisJP
Copy link

This is the error output I am getting

   Compiling getting-started-spinning-square v0.0.0 (file:///home/lefteris/w/rust_test)
src/main.rs:29:13: 29:18 error: the trait `graphics::graphics::Graphics` is not implemented for the type `opengl_graphics::back_end::GlGraphics` [E0277]
src/main.rs:29             clear(GREEN, gl);
                           ^~~~~
src/main.rs:36:13: 36:22 error: the trait `graphics::graphics::Graphics` is not implemented for the type `opengl_graphics::back_end::GlGraphics` [E0277]
src/main.rs:36             rectangle(RED, square, transform, gl);
                           ^~~~~~~~~
error: aborting due to 2 previous errors
Could not compile `getting-started-spinning-square`.

I am running ArchLinux with rust rustc 1.0.0-dev (built 2015-05-17)

Any ideas what's wrong?

@bvssvni bvssvni added the bug label May 29, 2015
@bvssvni bvssvni self-assigned this May 29, 2015
@bvssvni
Copy link
Member

bvssvni commented May 29, 2015

The dependencies are now on crates.io internally which causes this error. I'll update it.

bvssvni added a commit to bvssvni/Piston-Tutorials that referenced this issue May 29, 2015
@LefterisJP
Copy link
Author

Thank you, this does indeed address the issue

@xaviershay
Copy link

I'm getting this trying to run the tutorial with SDL2 using latest dependencies from crates.io:

 "piston 0.17.0 (registry+https://github.com/rust-lang/crates.io-index)",
 "piston2d-graphics 0.14.0 (registry+https://github.com/rust-lang/crates.io-index)",
 "piston2d-opengl_graphics 0.23.0 (registry+https://github.com/rust-lang/crates.io-index)",
 "piston_window 0.35.0 (registry+https://github.com/rust-lang/crates.io-index)",
 "pistoncore-sdl2_window 0.24.0 (registry+https://github.com/rust-lang/crates.io-index)",

Not sure if it's related, but error is the same. Going to keep poking at it.

@xaviershay
Copy link

Found it, released piston2d-opengl_graphics depends on 0.13 of piston2d-graphics: https://github.com/PistonDevelopers/opengl_graphics/blob/master/Cargo.toml#L36

Pinning to 0.13.0 in my Cargo.toml works around.

@xaviershay
Copy link

Relevant issue: PistonDevelopers/opengl_graphics#222

cvubrugier added a commit to cvubrugier/routine that referenced this issue Mar 5, 2016
This patch updates the dependencies to the latest versions except for
piston2d-graphics because piston2d-opengl_graphics still depends on
piston2d-graphics 0.13.x.

  PistonDevelopers/Piston-Tutorials#76

Signed-off-by: Christophe Vu-Brugier <cvubrugier@fastmail.fm>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants