rustybox, an experimental fork written entirely in Rust

Tim Tassonis stuff at decentral.ch
Fri Nov 15 21:19:28 UTC 2019


On 11/14/19 11:00 PM, Samuel Ainsworth wrote:
> Hello BusyBox overlords,
> 
> This week I thought it would be interesting to try porting busybox to 
> Rust with c2rust. I was pleasantly surprised to find out that it 
> actually worked. I thought the results might be interesting to the 
> BusyBox team as well. I have no idea if the core team is interested in 
> Rust at all, but I’d be happy to elaborate if there’s interest. Although 
> I did a complete transpile, a more conservative option would be to keep 
> applets written in C, with appletlib/libbb translated to Rust.
> 
> If anyone else is interested in contributing, there’s lots to be done!

Yeah. lots. It doesn't even compile:

$ curl -L -o rustybox-master.tar.gz 
https://github.com/samuela/rustybox/archive/master.tar.gz

$ tar xf rustybox-master.tar.gz
$ cd rustybox-master
$ cargo build

     Updating crates.io index
   Downloaded lazy_static v1.4.0
   Downloaded libc v0.2.65
   Downloaded c2rust-asm-casts v0.1.1
   Downloaded c2rust-bitfields v0.3.0
   Downloaded f128 v0.2.6
   Downloaded num-traits v0.2.9
   Downloaded autocfg v0.1.7
   Downloaded c2rust-bitfields-derive v0.2.0
   Downloaded f128_input v0.2.1
   Downloaded quote v0.6.13
   Downloaded f128_internal v0.2.1
   Downloaded syn v0.15.44
   Downloaded cc v1.0.47
    Compiling autocfg v0.1.7
    Compiling proc-macro2 v0.4.30
    Compiling unicode-xid v0.1.0
    Compiling libc v0.2.65
    Compiling cc v1.0.47
    Compiling syn v0.15.44
    Compiling rustybox v0.0.0 (/home/timtas/rustybox-master)
    Compiling c2rust-asm-casts v0.1.1
    Compiling lazy_static v1.4.0
    Compiling num-traits v0.2.9
    Compiling f128_internal v0.2.1
    Compiling quote v0.6.13
    Compiling f128_input v0.2.1
    Compiling c2rust-bitfields-derive v0.2.0
    Compiling f128 v0.2.6
error[E0554]: #![feature] may not be used on the stable release channel
  --> 
/home/timtas/.cargo/registry/src/github.com-1ecc6299db9ec823/f128-0.2.6/src/lib.rs:1:1
   |
1 | #![feature(proc_macro_hygiene)]
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error: aborting due to previous error

For more information about this error, try `rustc --explain E0554`.
error: Could not compile `f128`.

To learn more, run the command again with --verbose.





More information about the busybox mailing list