Replaced cargo-psx with just cargo.

Fixed remake not being in EU region.
Added heap support to remake.
Added remake to `rust-analyzer` linked projects.
This commit is contained in:
Filipe Rodrigues 2023-10-15 11:40:45 +01:00
parent 8bfaf7a87a
commit f7dded922e
6 changed files with 21 additions and 9 deletions

View File

@ -106,5 +106,9 @@
"WarGreymon",
"WarGrowlmon"
],
"rust-analyzer.linkedProjects": ["tools/Cargo.toml"]
"rust-analyzer.linkedProjects": [
"tools/Cargo.toml",
"remake-rust/Cargo.toml"
],
"rust-analyzer.check.allTargets": false
}

View File

@ -4,5 +4,5 @@ target = "mipsel-sony-psx"
rustflags = ["-Clink-arg=-Tpsexe.ld", "-Clink-arg=--oformat=binary"]
[unstable]
build-std = ["core"]
build-std = ["core", "alloc"]
build-std-features = ["compiler-builtins-mem"]

View File

@ -9,8 +9,17 @@ dependencies = [
"psx",
]
[[package]]
name = "linked_list_allocator"
version = "0.9.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "549ce1740e46b291953c4340adcd74c59bcf4308f4cac050fd33ba91b7168f4a"
[[package]]
name = "psx"
version = "0.1.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "47204f4a0c027798cd54dfa8ae34a3ce0d9fa0e2f59de7403f0c0a5e404e3198"
dependencies = [
"linked_list_allocator",
]

View File

@ -5,4 +5,4 @@ edition = "2021"
[dependencies]
psx = "0.1.6"
psx = { version = "0.1.6", features = ["EU_region", "heap"] }

View File

@ -3,6 +3,8 @@
use psx::{dprintln, Framebuffer};
psx::heap!( 1536 KB );
#[no_mangle]
fn main() {
let buf0 = (0, 0);

View File

@ -17,7 +17,6 @@ alias:
truncate : truncate # truncate (GNU coreutils) 9.3
python3 : python3 # Python 3.11.3
yq : yq # yq 3.2.2
cargo-psx: cargo-psx # cargo-psx-0.1.3
# Other tools
generate_psx_iso_deps : tools/generate_psx_iso_deps.py
@ -604,12 +603,10 @@ rules:
# Build the crate
- cwd: remake-rust/
args:
# Note: Using `$(cargo-psx)` doesn't work because of how cargo plugins
# work. Ideally however, we'd use something like `cargo --plugin=cargo-psx`,
# if it was supported.
- cargo
- psx
- $(cargo)
- build
- --release
- --package=^(name)
- [$(cp), remake-rust/$(build_target_dir)/^(name).exe, $(remake_psexe)]
# Then copy the dependency file and adjust the references