Make test-python work on Linux

This commit is contained in:
Dirkjan Ochtman 2023-12-01 06:18:14 -08:00 committed by Dirkjan Ochtman
parent 77f62de6ad
commit 6cc6220536
1 changed files with 7 additions and 1 deletions

View File

@ -1,6 +1,12 @@
ifeq ($(shell uname), Darwin)
PY_EXT := dylib
else
PY_EXT := so
endif
test-python:
cargo build --release
cp target/release/libinstant_distance.dylib instant-distance-py/test/instant_distance.so
cp target/release/libinstant_distance.$(PY_EXT) instant-distance-py/test/instant_distance.so
PYTHONPATH=instant-distance-py/test/ python3 -m test
clean: