You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.2 KiB
42 lines
1.2 KiB
7 years ago
|
#!/usr/bin/env bash
|
||
|
|
||
|
set -euxo pipefail
|
||
|
|
||
|
bindgen "$DEVKITPRO/libctru/include/citro3d.h" \
|
||
3 years ago
|
--rust-target nightly \
|
||
7 years ago
|
--use-core \
|
||
|
--distrust-clang-mangling \
|
||
|
--no-layout-tests \
|
||
|
--ctypes-prefix "::libc" \
|
||
|
--no-prepend-enum-name \
|
||
|
--generate "functions,types,vars" \
|
||
3 years ago
|
--blocklist-type "u(8|16|32|64)" \
|
||
|
--blocklist-type "__builtin_va_list" \
|
||
|
--blocklist-type "__va_list" \
|
||
3 years ago
|
--opaque-type "GPU_.*" \
|
||
|
--opaque-type "GFX_.*" \
|
||
|
--opaque-type "gfx.*_t" \
|
||
|
--opaque-type "DVL.*" \
|
||
|
--opaque-type "shader.*" \
|
||
|
--opaque-type "float24Uniform_s" \
|
||
3 years ago
|
--allowlist-type "C3D_.*" \
|
||
|
--allowlist-function "C3D_.*" \
|
||
|
--allowlist-var "C3D_.*" \
|
||
|
--allowlist-function 'AttrInfo_(Init|AddLoader|AddFixed)' \
|
||
|
--allowlist-function 'BufInfo_(Init|Add)' \
|
||
|
--allowlist-function 'Mtx_.*' \
|
||
3 years ago
|
--raw-line "use ctru_sys::*;" \
|
||
7 years ago
|
-- \
|
||
|
--target=arm-none-eabi \
|
||
|
--sysroot=$DEVKITARM/arm-none-eabi \
|
||
|
-isystem$DEVKITARM/arm-none-eabi/include \
|
||
|
-I$DEVKITPRO/libctru/include \
|
||
|
-mfloat-abi=hard \
|
||
|
-march=armv6k \
|
||
|
-mtune=mpcore \
|
||
|
-mfpu=vfp \
|
||
|
-DARM11 \
|
||
|
-D_3DS \
|
||
3 years ago
|
-D__3DS__ \
|
||
|
> src/bindings.rs
|