Skip to content
Snippets Groups Projects
Commit a9f2e9a9 authored by Jeremy Soller's avatar Jeremy Soller
Browse files

Add template

parent c4b88cc1
No related branches found
No related tags found
No related merge requests found
#ifndef _BITS_WCHAR_H
#define _BITS_WCHAR_H
typedef signed short wchar_t;
typedef signed int wint_t;
#endif /* _BITS_WCHAR_H */
...@@ -43,6 +43,7 @@ pub type c_long = i64; ...@@ -43,6 +43,7 @@ pub type c_long = i64;
pub type c_ulong = u64; pub type c_ulong = u64;
pub type wchar_t = i16; pub type wchar_t = i16;
pub type wint_t = i32;
pub type off_t = c_long; pub type off_t = c_long;
pub type mode_t = u16; pub type mode_t = u16;
......
[package]
name = "template"
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/template.h");
}
sys_includes = []
include_guard = "_TEMPLATE_H"
language = "C"
[enum]
prefix_with_name = true
//! template implementation for Redox, following http://pubs.opengroup.org/onlinepubs/7908799/xsh/template.h.html
#![no_std]
extern crate platform;
use platform::types::*;
/*
#[no_mangle]
pub extern "C" fn func(args) -> 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