You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
823 B

4 years ago
INSTALL:= /usr/local/lib
4 years ago
INSTALL-BIN:= /usr/local/bin
INSTALL-INCLUDE:=/usr/local/include
4 years ago
CLI:= cli
4 years ago
4 years ago
4 years ago
khash:
4 years ago
RUSTFLAGS="-C target-cpu=native" cargo build --release
4 years ago
strip ./target/release/libkhash.so
4 years ago
cd $(CLI) && $(MAKE) kana-hash
4 years ago
4 years ago
khash-nonative:
cargo build --release
cd $(CLI) && $(MAKE) kana-hash
4 years ago
test:
RUSTFLAGS="-C target-cpu=native -C opt-level=3" cargo test
RUSTFLAGS="-C target-cpu=native -C opt-level=3" cargo bench
4 years ago
cd $(CLI) && $(MAKE)
4 years ago
install:
4 years ago
cp -f ./target/release/libkhash.so $(INSTALL)/libkhash.so
cp -f ./target/release/libkhash.a $(INSTALL)/libkhash.a
4 years ago
cp -f $(CLI)/build/kana-hash $(INSTALL-BIN)/kana-hash
cp -f include/khash.h $(INSTALL-INCLUDE)/khash.h
4 years ago
uninstall:
rm -f $(INSTALL)/libkhash.so
rm -f $(INSTALL)/libkhash.a
4 years ago
rm -f $(INSTALL-BIN)/kana-hash
rm -f $(INSTALL-INCLUDE)/khash.h