forked from premiere/premiere-libtorrent
fixed DLL link issues
This commit is contained in:
parent
5b039a8982
commit
3fb05a13b1
|
@ -40,7 +40,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
namespace libtorrent {
|
||||
|
||||
// member of peer_connection
|
||||
struct bandwidth_channel
|
||||
struct TORRENT_EXPORT bandwidth_channel
|
||||
{
|
||||
static const int inf = boost::integer_traits<int>::const_max;
|
||||
|
||||
|
|
|
@ -54,7 +54,7 @@ using boost::intrusive_ptr;
|
|||
|
||||
namespace libtorrent {
|
||||
|
||||
struct bandwidth_manager
|
||||
struct TORRENT_EXPORT bandwidth_manager
|
||||
{
|
||||
bandwidth_manager(int channel
|
||||
#ifdef TORRENT_VERBOSE_BANDWIDTH_LIMIT
|
||||
|
|
|
@ -39,7 +39,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
namespace libtorrent {
|
||||
|
||||
struct bw_request
|
||||
struct TORRENT_EXPORT bw_request
|
||||
{
|
||||
bw_request(boost::intrusive_ptr<bandwidth_socket> const& pe
|
||||
, int blk, int prio);
|
||||
|
|
|
@ -48,7 +48,7 @@ namespace libtorrent
|
|||
{
|
||||
struct torrent_plugin;
|
||||
class torrent;
|
||||
TORRENT_EXPORT boost::shared_ptr<torrent_plugin> create_lt_trackers_plugin(torrent*, void*);
|
||||
boost::shared_ptr<torrent_plugin> TORRENT_EXPORT create_lt_trackers_plugin(torrent*, void*);
|
||||
}
|
||||
|
||||
#endif // TORRENT_LT_TRACKERS_HPP_INCLUDED
|
||||
|
|
|
@ -129,12 +129,7 @@ namespace libtorrent
|
|||
char const* time_now_string();
|
||||
std::string TORRENT_EXPORT log_time();
|
||||
|
||||
namespace aux
|
||||
{
|
||||
extern TORRENT_EXPORT ptime g_current_time;
|
||||
}
|
||||
|
||||
inline ptime const& time_now() { return aux::g_current_time; }
|
||||
ptime const& TORRENT_EXPORT time_now();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -339,7 +339,7 @@ namespace libtorrent { namespace
|
|||
namespace libtorrent
|
||||
{
|
||||
|
||||
boost::shared_ptr<torrent_plugin> create_lt_trackers_plugin(torrent* t, void*)
|
||||
boost::shared_ptr<torrent_plugin> TORRENT_EXPORT create_lt_trackers_plugin(torrent* t, void*)
|
||||
{
|
||||
if (t->valid_metadata() && t->torrent_file().priv()) return boost::shared_ptr<torrent_plugin>();
|
||||
return boost::shared_ptr<torrent_plugin>(new lt_tracker_plugin(*t));
|
||||
|
|
|
@ -163,13 +163,6 @@ namespace detail
|
|||
|
||||
namespace aux {
|
||||
|
||||
// used to cache the current time
|
||||
// every 100 ms. This is cheaper
|
||||
// than a system call and can be
|
||||
// used where more accurate time
|
||||
// is not necessary
|
||||
TORRENT_EXPORT ptime g_current_time = time_now_hires();
|
||||
|
||||
struct seed_random_generator
|
||||
{
|
||||
seed_random_generator()
|
||||
|
@ -1275,6 +1268,13 @@ namespace aux {
|
|||
}
|
||||
}
|
||||
|
||||
// used to cache the current time
|
||||
// every 100 ms. This is cheaper
|
||||
// than a system call and can be
|
||||
// used where more accurate time
|
||||
// is not necessary
|
||||
extern ptime g_current_time;
|
||||
|
||||
void session_impl::on_tick(error_code const& e)
|
||||
{
|
||||
mutex::scoped_lock l(m_mutex);
|
||||
|
|
12
src/time.cpp
12
src/time.cpp
|
@ -44,6 +44,18 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
|
||||
namespace libtorrent
|
||||
{
|
||||
namespace aux
|
||||
{
|
||||
// used to cache the current time
|
||||
// every 100 ms. This is cheaper
|
||||
// than a system call and can be
|
||||
// used where more accurate time
|
||||
// is not necessary
|
||||
ptime g_current_time;
|
||||
}
|
||||
|
||||
ptime const& TORRENT_EXPORT time_now() { return aux::g_current_time; }
|
||||
|
||||
char const* time_now_string()
|
||||
{
|
||||
time_t t = std::time(0);
|
||||
|
|
12
test/Jamfile
12
test/Jamfile
|
@ -1,15 +1,5 @@
|
|||
use-project /torrent : .. ;
|
||||
|
||||
lib test_common
|
||||
:
|
||||
setup_transfer.cpp
|
||||
:
|
||||
<library>/torrent//torrent
|
||||
<threading>multi
|
||||
:
|
||||
<threading>multi
|
||||
;
|
||||
|
||||
exe test_natpmp : test_natpmp.cpp /torrent//torrent
|
||||
: <threading>multi <debug-iterators>on <invariant-checks>full ;
|
||||
|
||||
|
@ -17,9 +7,9 @@ explicit test_natpmp ;
|
|||
|
||||
project
|
||||
: requirements
|
||||
<library>test_common
|
||||
<library>/torrent//torrent
|
||||
<source>main.cpp
|
||||
<source>setup_transfer.cpp
|
||||
: default-build
|
||||
<threading>multi
|
||||
<invariant-checks>full
|
||||
|
|
Loading…
Reference in New Issue