From 94f4c91e1a166f7f564ee4cf4342d524bee13c3f Mon Sep 17 00:00:00 2001 From: Alexey Osipov Date: Tue, 8 Nov 2022 17:26:26 +0300 Subject: [PATCH] Fix `make run-test` for newly cloned repo --- bindings/csharp/Makefile | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/bindings/csharp/Makefile b/bindings/csharp/Makefile index 4bc8b7d..a94bb7d 100644 --- a/bindings/csharp/Makefile +++ b/bindings/csharp/Makefile @@ -20,6 +20,8 @@ else CKZG_LIBRARY_PATH=Ckzg.Bindings/runtimes/$(CSHARP_PLATFORM)/native/ckzg.so endif +TARGETS=ckzg.c ../../src/c_kzg_4844.c ../../blst/$(BLST_OBJ) + .blst: cd ../../blst &&\ git apply ../blst_sha.patch &&\ @@ -27,8 +29,8 @@ endif git apply -R ../blst_sha.patch &&\ cd ../bindings/csharp -.ckzg: ckzg.c ../../src/c_kzg_4844.c ../../blst/$(BLST_OBJ) - $(CLANG_EXECUTABLE) -O -Wall -shared $(CLANG_FLAGS) ${addprefix -I,${INCLUDE_DIRS}} -o $(CKZG_LIBRARY_PATH) $^ +.ckzg: + $(CLANG_EXECUTABLE) -O -Wall -shared $(CLANG_FLAGS) ${addprefix -I,${INCLUDE_DIRS}} -o $(CKZG_LIBRARY_PATH) $(TARGETS) # Ckzg library ckzg: @@ -36,9 +38,9 @@ ckzg: @make .ckzg # E2e tests as an executable -test: tests.c ckzg.c ../../src/c_kzg_4844.c ../../blst/$(BLST_OBJ) +test: @make .blst - $(CLANG_EXECUTABLE) -O -w -Wall $(CLANG_FLAGS) ${addprefix -I,${INCLUDE_DIRS}} -o $(TESTS_EXECUTABLE) $^ + $(CLANG_EXECUTABLE) -O -w -Wall $(CLANG_FLAGS) ${addprefix -I,${INCLUDE_DIRS}} -o $(TESTS_EXECUTABLE) tests.c $(TARGETS) # E2e tests are built and run run-test: