2012-08-02 15:31:43 +02:00
|
|
|
|
2013-06-06 20:56:05 +02:00
|
|
|
noinst_LIBRARIES += \
|
|
|
|
src/common/libor.a \
|
|
|
|
src/common/libor-crypto.a \
|
|
|
|
src/common/libor-event.a
|
|
|
|
|
|
|
|
if UNITTESTS_ENABLED
|
|
|
|
noinst_LIBRARIES += \
|
|
|
|
src/common/libor-testing.a \
|
|
|
|
src/common/libor-crypto-testing.a \
|
|
|
|
src/common/libor-event-testing.a
|
|
|
|
endif
|
2012-08-02 15:31:43 +02:00
|
|
|
|
|
|
|
EXTRA_DIST+= \
|
|
|
|
src/common/common_sha1.i \
|
|
|
|
src/common/Makefile.nmake
|
|
|
|
|
|
|
|
#CFLAGS = -Wall -Wpointer-arith -O2
|
2014-09-24 16:51:39 +02:00
|
|
|
AM_CPPFLAGS += -I$(srcdir)/src/common -Isrc/common -I$(srcdir)/src/ext/trunnel -I$(srcdir)/src/trunnel
|
2012-08-02 15:31:43 +02:00
|
|
|
|
|
|
|
if USE_OPENBSD_MALLOC
|
2012-10-11 23:19:37 +02:00
|
|
|
libor_extra_source=src/ext/OpenBSD_malloc_Linux.c
|
2012-08-02 15:31:43 +02:00
|
|
|
else
|
|
|
|
libor_extra_source=
|
|
|
|
endif
|
|
|
|
|
2014-05-13 03:23:34 +02:00
|
|
|
if USE_MEMPOOLS
|
|
|
|
libor_mempool_source=src/common/mempool.c
|
|
|
|
libor_mempool_header=src/common/mempool.h
|
|
|
|
else
|
|
|
|
libor_mempool_source=
|
|
|
|
libor_mempool_header=
|
|
|
|
endif
|
|
|
|
|
2013-01-30 19:08:04 +01:00
|
|
|
src_common_libcurve25519_donna_a_CFLAGS=
|
|
|
|
|
2012-12-03 21:44:21 +01:00
|
|
|
if BUILD_CURVE25519_DONNA
|
2012-12-06 18:07:58 +01:00
|
|
|
src_common_libcurve25519_donna_a_SOURCES=\
|
|
|
|
src/ext/curve25519_donna/curve25519-donna.c
|
2013-01-30 19:08:04 +01:00
|
|
|
src_common_libcurve25519_donna_a_CFLAGS+=\
|
|
|
|
@F_OMIT_FRAME_POINTER@
|
2012-12-06 18:07:58 +01:00
|
|
|
noinst_LIBRARIES+=src/common/libcurve25519_donna.a
|
|
|
|
LIBDONNA=src/common/libcurve25519_donna.a
|
2012-12-03 21:44:21 +01:00
|
|
|
else
|
|
|
|
if BUILD_CURVE25519_DONNA_C64
|
2012-12-06 18:07:58 +01:00
|
|
|
src_common_libcurve25519_donna_a_SOURCES=\
|
|
|
|
src/ext/curve25519_donna/curve25519-donna-c64.c
|
|
|
|
noinst_LIBRARIES+=src/common/libcurve25519_donna.a
|
|
|
|
LIBDONNA=src/common/libcurve25519_donna.a
|
2012-12-03 21:44:21 +01:00
|
|
|
else
|
2012-12-06 18:07:58 +01:00
|
|
|
LIBDONNA=
|
2012-12-03 21:44:21 +01:00
|
|
|
endif
|
|
|
|
endif
|
2012-12-06 18:07:58 +01:00
|
|
|
|
2013-09-29 19:30:24 +02:00
|
|
|
LIBDONNA += $(LIBED25519_REF10)
|
|
|
|
|
2013-09-23 03:30:46 +02:00
|
|
|
if THREADS_PTHREADS
|
|
|
|
threads_impl_source=src/common/compat_pthreads.c
|
|
|
|
endif
|
|
|
|
if THREADS_WIN32
|
|
|
|
threads_impl_source=src/common/compat_winthreads.c
|
|
|
|
endif
|
|
|
|
|
2013-06-06 20:56:05 +02:00
|
|
|
LIBOR_A_SOURCES = \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/address.c \
|
2013-07-19 20:09:58 +02:00
|
|
|
src/common/backtrace.c \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/compat.c \
|
2013-09-23 03:30:46 +02:00
|
|
|
src/common/compat_threads.c \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/container.c \
|
|
|
|
src/common/di_ops.c \
|
|
|
|
src/common/log.c \
|
|
|
|
src/common/memarea.c \
|
|
|
|
src/common/util.c \
|
|
|
|
src/common/util_codedigest.c \
|
2014-04-09 19:45:27 +02:00
|
|
|
src/common/util_process.c \
|
2013-07-14 08:49:34 +02:00
|
|
|
src/common/sandbox.c \
|
2013-09-23 07:19:16 +02:00
|
|
|
src/common/workqueue.c \
|
2014-02-12 16:24:04 +01:00
|
|
|
src/ext/csiphash.c \
|
2014-09-24 16:51:39 +02:00
|
|
|
src/ext/trunnel/trunnel.c \
|
2014-05-13 03:23:34 +02:00
|
|
|
$(libor_extra_source) \
|
2013-09-23 03:30:46 +02:00
|
|
|
$(libor_mempool_source) \
|
|
|
|
$(threads_impl_source)
|
2012-08-02 15:31:43 +02:00
|
|
|
|
2013-06-06 20:56:05 +02:00
|
|
|
LIBOR_CRYPTO_A_SOURCES = \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/aes.c \
|
|
|
|
src/common/crypto.c \
|
2014-08-28 23:59:06 +02:00
|
|
|
src/common/crypto_pwbox.c \
|
2014-08-28 18:04:22 +02:00
|
|
|
src/common/crypto_s2k.c \
|
2013-02-04 17:32:55 +01:00
|
|
|
src/common/crypto_format.c \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/torgzip.c \
|
2012-12-03 21:44:21 +01:00
|
|
|
src/common/tortls.c \
|
2014-10-27 14:37:50 +01:00
|
|
|
src/trunnel/pwbox.c \
|
|
|
|
src/common/crypto_curve25519.c \
|
|
|
|
src/common/crypto_ed25519.c
|
2012-08-02 15:31:43 +02:00
|
|
|
|
2014-04-09 19:45:27 +02:00
|
|
|
LIBOR_EVENT_A_SOURCES = \
|
|
|
|
src/common/compat_libevent.c \
|
|
|
|
src/common/procmon.c
|
2013-06-06 20:56:05 +02:00
|
|
|
|
|
|
|
src_common_libor_a_SOURCES = $(LIBOR_A_SOURCES)
|
|
|
|
src_common_libor_crypto_a_SOURCES = $(LIBOR_CRYPTO_A_SOURCES)
|
|
|
|
src_common_libor_event_a_SOURCES = $(LIBOR_EVENT_A_SOURCES)
|
|
|
|
|
|
|
|
src_common_libor_testing_a_SOURCES = $(LIBOR_A_SOURCES)
|
|
|
|
src_common_libor_crypto_testing_a_SOURCES = $(LIBOR_CRYPTO_A_SOURCES)
|
|
|
|
src_common_libor_event_testing_a_SOURCES = $(LIBOR_EVENT_A_SOURCES)
|
|
|
|
|
|
|
|
src_common_libor_testing_a_CPPFLAGS = -DTOR_UNIT_TESTS $(AM_CPPFLAGS)
|
|
|
|
src_common_libor_crypto_testing_a_CPPFLAGS = -DTOR_UNIT_TESTS $(AM_CPPFLAGS)
|
|
|
|
src_common_libor_event_testing_a_CPPFLAGS = -DTOR_UNIT_TESTS $(AM_CPPFLAGS)
|
2013-07-09 18:37:11 +02:00
|
|
|
src_common_libor_testing_a_CFLAGS = $(AM_CFLAGS) $(TEST_CFLAGS)
|
|
|
|
src_common_libor_crypto_testing_a_CFLAGS = $(AM_CFLAGS) $(TEST_CFLAGS)
|
|
|
|
src_common_libor_event_testing_a_CFLAGS = $(AM_CFLAGS) $(TEST_CFLAGS)
|
|
|
|
|
2012-09-06 15:56:48 +02:00
|
|
|
COMMONHEADERS = \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/address.h \
|
2013-07-19 20:09:58 +02:00
|
|
|
src/common/backtrace.h \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/aes.h \
|
|
|
|
src/common/ciphers.inc \
|
|
|
|
src/common/compat.h \
|
|
|
|
src/common/compat_libevent.h \
|
2013-09-23 03:30:46 +02:00
|
|
|
src/common/compat_threads.h \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/container.h \
|
|
|
|
src/common/crypto.h \
|
2012-12-03 21:44:21 +01:00
|
|
|
src/common/crypto_curve25519.h \
|
2013-09-29 19:30:24 +02:00
|
|
|
src/common/crypto_ed25519.h \
|
2014-08-28 23:59:06 +02:00
|
|
|
src/common/crypto_pwbox.h \
|
2014-08-28 23:38:22 +02:00
|
|
|
src/common/crypto_s2k.h \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/di_ops.h \
|
|
|
|
src/common/memarea.h \
|
2014-04-17 04:22:47 +02:00
|
|
|
src/common/linux_syscalls.inc \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/procmon.h \
|
2013-07-14 02:31:18 +02:00
|
|
|
src/common/sandbox.h \
|
2013-06-06 20:56:05 +02:00
|
|
|
src/common/testsupport.h \
|
2012-08-02 15:31:43 +02:00
|
|
|
src/common/torgzip.h \
|
|
|
|
src/common/torint.h \
|
|
|
|
src/common/torlog.h \
|
|
|
|
src/common/tortls.h \
|
2014-05-13 03:23:34 +02:00
|
|
|
src/common/util.h \
|
2014-06-14 17:46:38 +02:00
|
|
|
src/common/util_process.h \
|
2013-09-23 07:19:16 +02:00
|
|
|
src/common/workqueue.h \
|
2014-05-13 03:23:34 +02:00
|
|
|
$(libor_mempool_header)
|
2012-08-02 15:31:43 +02:00
|
|
|
|
2012-09-06 15:56:48 +02:00
|
|
|
noinst_HEADERS+= $(COMMONHEADERS)
|
|
|
|
|
2012-08-03 03:20:52 +02:00
|
|
|
DISTCLEANFILES+= src/common/common_sha1.i
|
|
|
|
|
2012-09-06 15:56:48 +02:00
|
|
|
src/common/common_sha1.i: $(libor_SOURCES) $(libor_crypto_a_SOURCES) $(COMMONHEADERS)
|
2012-08-23 19:14:41 +02:00
|
|
|
$(AM_V_GEN)if test "@SHA1SUM@" != none; then \
|
2012-09-06 15:56:48 +02:00
|
|
|
(cd "$(srcdir)" && "@SHA1SUM@" $(src_common_libor_SOURCES) $(src_common_libor_crypto_a_SOURCES) $(COMMONHEADERS)) | "@SED@" -n 's/^\(.*\)$$/"\1\\n"/p' > $@; \
|
2012-08-02 15:31:43 +02:00
|
|
|
elif test "@OPENSSL@" != none; then \
|
2012-09-06 15:56:48 +02:00
|
|
|
(cd "$(srcdir)" && "@OPENSSL@" sha1 $(src_common_libor_SOURCES) $(src_Common_libor_crypto_a_SOURCES) $(COMMONHEADERS)) | "@SED@" -n 's/SHA1(\(.*\))= \(.*\)/"\2 \1\\n"/p' > $@; \
|
2012-08-02 15:31:43 +02:00
|
|
|
else \
|
2012-08-03 03:20:52 +02:00
|
|
|
rm $@; \
|
|
|
|
touch $@; \
|
2012-08-02 15:31:43 +02:00
|
|
|
fi
|
|
|
|
|
2012-08-03 03:20:52 +02:00
|
|
|
src/common/util_codedigest.o: src/common/common_sha1.i
|
2012-09-13 01:25:58 +02:00
|
|
|
|