Skip to content

Commit

Permalink
split exectuable and lib into separate packages
Browse files Browse the repository at this point in the history
  • Loading branch information
lukad committed Feb 8, 2019
1 parent 68446d6 commit cf89d48
Show file tree
Hide file tree
Showing 10 changed files with 57 additions and 38 deletions.
48 changes: 31 additions & 17 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 5 additions & 16 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,6 @@
[package]
authors = ["Luka Dornhecker"]
name = "rbf"
version = "0.1.0"
[workspace]

[[bin]]
doc = false
name = "rbf"

[dependencies]
combine = "3.4"
dynasm = "0.3"
dynasmrt = "0.3"
libc = "0.2.48"

[lib]
name = "rbf"
members = [
"rbf",
"librbf"
]
10 changes: 10 additions & 0 deletions librbf/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[package]
name = "librbf"
version = "0.1.0"
authors = ["Luka Dornhecker <[email protected]>"]

[dependencies]
combine = "3.4"
dynasm = "0.3"
dynasmrt = "0.3"
libc = "0.2.48"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
5 changes: 2 additions & 3 deletions tests/parser.rs → librbf/tests/parser.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
extern crate rbf;
extern crate librbf;

use rbf::parse;
use rbf::Instruction::*;
use librbf::{parse, Instruction::*};

#[test]
fn it_parses_an_empty_program() {
Expand Down
7 changes: 7 additions & 0 deletions rbf/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[package]
name = "rbf"
version = "0.1.0"
authors = ["Luka Dornhecker <[email protected]>"]

[dependencies]
librbf = { path = "../librbf", version = "0.1.0" }
4 changes: 2 additions & 2 deletions src/main.rs → rbf/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
extern crate rbf;
extern crate librbf;

use std::env;
use std::fs::File;
use std::io::{self, Read};

use rbf::{parse, Jit};
use librbf::{parse, Jit};

fn read_source<R>(mut input: R) -> String
where
Expand Down

0 comments on commit cf89d48

Please sign in to comment.