Remove clibrojo, as it's broken

This commit is contained in:
Lucien Greathouse
2020-12-14 11:13:36 -08:00
parent cae4c46669
commit f911009752
5 changed files with 0 additions and 60 deletions

7
Cargo.lock generated
View File

@@ -240,13 +240,6 @@ dependencies = [
"vec_map",
]
[[package]]
name = "clibrojo"
version = "0.1.0"
dependencies = [
"rojo",
]
[[package]]
name = "cloudabi"
version = "0.0.3"

View File

@@ -28,13 +28,6 @@ dev_live_assets = []
[workspace]
members = [
"rojo-insta-ext",
"clibrojo",
"memofs",
]
default-members = [
".",
"rojo-insta-ext",
"memofs",
]

View File

@@ -1,13 +0,0 @@
[package]
name = "clibrojo"
version = "0.1.0"
authors = ["Lucien Greathouse <me@lpghatguy.com>"]
edition = "2018"
[lib]
crate-type = ["cdylib"]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
rojo = { path = ".." }

View File

@@ -1,19 +0,0 @@
# Rojo as a C Library
This is an experiment to expose a C API for Rojo that would be suitable for embedding it into an existing C/C++ application.
I'm hoping to expand it to drop the HTTP layer and communicate through a channel, which could make it feasible to embed into an existing Roblox IDE with minimal changes or additional code.
## Building
This project is currently not built by default and could break/disappear at any time.
```bash
cargo build -p clibrojo
```
On Windows, Cargo will generate a `clibrojo.dll` and associated `.lib` file. Link these into your project.
To generate the associated C header file to include in the project, use [cbindgen](https://github.com/eqrion/cbindgen):
```bash
cbindgen --crate clibrojo --output include/rojo.h
```

View File

@@ -1,14 +0,0 @@
use std::{ffi::CStr, os::raw::c_char, path::PathBuf};
use librojo::commands::{serve, ServeOptions};
#[no_mangle]
pub extern "C" fn rojo_serve(path: *const c_char) {
let path = unsafe { PathBuf::from(CStr::from_ptr(path).to_str().unwrap()) };
serve(&ServeOptions {
fuzzy_project_path: path,
port: None,
})
.unwrap();
}