From 246ced3a8ce7bbfb60f14dec7e138670afdab647 Mon Sep 17 00:00:00 2001 From: Micah Elizabeth Scott Date: Thu, 9 Mar 2023 19:33:41 -0800 Subject: ext: build equix and hashx using automake This replaces the sketchy cmake invocation we had inside configure The libs are always built and always used in unit tests, but only included in libtor and tor when --enable-gpl is set. Signed-off-by: Micah Elizabeth Scott --- Makefile.am | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index 28a1c8e57d..21f71e2e05 100644 --- a/Makefile.am +++ b/Makefile.am @@ -114,6 +114,10 @@ TOR_CRYPTO_LIBS = \ $(LIBKECCAK_TINY) \ $(LIBDONNA) +if BUILD_MODULE_POW +TOR_CRYPTO_LIBS += $(EQUIX_LIBS) +endif + # Variants of the above for linking the testing variant of tor (for coverage # and tests) if UNITTESTS_ENABLED @@ -121,13 +125,10 @@ TOR_CRYPTO_TESTING_LIBS = \ src/lib/libtor-tls-testing.a \ src/lib/libtor-crypt-ops-testing.a \ $(LIBKECCAK_TINY) \ - $(LIBDONNA) + $(LIBDONNA) \ + $(EQUIX_LIBS) endif -EQUIX_LIBS = \ - src/ext/equix/build/libequix.a \ - src/ext/equix/build/hashx/libhashx.a - # All static libraries used to link tor. TOR_INTERNAL_LIBS = \ src/core/libtor-app.a \ @@ -136,8 +137,7 @@ TOR_INTERNAL_LIBS = \ $(TOR_CRYPTO_LIBS) \ $(TOR_UTIL_LIBS) \ src/trunnel/libor-trunnel.a \ - src/lib/libtor-trace.a \ - $(EQUIX_LIBS) + src/lib/libtor-trace.a libtor.a: $(TOR_INTERNAL_LIBS) $(AM_V_AR) export AR="$(AR)"; \ @@ -157,8 +157,7 @@ TOR_INTERNAL_TESTING_LIBS = \ $(TOR_CRYPTO_TESTING_LIBS) \ $(TOR_UTIL_TESTING_LIBS) \ src/trunnel/libor-trunnel-testing.a \ - src/lib/libtor-trace.a \ - $(EQUIX_LIBS) + src/lib/libtor-trace.a src/test/libtor-testing.a: $(TOR_INTERNAL_TESTING_LIBS) $(AM_V_AR) export AR="$(AR)"; \ -- cgit v1.2.3-54-g00ecf