Browse Source

Merge pull request #2 from AzureMarker/master

Add an init method to force linking
pull/4/head
Meziu 3 years ago committed by GitHub
parent
commit
878b8a30af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 9
      Cargo.toml
  2. 6
      src/lib.rs

9
Cargo.toml

@ -5,10 +5,5 @@ version = "0.1.0"
license = "MIT/Apache 2.0" license = "MIT/Apache 2.0"
edition = "2021" edition = "2021"
[lib] [dependencies]
name = "pthread_3ds" libc = { git = "https://github.com/Meziu/libc.git" }
path = "src/lib.rs"
crate-type = ["staticlib", "lib"]
[dependencies.libc]
git = "https://github.com/Meziu/libc.git"

6
src/lib.rs

@ -1,6 +1,12 @@
#![feature(thread_local)] #![feature(thread_local)]
#![allow(non_camel_case_types)] #![allow(non_camel_case_types)]
/// Call this somewhere to force Rust to link this module.
/// The call doesn't need to execute, just exist.
///
/// See https://github.com/rust-lang/rust/issues/47384
pub fn init() {}
// LIBCTRU THREADS // LIBCTRU THREADS
pub type _LOCK_T = i32; pub type _LOCK_T = i32;

Loading…
Cancel
Save