diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2011-08-11 02:24:42 +0900 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2011-08-11 02:29:14 +0900 |
| commit | e76dc28f7fc26e994a1f3ddf1f665035fcb690e3 (patch) | |
| tree | bac09b2f880783f0b7bef90c8db14d20a8df7686 /src/Platform.cc | |
| parent | 11ac2c4a8885480b64610089ab0da1c4478e6815 (diff) | |
Added libnettle and libgmp support.
libnettle and libgmp is used by default. Old implementation uses
libgcrypt as default. If more and more Linux distributions offer
libnettle linked GnuTLS, then this change decrease library dependency
against libgcrypt and libgpg-error. The current library detection for
libnettle and libgmp is very simple, just use AC_SEARCH_LIBS.
util::generateRandomData() was written using SimpleRandomizer, thus no
external library dependency from this function.
Diffstat (limited to 'src/Platform.cc')
| -rw-r--r-- | src/Platform.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/Platform.cc b/src/Platform.cc index 0e5bc416..ebfe7a6f 100644 --- a/src/Platform.cc +++ b/src/Platform.cc @@ -73,6 +73,9 @@ #include "message.h" #include "fmt.h" #include "console.h" +#ifdef HAVE_LIBGMP +# include "a2gmp.h" +#endif // HAVE_LIBGMP namespace aria2 { @@ -94,7 +97,9 @@ bool Platform::setUp() return false; } initialized_ = true; - +#ifdef HAVE_LIBGMP + global::initGmp(); +#endif // HAVE_LIBGMP #ifdef ENABLE_NLS setlocale (LC_CTYPE, ""); setlocale (LC_MESSAGES, ""); |
