Git Product home page Git Product logo

ogc-rs's Introduction

ogc-rs

Crates.io

A Rust wrapper library for devkitPro's libogc.

To get started, you'll first need to install the following dependencies on your system:

Then you'll need to fork this repo and git clone your fork into your local machine.

When that's done, do the following:

$ cd ogc-rs
$ rustup override set nightly
$ rustup component add rust-src
$ cargo check

If everything's working properly, cargo check should run successfully.

See the Wii testing project for an example on how to use this library.

Structure

This repository is organized as follows:

  • ogc-rs: Safe, idiomatic wrapper around ogc-sys.
  • ogc-sys: Low-level, unsafe bindings to libogc.

License

See LICENSE for more details.

ogc-rs's People

Contributors

1011x avatar antoineok avatar daxorinator avatar fenrirwolf avatar frictionlessportals avatar knarkzel avatar lucvandenbrand avatar profelements avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ogc-rs's Issues

Cannot compile the exemple

Hello, I get some problem when compiling the example (template) and i get a lot of error while compiling the template example due to a lot of errors. The error is always the same, but for differents lib.

The whole log:
https://hastebin.com/share/ruyuzulexa.wasm

The command used:
cargo +nightly build -Zbuild-std=core,alloc --target powerpc-unknown-eabi.json

the error (which stays the same):

= note: /opt/devkitpro/devkitPPC/powerpc-eabi/bin/ld: unrecognised emulation mode: elf_x86_64
Supported emulations: elf32ppc elf32ppclinux elf32ppcsim elf32lppc elf32lppclinux elf32lppcsim elf64ppc elf64lppc
collect2: error: ld returned 1 exit status

Cannot build due to ffi functions not found

I tried to build examples by using the command line in the readme (there is also an typo in the readme of both example, it's -Zbuild-std and not +Zbuild-std) But ogc-rs get three errors due to functions not found (error E0425), here is the logs

> cargo +nightly build -Zbuild-std=core,alloc --target powerpc-unknown-eabi.json
   Compiling compiler_builtins v0.1.92
   Compiling core v0.0.0 (/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
   Compiling libc v0.2.126
   Compiling memchr v2.5.0
   Compiling proc-macro2 v1.0.40
   Compiling quote v1.0.20
   Compiling unicode-ident v1.0.1
   Compiling autocfg v1.1.0
   Compiling cfg-if v1.0.0
   Compiling glob v0.3.0
   Compiling log v0.4.17
   Compiling minimal-lexical v0.2.1
   Compiling os_str_bytes v6.1.0
   Compiling hashbrown v0.12.2
   Compiling termcolor v1.1.3
   Compiling regex-syntax v0.6.27
   Compiling clap_lex v0.2.4
   Compiling libloading v0.7.3
   Compiling indexmap v1.9.1
   Compiling humantime v2.1.0
   Compiling either v1.7.0
   Compiling clang-sys v1.3.3
   Compiling bitflags v1.3.2
   Compiling bindgen v0.60.1
   Compiling textwrap v0.15.0
   Compiling strsim v0.10.0
   Compiling peeking_take_while v0.1.2
   Compiling lazy_static v1.4.0
   Compiling rustc-hash v1.1.0
   Compiling aho-corasick v0.7.18
   Compiling nom v7.1.1
   Compiling atty v0.2.14
   Compiling which v4.2.5
   Compiling syn v1.0.98
   Compiling lazycell v1.3.0
   Compiling shlex v1.1.0
   Compiling clap v3.2.10
   Compiling libm v0.2.2
   Compiling regex v1.6.0
   Compiling cexpr v0.6.0
   Compiling env_logger v0.9.0
   Compiling num_enum_derive v0.5.7
   Compiling ogc-sys v0.1.1 (/home/antoineok/ogc-rs/ogc-sys)
   Compiling rustc-std-workspace-core v1.99.0 (/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
   Compiling alloc v0.0.0 (/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
   Compiling cty v0.2.2
   Compiling num_enum v0.5.7
   Compiling voladdress v1.2.2
   Compiling bit_field v0.10.1
   Compiling cstr_core v0.2.5
warning: lint `unaligned_references` has been removed: converted into hard error, see issue #82523 <https://github.com/rust-lang/rust/issues/82523> for more information
 --> ogc-sys/src/lib.rs:5:10
  |
5 | #![allow(unaligned_references)]
  |          ^^^^^^^^^^^^^^^^^^^^
  |
  = note: `#[warn(renamed_and_removed_lints)]` on by default

   Compiling ogc-rs v0.1.1 (/home/antoineok/ogc-rs)
error[E0425]: cannot find function, tuple struct or tuple variant `AESND_RegisterAudioCallback` in crate `ffi`
     --> src/aesnd.rs:64:18
      |
64    |               ffi::AESND_RegisterAudioCallback(callback);
      |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: a function with a similar name exists: `AESND_RegisterAudioCallbackWithArg`
      |
     ::: /home/antoineok/ogc-rs/ogc-sys/src/ogc.rs:12184:5
      |
12184 | /     pub fn AESND_RegisterAudioCallbackWithArg(
12185 | |         cb: AESNDAudioCallbackArg,
12186 | |         cbArg: *mut ::libc::c_void,
12187 | |     ) -> AESNDAudioCallbackArg;
      | |______________________________- similarly named function `AESND_RegisterAudioCallbackWithArg` defined here

error[E0425]: cannot find function, tuple struct or tuple variant `AESND_RegisterVoiceCallback` in crate `ffi`
     --> src/aesnd.rs:192:18
      |
192   |               ffi::AESND_RegisterVoiceCallback(play_state, callback);
      |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: a function with a similar name exists: `AESND_RegisterVoiceCallbackWithArg`
      |
     ::: /home/antoineok/ogc-rs/ogc-sys/src/ogc.rs:12237:5
      |
12237 | /     pub fn AESND_RegisterVoiceCallbackWithArg(
12238 | |         pb: *mut AESNDPB,
12239 | |         cb: AESNDVoiceCallbackArg,
12240 | |         cbArg: *mut ::libc::c_void,
12241 | |     ) -> AESNDVoiceCallbackArg;
      | |______________________________- similarly named function `AESND_RegisterVoiceCallbackWithArg` defined here

error[E0425]: cannot find function, tuple struct or tuple variant `AESND_AllocateVoice` in crate `ffi`
     --> src/aesnd.rs:197:24
      |
197   |           unsafe { *ffi::AESND_AllocateVoice(None) }
      |                          ^^^^^^^^^^^^^^^^^^^ help: a function with a similar name exists: `AESND_PlayVoice`
      |
     ::: /home/antoineok/ogc-rs/ogc-sys/src/ogc.rs:12226:5
      |
12226 | /     pub fn AESND_PlayVoice(
12227 | |         pb: *mut AESNDPB,
12228 | |         format: u32_,
12229 | |         buffer: *const ::libc::c_void,
...     |
12233 | |         looped: bool,
12234 | |     );
      | |_____- similarly named function `AESND_PlayVoice` defined here

warning: `ogc-sys` (lib) generated 1 warning

stdbool.h not found when compiling ogc-sys and LLVM's target data-layout changing

Hi again,
I have two problems with your library.
The first one is a change in LLVM's default target:
error: data-layout for target 'powerpc-unknown-eabi-6532891863323583425', 'E-m:e-p:32:32-i64:64-n32', differs from LLVM target's 'powerpc-unknown-eabi' default layout, 'E-m:e-p:32:32-Fn32-i64:64-n32'
Replacing the data-layout in the json by the one said above seems to fix the issue.
The second one appears when compiling ogc-sys:
Link to the error message
I can send the error with the backtrace env variable set to 1 or full if asked.

Missing tests

Is it possible to integrate unit tests, doc tests and integration tests for ogc-rs? I've been trying to figure it out but so far no good.

Future incompatibility in ogc-sys v0.1.0

Currently, cargo mentions a future incompatibility issue while building ogc-sys:

warning: `#[derive]` can't be used on a `#[repr(packed)]` struct that does not derive Copy (error E0133)
     --> /home/infra/.cargo/registry/src/github.com-1ecc6299db9ec823/ogc-sys-0.1.0/src/ogc.rs:10265:10
      |
10265 | #[derive(Debug)]
      |          ^^^^^
      |
note: the lint level is defined here
     --> /home/infra/.cargo/registry/src/github.com-1ecc6299db9ec823/ogc-sys-0.1.0/src/lib.rs:5:10
      |
5     | #![allow(unaligned_references)]
      |          ^^^^^^^^^^^^^^^^^^^^
      = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
      = note: for more information, see issue #82523 <https://github.com/rust-lang/rust/issues/82523>
      = note: this warning originates in the derive macro `Debug` (in Nightly builds, run with -Z macro-backtrace for more info)

This can be resolved by updating bindgen to v0.60.1, incrementing the version for ogc-sys, and then updating the package on crates.io. I can submit a PR for the first two later.

`get_clang_version` does not parse the version correctly

When building ogc-sys, Clang is unable to find system libraries like stdlib.h. I did some probing, and found that get_clang_version outputs 16.0.6 instead of the expected 16, leading to an invalid /usr/lib/clang/.../include path.

The problem is with the regex:

let regex = Regex::new(r"(?m)\d+(\.\d+)+").unwrap();
let result = regex.captures(first_line).unwrap().get(0);

Capture group 0 refers to the whole match, which includes the (\.\d+)+ part. Perhaps you meant:

let regex = Regex::new(r"(?m)(\d+)(\.\d+)+").unwrap();
let result = regex.captures(first_line).unwrap().get(1);

Or, using non-capturing groups:

let regex = Regex::new(r"(?m)\d+(?:\.\d+)+").unwrap();
let result = regex.captures(first_line).unwrap().get(0);

Missing examples.

ogc-rs currently only has one example which resides in another repository. ogc-rs should have examples included in its repository, making it easier to figure out how to use it. I have ported ProfElements' embedded_graphics to pure ogc-rs functions: https://github.com/knarkzel/rogue. I'd also recommend restructuring the repository such that the structure looks like this:

ogc-rs
|-- Cargo.lock
|-- Cargo.toml
|-- LICENSE
|-- README.md
|-- examples
|-- ogc-sys
|   |-- Cargo.toml
|   |-- build.rs
|   |-- src
|   `-- wrapper.h
|-- powerpc-unknown-eabi.json
`-- src
    |-- audio.rs
    |-- console.rs
    |-- debug.rs
    |-- error.rs
    |-- gu.rs
    |-- gx.rs
    |-- lib.rs
    |-- network.rs
    |-- runtime.rs
    |-- system.rs
    |-- utils.rs
    `-- video.rs

This way, we can easily add examples without getting errors because of "virtual Cargo.toml manifesto...".

ogc-sys: no bindings generated for `static inline` methods

In the process of trying to convert the triangle example from https://github.com/devkitPro/wii-examples/blob/master/graphics/gx/triangle/source/triangle.c to rust I noticed that multiple methods including GX_End() where missing from ogc-sys.
All these methods are static inline methods in libogc/include/ogc/gx.h

These methods should somehow be directly converted to rust because they are not exported.
Note that GX_End() doesn't actually do anything at all. And the other methods are very simple.

A relevant issue in rust-bindgen is rust-lang/rust-bindgen#1090

All inline methods in gx.h
$ grep '^static inline' $DEVKITPRO/libogc/include/ogc/gx.h
static inline void GX_End(void)
static inline void GX_Position3f32(f32 x,f32 y,f32 z)
static inline void GX_Position3u16(u16 x,u16 y,u16 z)
static inline void GX_Position3s16(s16 x,s16 y,s16 z)
static inline void GX_Position3u8(u8 x,u8 y,u8 z)
static inline void GX_Position3s8(s8 x,s8 y,s8 z)
static inline void GX_Position2f32(f32 x,f32 y)
static inline void GX_Position2u16(u16 x,u16 y)
static inline void GX_Position2s16(s16 x,s16 y)
static inline void GX_Position2u8(u8 x,u8 y)
static inline void GX_Position2s8(s8 x,s8 y)
static inline void GX_Position1x8(u8 index)
static inline void GX_Position1x16(u16 index)
static inline void GX_Normal3f32(f32 nx,f32 ny,f32 nz)
static inline void GX_Normal3s16(s16 nx,s16 ny,s16 nz)
static inline void GX_Normal3s8(s8 nx,s8 ny,s8 nz)
static inline void GX_Normal1x8(u8 index)
static inline void GX_Normal1x16(u16 index)
static inline void GX_Color4u8(u8 r,u8 g,u8 b,u8 a)
static inline void GX_Color3u8(u8 r,u8 g,u8 b)
static inline void GX_Color3f32(f32 r, f32 g, f32 b)
static inline void GX_Color1u32(u32 clr)
static inline void GX_Color1u16(u16 clr)
static inline void GX_Color1x8(u8 index)
static inline void GX_Color1x16(u16 index)
static inline void GX_TexCoord2f32(f32 s,f32 t)
static inline void GX_TexCoord2u16(u16 s,u16 t)
static inline void GX_TexCoord2s16(s16 s,s16 t)
static inline void GX_TexCoord2u8(u8 s,u8 t)
static inline void GX_TexCoord2s8(s8 s,s8 t)
static inline void GX_TexCoord1f32(f32 s)
static inline void GX_TexCoord1u16(u16 s)
static inline void GX_TexCoord1s16(s16 s)
static inline void GX_TexCoord1u8(u8 s)
static inline void GX_TexCoord1s8(s8 s)
static inline void GX_TexCoord1x8(u8 index)
static inline void GX_TexCoord1x16(u16 index)
static inline void GX_MatrixIndex1x8(u8 index)

ld error while compiling examples

It's not an rust error this time, but an error during example compilation (not during the compilation of ogc-rs)

error: linking with `powerpc-eabi-gcc` failed: exit status: 1
  |
  = note: LC_ALL="C" PATH="/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/bin:/opt/devkitpro/devkitPPC/powerpc-eabi/bin:/opt/devkitpro/devkitPPC/bin:/opt/devkitpro/tools/bin:/home/antoineok/.cargo/bin:/home/antoineok/.vscode-server/bin/695af097c7bd098fbf017ce3ac85e09bbc5dda06/bin/remote-cli:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Program Files/Common Files/Oracle/Java/javapath:/mnt/c/devkitPro/msys2/usr/bin:/mnt/c/Program Files/Zulu/zulu-8/bin/:/mnt/d/Program Files/Zulu/zulu-17/bin/:/mnt/c/Program Files/Python310/Scripts/:/mnt/c/Program Files/Python310/:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0/:/mnt/c/Windows/System32/OpenSSH/:/mnt/c/Program Files/NVIDIA Corporation/NVIDIA NvDLISR:/mnt/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/mnt/c/Program Files/Git/cmd:/mnt/c/WINDOWS/system32:/mnt/c/WINDOWS:/mnt/c/WINDOWS/System32/Wbem:/mnt/c/WINDOWS/System32/WindowsPowerShell/v1.0/:/mnt/c/WINDOWS/System32/OpenSSH/:/mnt/c/Program Files/dotnet/:/Docker/host/bin:/mnt/c/Program Files/nodejs/:/mnt/c/devkitPro/devkitPPC/bin:/mnt/c/devkitPro/devkitPPC/powerpc-eabi/bin:/mnt/c/laragon/bin/mysql/mariadb-10.11.2-winx64/bin:/mnt/c/Program Files/LLVM/bin:/mnt/c/Users/antoine/.cargo/bin:/mnt/c/Users/antoine/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/antoine/AppData/Local/JetBrains/Toolbox/scripts:/mnt/c/Users/antoine/AppData/Roaming/npm:/mnt/c/Users/antoine/.dotnet/tools:/mnt/c/Users/antoine/AppData/Local/Programs/Microsoft VS Code/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl" VSLANG="1033" "powerpc-eabi-gcc" "-mrvl" "-meabi" "-mhard-float" "/tmp/rustc1pKwOj/symbols.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.21hno1q9r6dckfnb.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.25c0whr7nfc6zf3z.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.2kpxdvgktgpjtpvo.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.2v71gi6gzg2mien0.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.2xp7gaw4fqlf1aob.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.2zhuq53jakt60p2s.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.32vrtt2u0xg3yim.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.3vkh9j00bdslh0uy.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.42m87843vqlmua8o.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.4el662cvfq412mrn.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.4nikgvbeh6j6rkhk.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.4tszl1yarnsu3itv.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.4xelt1ehy2if36r.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.50vsv9u432erjk3o.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.ju558kks4uflm8z.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.kljosfhmsz9e9w7.rcgu.o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729.514pfmmtwhgqazna.rcgu.o" "-Wl,--as-needed" "-L" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps" "-L" "/home/antoineok/ogc-rs/examples/template/target/debug/deps" "-L" "/opt/devkitpro/devkitPPC/powerpc-eabi/lib" "-L" "/opt/devkitpro/libogc/lib/wii" "-L" "/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/powerpc-unknown-eabi/lib" "-Wl,-Bstatic" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_rs-76b5f4eaeb3f0e88.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libcfg_if-97a7dca0318181e9.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libvoladdress-7f36387e5f14c687.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libbit_field-9f42316ea92c684e.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/liblibm-8ea8a9be2027557d.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/liblibc-2ef421a58f8f0780.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libnum_enum-18ab7f96a2ab69e9.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libcstr_core-2eda37ff5f2124f5.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libmemchr-92c3dd01f248fd5d.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libcty-a7f6bf53093b6624.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libbitflags-27675cabe3306053.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/liballoc-509790ff65ed2f8f.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/librustc_std_workspace_core-60f50514e75d82da.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libcore-45eb83842269b674.rlib" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libcompiler_builtins-74006f92e91c08ee.rlib" "-Wl,-Bdynamic" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L" "/home/antoineok/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/powerpc-unknown-eabi/lib" "-o" "/home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/template-965c3dc52bb0c729" "-Wl,--gc-sections" "-no-pie" "-nodefaultlibs"
  = note: /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-vfprintf.o): in function `_vfprintf_r':
          (.text._vfprintf_r+0x2464): undefined reference to `_restfpr_31_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-vfprintf.o): in function `__sbprintf':
          (.text.__sbprintf+0xfc): undefined reference to `_restgpr_26_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-vfiprintf.o): in function `__sprint_r':
          (.text.__sprint_r+0xc8): undefined reference to `_restgpr_24_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-vfiprintf.o): in function `_vfiprintf_r':
          (.text._vfiprintf_r+0x13f4): undefined reference to `_restgpr_14_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-vfiprintf.o): in function `__sbprintf':
          (.text.__sbprintf+0xfc): undefined reference to `_restgpr_26_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libsysbase_libsysbase_a-sbrk.o): in function `_sbrk_r':
          (.text._sbrk_r+0x6e): undefined reference to `__end__'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: (.text._sbrk_r+0x72): undefined reference to `__end__'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-svfprintf.o): in function `_svfprintf_r':
          (.text._svfprintf_r+0x2338): undefined reference to `_restfpr_31_x'
          /opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.1.0/../../../../powerpc-eabi/bin/ld: /home/antoineok/ogc-rs/examples/template/target/powerpc-unknown-eabi/debug/deps/libogc_sys-f92cdd3592aabc03.rlib(libc_a-svfiprintf.o): in function `__ssprint_r':
          (.text.__ssprint_r+0x19c): undefined reference to `_restgpr_22_x'
          collect2: error: ld returned 1 exit status
          
  = note: some `extern` functions couldn't be found; some native libraries may need to be installed or have their path specified
  = note: use the `-l` flag to specify native libraries to link
  = note: use the `cargo:rustc-link-lib` directive to specify the native libraries to link with Cargo (see https://doc.rust-lang.org/cargo/reference/build-scripts.html#cargorustc-link-libkindname)

CLIPPY COMPLAINS ALOT.

when using cargo clippy it yells at us for alot of things. I hope we can fix this.
Should be low hanging fruit though.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.