I used the patches from openembedded project for ctorrent. I used these two patches: http://openembedded.bkbits.net:8080/openembedded/patch@1.2787.114.1 http://openembedded.bkbits.net:8080/openembedded/patch@1.2787.53.164 I attach a uclib.patch file.
Created attachment 63343 [details, diff] ctorrent for uclic fix
Created attachment 63384 [details, diff] getcwd fix Only with this patch, the ctorrent compile with uclibc. From http://openembedded.bkbits.net:8080/openembedded/patch@1.2787.114.1 : "Apply a patch to ctorrent to make it use getcwd rather than getwd (getwd is deprecated for portability and security reasons), which fixes its build for uclibc."
If it still doesn't work, we need a patch for net-p2p/ctorrent-3.1; this one got totally obsolete. Sorry. :/
FYI.. this seems to compile fine under uClibc. uClibc portage # ctorrent Enhanced CTorrent dnh3.1 Original code Copyright: YuHong(992126018601033) WARNING: THERE IS NO WARRANTY FOR CTorrent. USE AT YOUR OWN RISK!!! General Options: -h/-H Show this message -x Decode metainfo (torrent) file only, don't download -c Check pieces only, don't download -v Verbose output (for debugging) Download Options: -e int Exit while seed <int> hours later (default 72 hours) -E num Exit after seeding to <num> ratio (UL:DL) -i ip Listen for connections on specific IP address (default all/any) -p port Listen port (default 2706 -> 2106) -s filename Download ("save as") to a different file or directory -C cache_size Cache size, unit MB (default 16MB) -f Force saved bitfield or seed mode (skip initial hash check) -b filename Specify bitfield save file (default is torrent+".bf") -M max_peers Max peers count (default 100) -m min_peers Min peers count (default 1) -z slice_size Download slice/block size, unit KB (default 16, max 128) -n file_list Specify file number(s) to download -D rate Max bandwidth down (unit KB/s) -U rate Max bandwidth up (unit KB/s) -P peer_id Set Peer ID prefix (default "-CD0301-") -A user_agent Set User-Agent header (default "Enhanced-CTorrent/dnh3.1") -S host:port Use CTCS server at host:port -a Preallocate files on disk -T Convert foreign filenames to printable text -X command Run command upon download completion ("user exit") -d Daemon mode (fork to background) Make metainfo (torrent) file options: -t Create a new torrent file -u url Tracker's url -l piece_len Piece length (default 262144) -s filename Specify metainfo file name Example: ctorrent -s new_filename -e 12 -C 32 -p 6881 example.torrent home page: http://ctorrent.sourceforge.net/ see also: http://www.rahul.net/dholmes/ctorrent/ bug report: dholmes@ct.boxmail.com original author: bsdi@sina.com uClibc portage # ldd `which ctorrent` libssl.so.0.9.8 => /usr/lib/libssl.so.0.9.8 (0x4a7f2000) libstdc++.so.6 => /usr/lib/gcc/i386-gentoo-linux-uclibc/3.4.6/libstdc++.so.6 (0x4a749000) libm.so.0 => /lib/libm.so.0 (0x4a735000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4a72c000) libc.so.0 => /lib/libc.so.0 (0x4a6e0000) libcrypto.so.0.9.8 => /usr/lib/libcrypto.so.0.9.8 (0x4a5c8000) libdl.so.0 => /lib/libdl.so.0 (0x4a5c4000) ld-uClibc.so.0 => /lib/ld-uClibc.so.0 (0x4a833000) uClibc portage # qlist -Uv ctorrent net-p2p/ctorrent-3.1
Looks like upstream fixed it already. uClibc portage # scanelf -Bs getwd `which ctorrent` ET_DYN - /usr/bin/ctorrent uClibc portage # scanelf -Bs getcwd `which ctorrent` ET_DYN getcwd /usr/bin/ctorrent