mirror of
https://github.com/darkrenaissance/darkfi.git
synced 2026-01-07 22:04:03 -05:00
bin: Enable static compile targets for more bins
This commit is contained in:
2
Makefile
2
Makefile
@@ -9,7 +9,7 @@ CARGO = cargo +nightly
|
||||
# Compile target for system binaries
|
||||
RUST_TARGET = $(shell rustc -Vv | grep '^host: ' | cut -d' ' -f2)
|
||||
# Uncomment when doing musl static builds
|
||||
#RUSTFLAGS = "-C target-feature=+crt-static -C link-self-contained=yes"
|
||||
#RUSTFLAGS = -C target-feature=+crt-static -C link-self-contained=yes
|
||||
|
||||
# Binaries to be built
|
||||
BINS = \
|
||||
|
||||
@@ -6,18 +6,21 @@ PREFIX = $(HOME)/.cargo
|
||||
# Cargo binary
|
||||
CARGO = cargo +nightly
|
||||
|
||||
# Compile target
|
||||
RUST_TARGET = $(shell rustc -Vv | grep '^host: ' | cut -d' ' -f2)
|
||||
|
||||
SRC = \
|
||||
Cargo.toml \
|
||||
../../Cargo.toml \
|
||||
$(shell find src -type f) \
|
||||
$(shell find ../../src -type f) \
|
||||
$(shell find src -type f -name '*.rs') \
|
||||
$(shell find ../../src -type f -name '*.rs') \
|
||||
|
||||
BIN = ../../darkirc
|
||||
|
||||
all: $(BIN)
|
||||
|
||||
$(BIN): $(SRC)
|
||||
$(CARGO) build $(TARGET_PRFX)$(RUST_TARGET) --release --package darkirc
|
||||
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) build --target=$(RUST_TARGET) --release --package darkirc
|
||||
cp -f ../../target/$(RUST_TARGET)/release/darkirc $@
|
||||
|
||||
android:
|
||||
|
||||
@@ -6,18 +6,21 @@ PREFIX = $(HOME)/.cargo
|
||||
# Cargo binary
|
||||
CARGO = cargo +nightly
|
||||
|
||||
# Compile target
|
||||
RUST_TARGET = $(shell rustc -Vv | grep '^host: ' | cut -d' ' -f2)
|
||||
|
||||
SRC = \
|
||||
Cargo.toml \
|
||||
../../Cargo.toml \
|
||||
$(shell find src -type f) \
|
||||
$(shell find ../../src -type f) \
|
||||
$(shell find src -type f -name '*.rs') \
|
||||
$(shell find ../../src -type f -name '*.rs') \
|
||||
|
||||
BIN = ../../lilith
|
||||
|
||||
all: $(BIN)
|
||||
|
||||
$(BIN): $(SRC)
|
||||
$(CARGO) build $(TARGET_PRFX)$(RUST_TARGET) --release --package lilith
|
||||
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) build --target=$(RUST_TARGET) --release --package lilith
|
||||
cp -f ../../target/$(RUST_TARGET)/release/lilith $@
|
||||
|
||||
clean:
|
||||
|
||||
@@ -6,18 +6,21 @@ PREFIX = $(HOME)/.cargo
|
||||
# Cargo binary
|
||||
CARGO = cargo +nightly
|
||||
|
||||
# Compile target
|
||||
RUST_TARGET = $(shell rustc -Vv | grep '^host: ' | cut -d' ' -f2)
|
||||
|
||||
SRC = \
|
||||
Cargo.toml \
|
||||
../../../Cargo.toml \
|
||||
$(shell find src -type f) \
|
||||
$(shell find ../../../src -type f) \
|
||||
$(shell find src -type f -name '*.rs') \
|
||||
$(shell find ../../../src -type f -name '*.rs') \
|
||||
|
||||
BIN = ../../../taud
|
||||
|
||||
all: $(BIN)
|
||||
|
||||
$(BIN): $(SRC)
|
||||
$(CARGO) build $(TARGET_PRFX)$(RUST_TARGET) --release --package taud
|
||||
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) build --target=$(RUST_TARGET) --release --package taud
|
||||
cp -f ../../../target/$(RUST_TARGET)/release/taud $@
|
||||
|
||||
clean:
|
||||
|
||||
@@ -6,18 +6,21 @@ PREFIX = $(HOME)/.cargo
|
||||
# Cargo binary
|
||||
CARGO = cargo +nightly
|
||||
|
||||
# Compile target
|
||||
RUST_TARGET = $(shell rustc -Vv | grep '^host: ' | cut -d' ' -f2)
|
||||
|
||||
SRC = \
|
||||
Cargo.toml \
|
||||
../../Cargo.toml \
|
||||
$(shell find src -type f) \
|
||||
$(shell find ../../src -type f) \
|
||||
$(shell find src -type f -name '*.rs') \
|
||||
$(shell find ../../src -type f -name '*.rs') \
|
||||
|
||||
BIN = ../../vanityaddr
|
||||
|
||||
all: $(BIN)
|
||||
|
||||
$(BIN): $(SRC)
|
||||
$(CARGO) build $(TARGET_PRFX)$(RUST_TARGET) --release --package vanityaddr
|
||||
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) build --target=$(RUST_TARGET) --release --package vanityaddr
|
||||
cp -f ../../target/$(RUST_TARGET)/release/vanityaddr $@
|
||||
|
||||
clean:
|
||||
|
||||
Reference in New Issue
Block a user