As MacPorts is rather unhappy with Xcode 4.3 (understandably, with all those changed paths), I invested a fair amount of effort to get it recompile rTorrent (which I’d been running in a screen-session on my Mac mini). I got it work (xcode-select + setting the Developer-folder in /opt/local/etc/macports.conf to either “/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain” or “/”), but while searching around, I also came across Transmission‘s headless daemon and web-interface.
So, here’s how I built and configured the headless daemon on OS X (with Xcode 4.3):
- Get the source-package, e.g. transmission-2.50.tar.bz2
- Copy the source of libevent2 into “third-party/libevent” (“mv ../libevent-2.0.17-stable third-party/libevent” inside the Transmission-directory).
- Build via “xcodebuild -project Transmission.xcodeproj -target transmission-daemon -configuration Release”.
- Run the daemon so it creates its initial config in “~/Library/Application Support/transmission-daemon”.
- Edit the configuration in settings.json (whitelist, watchdir, ports, speeds, …).
- If you want to use the web-interface, copy its files: “cp -R web ~/Library/Application Support/transmission-daemon/”
- Re-start the daemon.
This worked well for me and I’m quite impressed with both the web-interface and Transmission itself.
Hello, Im trying to build it into OSX too, but having the following problem:
Undefined symbols for architecture x86_64:
“_libiconv_open”, referenced from:
_tr_utf8clean in libtransmission.a(utils.o)
“_libiconv”, referenced from:
_tr_utf8clean in libtransmission.a(utils.o)
“_libiconv_close”, referenced from:
_tr_utf8clean in libtransmission.a(utils.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Any suggestion?
Thanks
I just added
ARCHS=i386 ONLY_ACTIVE_ARCH=NO
at the end of the xcodebuild args and things worked as expected.
=)
And just to complement,
to use the web you should copy it to
“cp -R web ~/Library/Application Support/transmission-daemon/web”
All you need to do is install command line tools via Preferences -> Downloads -> Components. There’s no need to much with paths.
Works in pkgsrc on x64/Mountain Lion if you edit the ./configure file and just remove the lines around 19900 that quit if no MacOSX10.5 SDK. It fails the build … but daemon, cli and remote are all functional and can be taken from their folders manually.
Transmission is available on homebrew. No MacPorts hassle.