-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
35 lines (25 loc) · 1021 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
CC = gcc
CCFLAGS = -B target/debug -iquote . -lrustic_ffi_client
wasm:
./clients/http/wasm/package.sh
wasm-publish: wasm
cd clients/http/wasm/pkg; npm publish
ffi: ffi-header ffi-library
ffi-library:
cargo build -p rustic-ffi-client --release
ffi-header:
cargo +nightly expand -p rustic-ffi-client > ffi-client.rs
cbindgen -o bindings.h -c clients/ffi/cbindgen.toml ffi-client.rs
rm ffi-client.rs
ffi-examples: target/ffi/sync_http_interop target/ffi/cb_http_interop ffi
LD_LIBRARY_PATH=target/debug ./target/ffi/sync_http_interop
LD_LIBRARY_PATH=target/debug ./target/ffi/cb_http_interop
target/ffi/sync_http_interop: clients/ffi/tests/sync_http_interop.c
mkdir -p target/ffi
$(CC) $(CCFLAGS) -o target/ffi/sync_http_interop clients/ffi/tests/sync_http_interop.c
target/ffi/cb_http_interop: clients/ffi/tests/cb_http_interop.c
mkdir -p target/ffi
$(CC) $(CCFLAGS) -o target/ffi/cb_http_interop clients/ffi/tests/cb_http_interop.c
extensions: uwu
uwu:
cargo build -p rustic-uwu-extension --release