kiss3d构建错误:类型Modifiers没有实现trait'core :: fmt :: Debug

时间:2015-07-29 12:59:08

标签: rust

我曾尝试在Windows 7下构建“kiss3d”(生锈1.0 32位,生锈夜间1.3 32位),但没有成功。有人成功吗?

我使用了以下Cargo.toml:  Cargo.toml (符合。:    gcc.exe cannot find -lglfw3 when using glfw-rs):

[package]
name    = "kiss3d"
version = "0.1.2"
authors = [ "SĂ©bastien Crozet <developer@crozet.re>" ]

description = "3D graphics engine for Rust."
repository = "https://github.com/sebcrozet/kiss3d"
readme = "README.md"
keywords = [ "3D", "graphics", "OpenGL", "KISS" ]
license = "BSD-3-Clause"

include = [
    "src/**/*.rs",
    "examples/**/*.rs",
    "examples/media",
    "examples/Cargo.toml",
    "Cargo.toml",
    "LICENSE",
    "Readme.md"
]
    [dependencies.glfw]
    git = "https://github.com/bjz/glfw-rs.git"
    default-features = false

   [lib]
    name = "kiss3d"
    path = "src/lib.rs"

   [dependencies]
    nalgebra = "*"
   gl = "*"
   time = "*"
   num = "*"
   libc = "*"
   ncollide_procedural = "*"
   freetype-rs = "*"
   image = "*"

但无济于事。

1 个答案:

答案 0 :(得分:0)

我发现什么对我有用(使用Win 7教授,每夜生锈1.4 32位版本):

1)我更改了./src目录中的lib.rs,添加以下行:        #![功能(libc中)      在行之前:       extern crate libc;

2)我在项目的根目录中创建了./bin/i686-pc-windows-gnu目录

3)在./bin/i686-pc-windows-gnu中我复制了以下文件:       freetype6.dll,glfw3.dll

4)改变了Cargo.toml:

 [package]
 name    = "kiss3d-examples"
version = "0.1.0"
authors = [ "SĂ©bastien Crozet <developer@crozet.re>" ]
[dependencies]
rand = "*"
nalgebra = "*"
gl = "*"
time = "*"
num = "*"
image = "*"
ncollide_procedural = "*"
ncollide_transformation = "*"
freetype-rs = "*"
[dependencies.glfw]
git = "https://github.com/bjz/glfw-rs.git"
default-features = false
 [lib]
 name = "kiss3d"
 path = "./src/lib.rs"

 [[bin]]
 name = "cube"
 path = "./cube.rs"

所以我能够:货运和立方体示例运行......