forked from premiere/premiere-libtorrent
solaris fixes
This commit is contained in:
parent
864da49dd6
commit
bc1e47a486
5
Jamfile
5
Jamfile
|
@ -171,8 +171,10 @@ rule linking ( properties * )
|
|||
{
|
||||
# on mac the boost headers are installed in
|
||||
# a directory that isn't automatically accessable
|
||||
# on open indiana, boost is install at /usr/g++/include
|
||||
result += <include>/opt/local/include/boost-1_35
|
||||
<include>/opt/local/include
|
||||
<include>/usr/g++/include
|
||||
;
|
||||
}
|
||||
|
||||
|
@ -353,10 +355,13 @@ local boost-library-search-path =
|
|||
<search>/usr/lib
|
||||
<search>/usr/local/lib
|
||||
<search>/sw/lib
|
||||
<search>/usr/g++/lib
|
||||
;
|
||||
|
||||
lib boost_system : : <target-os>darwin <name>boost_system-mt $(boost-library-search-path) ;
|
||||
|
||||
lib boost_system : : <target-os>solaris <name>boost_system $(boost-library-search-path) ;
|
||||
|
||||
lib boost_system : : <name>boost_system ;
|
||||
|
||||
# openssl on linux/bsd/macos etc.
|
||||
|
|
|
@ -197,6 +197,7 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
#define TORRENT_SOLARIS
|
||||
#define TORRENT_COMPLETE_TYPES_REQUIRED 1
|
||||
#define TORRENT_USE_IFCONF 1
|
||||
#define TORRENT_HAS_SALEN 0
|
||||
|
||||
// ==== BEOS ===
|
||||
#elif defined __BEOS__ || defined __HAIKU__
|
||||
|
|
|
@ -166,11 +166,7 @@ namespace libtorrent
|
|||
disk_buffer_pool* disk_pool() { return m_disk_pool; }
|
||||
session_settings const& settings() const { return *m_settings; }
|
||||
|
||||
void set_error(std::string const& file, error_code const& ec) const
|
||||
{
|
||||
m_error_file = file;
|
||||
m_error = ec;
|
||||
}
|
||||
void set_error(std::string const& file, error_code const& ec) const;
|
||||
|
||||
error_code const& error() const { return m_error; }
|
||||
std::string const& error_file() const { return m_error_file; }
|
||||
|
|
|
@ -211,6 +211,10 @@ namespace libtorrent
|
|||
void create_directories(std::string const& f, error_code& ec)
|
||||
{
|
||||
ec.clear();
|
||||
if (is_directory(f, ec)) return;
|
||||
if (ec != boost::system::errc::no_such_file_or_directory)
|
||||
return;
|
||||
ec.clear();
|
||||
if (is_root_path(f)) return;
|
||||
if (has_parent_path(f))
|
||||
{
|
||||
|
@ -1758,6 +1762,7 @@ typedef struct _FILE_ALLOCATED_RANGE_BUFFER {
|
|||
// this is supported on solaris
|
||||
size_type ret = lseek(m_fd, start, SEEK_DATA);
|
||||
if (ret < 0) return start;
|
||||
return start;
|
||||
#else
|
||||
return start;
|
||||
#endif
|
||||
|
|
|
@ -246,6 +246,12 @@ namespace libtorrent
|
|||
return true;
|
||||
}
|
||||
|
||||
void storage_interface::set_error(std::string const& file, error_code const& ec) const
|
||||
{
|
||||
m_error_file = file;
|
||||
m_error = ec;
|
||||
}
|
||||
|
||||
// for backwards compatibility, let the default readv and
|
||||
// writev implementations be implemented in terms of the
|
||||
// old read and write
|
||||
|
|
Loading…
Reference in New Issue