mirror of
https://github.com/transmission/transmission.git
synced 2025-12-24 20:35:36 +00:00
(trunk) #3949 "Add --enable-lightweight argument to configure" -- fixed.
TR_EMBEDDED has been around for awhile, but few (any?) repackagers are aware of it. If it was "advertised" through a configure-time argument, and in the status messages at the end of the configure script, more repackagers would be aware of it.
This commit is contained in:
12
configure.ac
12
configure.ac
@@ -406,6 +406,14 @@ case $host_os in
|
||||
|
||||
esac
|
||||
|
||||
AC_ARG_ENABLE([lightweight],
|
||||
AS_HELP_STRING([--enable-lightweight],[optimize libtransmission for low-resource systems: smaller cache size, prefer unencrypted peer connections, etc.]),
|
||||
[enable_lightweight=${enableval}],
|
||||
[enable_lightweight="no"])
|
||||
if test "x$enable_lightweight" = "xyes" ; then
|
||||
AC_DEFINE([TR_LIGHTWEIGHT],[1],[optimize libtransmission for low-resource systems])
|
||||
fi
|
||||
|
||||
AC_ARG_ENABLE([cli],
|
||||
[AS_HELP_STRING([--enable-cli],[build command-line client])],
|
||||
[build_cli=${enableval}],
|
||||
@@ -485,6 +493,10 @@ Configuration:
|
||||
Source code location: ${srcdir}
|
||||
Compiler: ${CXX}
|
||||
|
||||
Build libtransmission: yes
|
||||
|
||||
* optimized for low-resource systems: ${enable_lightweight}
|
||||
|
||||
Build Command-Line client: ${build_cli}
|
||||
|
||||
Build GTK+ client: ${build_gtk}
|
||||
|
||||
@@ -363,7 +363,7 @@ add_response( struct evhttp_request * req, struct tr_rpc_server * server,
|
||||
|
||||
/* zlib's manual says: "Add 16 to windowBits to write a simple gzip header
|
||||
* and trailer around the compressed data instead of a zlib wrapper." */
|
||||
#ifdef TR_EMBEDDED
|
||||
#ifdef TR_LIGHTWEIGHT
|
||||
compressionLevel = Z_DEFAULT_COMPRESSION;
|
||||
#else
|
||||
compressionLevel = Z_BEST_COMPRESSION;
|
||||
|
||||
@@ -55,7 +55,11 @@ enum
|
||||
{
|
||||
SAVE_INTERVAL_SECS = 360,
|
||||
|
||||
#ifdef TR_LIGHTWEIGHT
|
||||
DEFAULT_CACHE_SIZE_MB = 2
|
||||
#else
|
||||
DEFAULT_CACHE_SIZE_MB = 4
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
@@ -251,7 +255,7 @@ tr_sessionGetPublicAddress( const tr_session * session, int tr_af_type, tr_bool
|
||||
****
|
||||
***/
|
||||
|
||||
#ifdef TR_EMBEDDED
|
||||
#ifdef TR_LIGHTWEIGHT
|
||||
#define TR_DEFAULT_ENCRYPTION TR_CLEAR_PREFERRED
|
||||
#else
|
||||
#define TR_DEFAULT_ENCRYPTION TR_ENCRYPTION_PREFERRED
|
||||
|
||||
@@ -101,7 +101,7 @@ const char * tr_strip_positional_args( const char * fmt );
|
||||
|
||||
/* #define DISABLE_GETTEXT */
|
||||
#ifndef DISABLE_GETTEXT
|
||||
#if defined(WIN32) || defined(TR_EMBEDDED)
|
||||
#if defined(WIN32) || defined(TR_LIGHTWEIGHT)
|
||||
#define DISABLE_GETTEXT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user