43 releases

0.1.45 Oct 8, 2020
0.1.44 Oct 3, 2020
0.1.41 Sep 14, 2020
0.1.36 Aug 27, 2020
0.1.20 Jun 28, 2020

#96 in #x86-64

Download history 86/week @ 2024-07-02 79/week @ 2024-07-23

104 downloads per month

MIT license

120KB
3K SLoC

x64_asm at crates.io x64_asm at docs.rs

x64_asm

x86_64 assembler

Get Started

How to use as an assembler command

cargo build
./target/debug/x64_asm <assembly-file in AT&T syntax>

How to use as a Rust crate

See documentation

use x64_asm;

fn main() -> Result<(), Box<dyn std::error::Error>>{
    // you can pass a file(or string).
    let elf_builder = x64_asm::assemble_file("asm.s", x64_asm::Syntax::ATANDT)?;
    
    elf_builder.generate_elf_file("obj.o")?;

    Ok(())
}

Test

cargo test
cargo test --features sample

Dependencies


lib.rs:

An x86_64 assembler.

Dependencies

~1.7–2.4MB
~47K SLoC