Compilation environment fixes to make make install work correctly.
[crypto.git] / lib / silcmath / Makefile.ad
index a65c9d88f9dceb8e777f30e090eb39172868001e..3f589eb051883b4ae647421d44e5cabe49b756a5 100644 (file)
@@ -3,7 +3,7 @@
 #
 #  Author: Pekka Riikonen <priikone@silcnet.org>
 #
-#  Copyright (C) 2000 - 2005 Pekka Riikonen
+#  Copyright (C) 2000 - 2008 Pekka Riikonen
 #
 #  This program is free software; you can redistribute it and/or modify
 #  it under the terms of the GNU General Public License as published by
 
 AUTOMAKE_OPTIONS = 1.0 no-dependencies foreign
 
-if SILC_MP_NSS_MPI
-SUBDIRS = mpi
-else
-SUBDIRS =
-endif
-
-DIST_SUBDIRS = mpi
+SUBDIRS=tests
 
 noinst_LTLIBRARIES = libsilcmath.la
 
-if SILC_MP_NSS_MPI
-MP_SOURCE = mp_mpi.c
+if SILC_MP_SILCMATH
+MP_HEADER =                    \
+#ifdef SILC_DIST_TMA
+       mp_tma.h                \
+       tma.h                   \
+       tma_class.h             \
+       tma_superclass.h        \
+#endif SILC_DIST_TMA
+#ifdef SILC_DIST_TFM
+       mp_tfm.h                \
+       tfm.h
+#endif SILC_DIST_TFM
+
+MP_SOURCE =                    \
+       silcmp.h                \
+       silcmath.h              \
+       $(MP_HEADER)            \
+#ifdef SILC_DIST_TMA
+       tma.c                   \
+       mp_tma.c                \
+#endif SILC_DIST_TMA
+#ifdef SILC_DIST_TFM
+       tfm.c                   \
+       mp_tfm.c
+#endif SILC_DIST_TFM
+
+AM_CFLAGS = @MATH_CFLAGS@
 else
 MP_SOURCE = mp_gmp.c
+MP_HEADER =
 endif
 
-libsilcmath_la_SOURCES = \
-       silcprimegen.c \
-       modinv.c \
-       mpbin.c \
-       $(MP_SOURCE)
+libsilcmath_la_SOURCES =       \
+       $(MP_SOURCE)            \
+       silcprimegen.c          \
+#ifndef SILC_DIST_TFM
+       modinv.c                \
+#endif SILC_DIST_TFM
+       mpbin.c
 
-#ifdef SILC_DIST_TOOLKIT
-MP_HEADER = mpi/mpi.h mpi/mplogic.h mpi/mpi-config.h
 include_HEADERS =      \
        mp_gmp.h        \
-       mp_mpi.h        \
+       $(MP_HEADER)    \
        silcmath.h      \
-       silcmp.h        \
-       $(MP_HEADER)
-#endif SILC_DIST_TOOLKIT
+       silcmp.h
 
-EXTRA_DIST = mp_gmp.c mp_mpi.c *.h
+EXTRA_DIST = $(MP_SOURCE) mp_gmp.c mp_gmp.h
 
 include $(top_srcdir)/Makefile.defines.in