Skip to content
Snippets Groups Projects
Commit 16cf6e02 authored by Paul Sajna's avatar Paul Sajna
Browse files

build mman header

parent 4f5d65e7
No related branches found
No related tags found
No related merge requests found
[package]
name = "mman"
version = "0.1.0"
authors = ["Jeremy Soller <jackpot51@gmail.com>"]
build = "build.rs"
[build-dependencies]
cbindgen = { path = "../../cbindgen" }
[dependencies]
platform = { path = "../../platform" }
extern crate cbindgen;
use std::{env, fs};
fn main() {
let crate_dir = env::var("CARGO_MANIFEST_DIR").expect("CARGO_MANIFEST_DIR not set");
fs::create_dir_all("../../target/include").expect("failed to create include directory");
cbindgen::generate(crate_dir)
.expect("failed to generate bindings")
.write_to_file("../../target/include/mman.h");
}
sys_includes = []
include_guard = "_MMAN_H"
language = "C"
[enum]
prefix_with_name = true
#![no_std]
extern crate platform;
use platform::types::*;
#[no_mangle]
pub extern "C" fn mlock(addr: *const c_void, len: usize) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn mlockall(flags: c_int) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn mmap(
addr: *mut c_void,
len: usize,
prot: c_int,
flags: c_int,
fildes: c_int,
off: off_t,
) -> *mut c_void {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn mprotect(addr: *mut c_void, len: usize, prot: c_int) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn msync(addr: *mut c_void, len: usize, flags: c_int) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn munlock(addr: *const c_void, len: usize) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn munlockall() -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn munmap(addr: *mut c_void, len: usize) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn shm_open(
name: *const c_char,
oflag: c_int,
mode: mode_t,
) -> c_int {
unimplemented!();
}
#[no_mangle]
pub extern "C" fn shm_unlink(name: *const c_char) -> c_int {
unimplemented!();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment