Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rTorrent via Cygwin #163

Closed
shaybracha opened this issue Nov 7, 2013 · 8 comments
Closed

rTorrent via Cygwin #163

shaybracha opened this issue Nov 7, 2013 · 8 comments

Comments

@shaybracha
Copy link

Hi
i'm new with rTorrent and would like to know if there is user guide step by step installing and use rTorrent.
some user manual from http://rtwi.jmk.hu/wiki/rTorrentOnWindows#libsigc
got compile error
Thanks

@malwinmp
Copy link

Hello shaybracha,

What error do you get, could you be more specific? Maybe you're missing dependencies or you've got missconfigured compilator paths. I've just compiled latest libtorrent and rtorrent under latest cygwin on windows 7 and it seems to work.

Edit: if you get an error like this :

directory.cc: In member function ‘bool utils::Directory::update(int)’:
directory.cc:93:28: error: ‘struct dirent’ has no member named ‘d_reclen’
itr->d_reclen = entry->d_reclen;

Find directory.cc file, it is in rtorrent\src\utils. Open it with text editor and alter line :

    itr->d_reclen = entry->d_reclen;

to :

itr->d_reclen = __builtin_offsetof (struct dirent, d_name) + strlen (entry->d_name) + 1;

and ofc strlen requires including cstring

Haven't much time tonight, so I compiled rtorrent without xmlrpc support (I didn't find xmlrpc-c packages in cygwin manager or I'm blind) so if you want it you have to compile xmlrpc from sources as well.

@AbrahamAriel
Copy link

Hello malwinMP, I tried your fix but as expected, it doesn't work as strlen isn't defined. I don't know how to go about that and still can't get rtorrent to build. I thought it was because of XMLRPC-C but even without XMLRPC-C, rtorrent still refuses to build due to the same error.

I tried the patch mentioned here: http://rtwi.jmk.hu/wiki/rTorrentOnWindows#rtorrent
But it doesn't work either. It was my last resort as it's a very outdated patch and I think the current trunk must have had it already since the seemed really old.

@malwinmp
Copy link

If compiler says it's not defined then you're probably forgot to include string.h header. strlen function is defined in string.h.

@AbrahamAriel
Copy link

Ah, I see. Thank you very much, malwinMP. I got it built without any problems after that. Is there any reason why this isn't done in the codebase in the first place? Is it because this is a Cygwin or Windows only problem?

@noahrooney
Copy link

malwinMP,

I made the change you suggested to directory.cc but I don't know what you mean by "If compiler says it's not defined then you're probably forgot to include string.h header. strlen function is defined in string.h."

Please assist, thank you!

@Drake008
Copy link

Drake008 commented Mar 9, 2015

So I changed the itr but then I do not know where this (ofc strlen requires including cstring) is.
Maybe someone can clear that out for me.


directory.cc: In member function 'bool utils::Directory::update(int)':
directory.cc:91:28: error: 'struct dirent' has no member named 'd_reclen'
itr->d_reclen = entry->d_reclen;
^
Makefile:399: recipe for target 'directory.o' failed
make[3]: *** [directory.o] Error 1
make[3]: Leaving directory '/usr/local/src/rtorrent/src/utils'
Makefile:602: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/usr/local/src/rtorrent/src'
Makefile:438: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/usr/local/src/rtorrent'
Makefile:369: recipe for target 'all' failed

make: *** [all] Error 2

@JoeyNJ
Copy link

JoeyNJ commented Mar 12, 2015

Add this line on top of directory.cc
#include <string.h>

@ghudiczius
Copy link

Hi,

Give a try to my fork of libTorrent and rTorrent and see the updated compilation manual on how to install rTorrent on Windows

Regards,
Gabor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants