#libc #bare-metal #function #calls #memset #rustc #memcpy

rlibc

A bare-metal library supplying certain libc functions like memcpy, memmove, memset and memcmp. This is designed for use in freestanding environments where another libc does not exist, since rustc may implicitly insert calls to such functions.

9 releases (1 stable)

Uses old Rust 2015

1.0.0 Jan 17, 2016
0.1.5 Jan 15, 2016
0.1.4 Aug 10, 2015
0.1.3 Mar 19, 2015
0.0.2 Nov 21, 2014

#5 in #memset

Download history 1798/week @ 2024-07-20 1927/week @ 2024-07-27 2100/week @ 2024-08-03 2397/week @ 2024-08-10 1694/week @ 2024-08-17 1890/week @ 2024-08-24 1766/week @ 2024-08-31 1695/week @ 2024-09-07 2087/week @ 2024-09-14 2287/week @ 2024-09-21 2085/week @ 2024-09-28 1775/week @ 2024-10-05 3321/week @ 2024-10-12 1745/week @ 2024-10-19 1914/week @ 2024-10-26 3208/week @ 2024-11-02

10,427 downloads per month
Used in 107 crates (16 directly)

MIT/Apache

7KB
137 lines

rlibc

A bare minimum "libc" for Rust crates that do not want to rely on libc itself. This crate provides functions which LLVM often lowers intrinsic calls to and will be required to link correctly.

Usage

Add this to your Cargo.toml:

[dependencies]

rlibc = "0.1"

And add this to your crate root:

extern crate rlibc;

lib.rs:

A bare-metal library supplying functions rustc may lower code to

This library is not intended for general use, and is superseded by a system libc if one is available. In a freestanding context, however, common functions such as memset, memcpy, etc are not implemented. This library provides an implementation of these functions which are either required by libcore or called by rustc implicitly.

This library is never included by default, and must be manually included if necessary. It is an error to include this library when also linking with the system libc library.

No runtime deps