Error when compiling transmission on Windows

Ask for help and report issues with the Windows version of Transmission
Post Reply
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Error when compiling transmission on Windows

Post by MehranNZ »

hey folks
i really have to compile the transmission for windows(i have changed the code and want to test it on windows so i can't use binary files)
i used this instruction
http://trqtw.sourceforge.net/blog/trans ... vironment/
everything went smooth until the end when i entered "make" it gave me this error
i'm on mint 13 (ubuntu 12.04) can somebody plz help me?!

Code: Select all

make
CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run aclocal-1.11 -I m4
 cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run automake-1.11 --gnu
CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run autoconf
/bin/bash ./config.status --recheck
running CONFIG_SHELL=/bin/bash /bin/bash ./configure --host=i686-pc-mingw32 --prefix=/home/mehran/mingw/usr/i686-pc-mingw32 --enable-daemon --disable-cli --without-gtk --enable-utp CFLAGS=-pipe -DSTATICLIB LIBEVENT_LIBS=-levent -lws2_32 host_alias=i686-pc-mingw32 --no-create --no-recursion
configure: WARNING: if you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used
checking whether make supports nested variables... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for i686-pc-mingw32-strip... i686-pc-mingw32-strip
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking how to create a pax tar archive... gnutar
checking build system type... x86_64-unknown-linux-gnu
checking host system type... i686-pc-mingw32
checking how to print strings... printf
checking for style of include used by make... GNU
checking for i686-pc-mingw32-gcc... i686-pc-mingw32-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether i686-pc-mingw32-gcc accepts -g... yes
checking for i686-pc-mingw32-gcc option to accept ISO C89... none needed
checking dependency style of i686-pc-mingw32-gcc... gcc3
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by i686-pc-mingw32-gcc... /opt/mxe/usr/i686-pc-mingw32/bin/ld
checking if the linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /opt/mxe/usr/bin/i686-pc-mingw32-nm -B
checking the name lister (/opt/mxe/usr/bin/i686-pc-mingw32-nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 3458764513820540925
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to i686-pc-mingw32 format... func_convert_file_nix_to_w32
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /opt/mxe/usr/i686-pc-mingw32/bin/ld option to reload object files... -r
checking for i686-pc-mingw32-objdump... i686-pc-mingw32-objdump
checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
checking for i686-pc-mingw32-dlltool... i686-pc-mingw32-dlltool
checking how to associate runtime and link libraries... func_cygming_dll_for_implib
checking for i686-pc-mingw32-ar... i686-pc-mingw32-ar
checking for archiver @FILE support... @
checking for i686-pc-mingw32-strip... (cached) i686-pc-mingw32-strip
checking for i686-pc-mingw32-ranlib... i686-pc-mingw32-ranlib
checking command to parse /opt/mxe/usr/bin/i686-pc-mingw32-nm -B output from i686-pc-mingw32-gcc object... ok
checking for sysroot... no
checking for i686-pc-mingw32-mt... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... i686-pc-mingw32-gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... no
checking for objdir... .libs
checking if i686-pc-mingw32-gcc supports -fno-rtti -fno-exceptions... no
checking for i686-pc-mingw32-gcc option to produce PIC... -DDLL_EXPORT -DPIC
checking if i686-pc-mingw32-gcc PIC flag -DDLL_EXPORT -DPIC works... yes
checking if i686-pc-mingw32-gcc static flag -static works... yes
checking if i686-pc-mingw32-gcc supports -c -o file.o... yes
checking if i686-pc-mingw32-gcc supports -c -o file.o... (cached) yes
checking whether the i686-pc-mingw32-gcc linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for i686-pc-mingw32-gcc... (cached) i686-pc-mingw32-gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether i686-pc-mingw32-gcc accepts -g... (cached) yes
checking for i686-pc-mingw32-gcc option to accept ISO C89... (cached) none needed
checking dependency style of i686-pc-mingw32-gcc... (cached) gcc3
checking for i686-pc-mingw32-g++... i686-pc-mingw32-g++
checking whether we are using the GNU C++ compiler... yes
checking whether i686-pc-mingw32-g++ accepts -g... yes
checking dependency style of i686-pc-mingw32-g++... gcc3
checking how to run the C++ preprocessor... i686-pc-mingw32-g++ -E
checking for ld used by i686-pc-mingw32-g++... /opt/mxe/usr/i686-pc-mingw32/bin/ld
checking if the linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) is GNU ld... yes
checking whether the i686-pc-mingw32-g++ linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking for i686-pc-mingw32-g++ option to produce PIC... -DDLL_EXPORT -DPIC
checking if i686-pc-mingw32-g++ PIC flag -DDLL_EXPORT -DPIC works... yes
checking if i686-pc-mingw32-g++ static flag -static works... yes
checking if i686-pc-mingw32-g++ supports -c -o file.o... yes
checking if i686-pc-mingw32-g++ supports -c -o file.o... (cached) yes
checking whether the i686-pc-mingw32-g++ linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking for i686-pc-mingw32-g++... yes
checking for inline... inline
checking gcc version... 4.7.0
checking for ANSI C header files... (cached) yes
checking whether time.h and sys/time.h may both be included... yes
checking stdbool.h usability... yes
checking stdbool.h presence... yes
checking for stdbool.h... yes
checking for iconv_open... no
checking for pread... no
checking for pwrite... no
checking for lrintf... yes
checking for strlcpy... no
checking for daemon... no
checking for dirname... yes
checking for basename... yes
checking for strcasecmp... yes
checking for localtime_r... no
checking for fallocate64... no
checking for posix_fallocate... no
checking for memmem... no
checking for strsep... no
checking for strtold... yes
checking for syslog... no
checking for valloc... no
checking for getpagesize... yes
checking for posix_memalign... no
checking for statvfs... no
checking for htonll... no
checking for ntohll... no
checking for mkdtemp... no
checking whether make sets $(MAKE)... (cached) yes
checking for the pthreads library -lpthreads... no
checking whether pthreads work without any flags... no
checking whether pthreads work with -Kthread... no
checking whether pthreads work with -kthread... no
checking for the pthreads library -llthread... no
checking whether pthreads work with -pthread... no
checking whether pthreads work with -pthreads... no
checking whether pthreads work with -mthreads... no
checking for the pthreads library -lpthread... no
checking whether pthreads work with --thread-safe... no
checking whether pthreads work with -mt... no
checking for pthread-config... no
checking for library containing cos... none required
checking for library containing socket... no
checking for library containing gethostbyname... no
checking for i686-pc-mingw32-pkg-config... /opt/mxe/usr/bin/i686-pc-mingw32-pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for OPENSSL... yes
checking for LIBCURL... yes
checking for LIBEVENT... yes
checking for /tmp/dummy1_zlib.h... yes
checking for library containing gzopen... -lz
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... unknown
checking for _LARGE_FILES value needed for large files... unknown
checking for lseek64... yes
checking whether posix_fadvise is declared... no
checking for posix_fadvise... no
checking sys/inotify.h usability... no
checking sys/inotify.h presence... no
checking for sys/inotify.h... no
checking sys/event.h usability... no
checking sys/event.h presence... no
checking for sys/event.h... no
checking sys/statvfs.h usability... no
checking sys/statvfs.h presence... no
checking for sys/statvfs.h... no
checking xfs/xfs.h usability... no
checking xfs/xfs.h presence... no
checking for xfs/xfs.h... no
checking how to copy va_list... va_copy
checking for clock_gettime in -lrt... no
checking µTP... yes
checking supported miniupnp library... none
checking whether NLS is requested... yes
checking for intltool >= 0.35.0... 0.50.2 found
checking for intltool-update... /usr/bin/intltool-update
checking for intltool-merge... /usr/bin/intltool-merge
checking for intltool-extract... /usr/bin/intltool-extract
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for perl... /usr/bin/perl
checking for perl >= 5.8.1... 5.14.2
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking for LC_MESSAGES... no
checking for libintl.h... (cached) yes
checking for ngettext in libc... no
checking for bindtextdomain in -lintl... no
checking if -liconv is needed to use gettext... 
checking for ngettext in -lintl... yes
checking for dcgettext in -lintl... yes
checking for bind_textdomain_codeset... yes
checking for msgfmt... (cached) /usr/bin/msgfmt
checking for dcgettext... yes
checking for gmsgfmt... (cached) /usr/bin/msgfmt
checking for xgettext... (cached) /usr/bin/xgettext
checking for i686-pc-mingw32-windres... i686-pc-mingw32-windres
configure: creating ./config.status


Configuration:

   Source code location:                              .
   Compiler:                                          i686-pc-mingw32-g++

   Build libtransmission:                             yes
      * optimized for low-resource systems:           no
      * µTP enabled:                                  yes

   Build Command-Line client:                         no

   Build GTK+ client:                                 no (GTK+ none)
      * libappindicator for an Ubuntu-style tray:     no

   Build Daemon:                                      yes

   Build Mac client:                                  no


 /bin/bash ./config.status
config.status: creating Makefile
config.status: creating transmission-gtk.spec
config.status: creating cli/Makefile
config.status: creating daemon/Makefile
config.status: creating extras/Makefile
config.status: creating libtransmission/Makefile
config.status: creating utils/Makefile
config.status: creating third-party/Makefile
config.status: creating third-party/dht/Makefile
config.status: creating third-party/libutp/Makefile
config.status: creating third-party/libnatpmp/Makefile
config.status: creating third-party/miniupnp/Makefile
config.status: creating macosx/Makefile
config.status: creating gtk/Makefile
config.status: creating gtk/icons/Makefile
config.status: creating qt/config.pri
config.status: creating web/Makefile
config.status: creating web/images/Makefile
config.status: creating web/style/Makefile
config.status: creating web/style/jqueryui/Makefile
config.status: creating web/style/jqueryui/images/Makefile
config.status: creating web/style/transmission/Makefile
config.status: creating web/style/transmission/images/Makefile
config.status: creating web/style/transmission/images/buttons/Makefile
config.status: creating web/javascript/Makefile
config.status: creating web/javascript/jquery/Makefile
config.status: creating po/Makefile.in
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing default-1 commands
config.status: executing po/stamp-it commands
Making all in extras
make[1]: Entering directory `/home/mehran/workspace/temp-tr/extras'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/mehran/workspace/temp-tr/extras'
Making all in third-party
make[1]: Entering directory `/home/mehran/workspace/temp-tr/third-party'
Making all in dht
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/dht'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/dht'
Making all in libnatpmp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/libnatpmp'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/libnatpmp'
Making all in miniupnp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
./updateminiupnpcstrings.sh ./miniupnpcstrings.h.in miniupnpcstrings.h
Detected OS [LinuxMint] version [13]
setting OS_STRING macro value to LinuxMint/13 in miniupnpcstrings.h.
make  all-am
make[3]: Entering directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
  CC     minisoap.o
  CC     miniwget.o
miniwget.c: In function 'getHTTPResponse':
miniwget.c:189:35: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
miniwget.c:226:54: warning: signed and unsigned type in conditional expression [-Wsign-compare]
miniwget.c: In function 'miniwget3':
miniwget.c:343:4: warning: implicit declaration of function 'getnameinfo' [-Wimplicit-function-declaration]
miniwget.c:343:4: warning: nested extern declaration of 'getnameinfo' [-Wnested-externs]
miniwget.c:289:24: warning: unused parameter 'url' [-Wunused-parameter]
  AR     libminiupnp.a
make[3]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
Making all in libutp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/libutp'
  CXX    utp.o
In file included from utp.cpp:3:0:
utp.h:8:0: warning: "WIN32_LEAN_AND_MEAN" redefined [enabled by default]
<command-line>:0:0: note: this is the location of the previous definition
utp.cpp:15:29: fatal error: win32_inet_ntop.h: No such file or directory
compilation terminated.
make[2]: *** [utp.o] Error 1
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/libutp'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/mehran/workspace/temp-tr/third-party'
make: *** [all-recursive] Error 1
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when compiling transmission on Windows

Post by rb07 »

You have to patch the source to be able to compile Transmission-Qt (or the daemon, and tools) in Windows.

Since you are using your own changes then you probably only want to patch in the places that need it for your objective:

The libutp part of the patch is:

Code: Select all

Index: third-party/libutp/Makefile.am
===================================================================
--- third-party/libutp/Makefile.am	(revision 13721)
+++ third-party/libutp/Makefile.am	(working copy)
@@ -1,4 +1,4 @@
-AM_CPPFLAGS = -fno-exceptions -fno-rtti -ansi -DPOSIX
+AM_CPPFLAGS = -fno-exceptions -fno-rtti -DPOSIX
 
 noinst_LIBRARIES = libutp.a
 libutp_a_SOURCES = utp.cpp utp_utils.cpp
Index: third-party/libutp/utp.cpp
===================================================================
--- third-party/libutp/utp.cpp	(revision 13721)
+++ third-party/libutp/utp.cpp	(working copy)
@@ -12,7 +12,9 @@
 #include <limits.h> // for UINT_MAX
 
 #ifdef WIN32
-#include "win32_inet_ntop.h"
+/* libtransmission switched to using libevent's inet_ntop */
+extern const char *evutil_inet_ntop(int, const void *, char *, socklen_t);
+#define inet_ntop(a,b,c,d)     evutil_inet_ntop(a,b,c,d)
 
 // newer versions of MSVC define these in errno.h
 #ifndef ECONNRESET
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

i didn't follow :/
lets forget about the part that i said i changed the code lets do this real simple! imagine that i have downloaded transmission-2.76 and now i want to compile it with your instruction here http://trqtw.sourceforge.net/blog/trans ... vironment/ but i get that error! what exactly should i do next?! plz be more clear and tell me what should i do step by step
tnx
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when compiling transmission on Windows

Post by rb07 »

No, I'm not going to repeat step by step instructions, they are already here: https://trac.transmissionbt.com/wiki/Bu ... nQtWindows, and in the SourceForge pages.

If you don't understand what a "patch" is, then go do some learning.
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

i patched it
1. made a file in /third-party/libutp/patchfile and copied what you wrote there
2.cd to /third-party/libutp/patchfile
3.patch < patchfile
but after make i get this error(sorry SF is not working look for yourself http://sourceforge.net/apps/wordpress/trqtw/ and wiki is kind of outdated even those links are not working anymore ):

Code: Select all

make
CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run aclocal-1.11 -I m4
 cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run automake-1.11 --gnu
CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/mehran/workspace/temp-tr/missing --run autoconf
/bin/bash ./config.status --recheck
running CONFIG_SHELL=/bin/bash /bin/bash ./configure --host=i686-pc-mingw32 --prefix=/home/mehran/mingw/usr/i686-pc-mingw32 --enable-daemon --disable-cli --without-gtk --enable-utp CFLAGS=-pipe -DSTATICLIB LIBEVENT_LIBS=-levent -lws2_32 host_alias=i686-pc-mingw32 --no-create --no-recursion
configure: WARNING: if you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used
checking whether make supports nested variables... yes
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for i686-pc-mingw32-strip... i686-pc-mingw32-strip
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking how to create a pax tar archive... gnutar
checking build system type... x86_64-unknown-linux-gnu
checking host system type... i686-pc-mingw32
checking how to print strings... printf
checking for style of include used by make... GNU
checking for i686-pc-mingw32-gcc... i686-pc-mingw32-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether i686-pc-mingw32-gcc accepts -g... yes
checking for i686-pc-mingw32-gcc option to accept ISO C89... none needed
checking dependency style of i686-pc-mingw32-gcc... gcc3
checking for a sed that does not truncate output... /bin/sed
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for fgrep... /bin/grep -F
checking for ld used by i686-pc-mingw32-gcc... /opt/mxe/usr/i686-pc-mingw32/bin/ld
checking if the linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /opt/mxe/usr/bin/i686-pc-mingw32-nm -B
checking the name lister (/opt/mxe/usr/bin/i686-pc-mingw32-nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 3458764513820540925
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to i686-pc-mingw32 format... func_convert_file_nix_to_w32
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /opt/mxe/usr/i686-pc-mingw32/bin/ld option to reload object files... -r
checking for i686-pc-mingw32-objdump... i686-pc-mingw32-objdump
checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
checking for i686-pc-mingw32-dlltool... i686-pc-mingw32-dlltool
checking how to associate runtime and link libraries... func_cygming_dll_for_implib
checking for i686-pc-mingw32-ar... i686-pc-mingw32-ar
checking for archiver @FILE support... @
checking for i686-pc-mingw32-strip... (cached) i686-pc-mingw32-strip
checking for i686-pc-mingw32-ranlib... i686-pc-mingw32-ranlib
checking command to parse /opt/mxe/usr/bin/i686-pc-mingw32-nm -B output from i686-pc-mingw32-gcc object... ok
checking for sysroot... no
checking for i686-pc-mingw32-mt... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... i686-pc-mingw32-gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... no
checking for objdir... .libs
checking if i686-pc-mingw32-gcc supports -fno-rtti -fno-exceptions... no
checking for i686-pc-mingw32-gcc option to produce PIC... -DDLL_EXPORT -DPIC
checking if i686-pc-mingw32-gcc PIC flag -DDLL_EXPORT -DPIC works... yes
checking if i686-pc-mingw32-gcc static flag -static works... yes
checking if i686-pc-mingw32-gcc supports -c -o file.o... yes
checking if i686-pc-mingw32-gcc supports -c -o file.o... (cached) yes
checking whether the i686-pc-mingw32-gcc linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for i686-pc-mingw32-gcc... (cached) i686-pc-mingw32-gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether i686-pc-mingw32-gcc accepts -g... (cached) yes
checking for i686-pc-mingw32-gcc option to accept ISO C89... (cached) none needed
checking dependency style of i686-pc-mingw32-gcc... (cached) gcc3
checking for i686-pc-mingw32-g++... i686-pc-mingw32-g++
checking whether we are using the GNU C++ compiler... yes
checking whether i686-pc-mingw32-g++ accepts -g... yes
checking dependency style of i686-pc-mingw32-g++... gcc3
checking how to run the C++ preprocessor... i686-pc-mingw32-g++ -E
checking for ld used by i686-pc-mingw32-g++... /opt/mxe/usr/i686-pc-mingw32/bin/ld
checking if the linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) is GNU ld... yes
checking whether the i686-pc-mingw32-g++ linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking for i686-pc-mingw32-g++ option to produce PIC... -DDLL_EXPORT -DPIC
checking if i686-pc-mingw32-g++ PIC flag -DDLL_EXPORT -DPIC works... yes
checking if i686-pc-mingw32-g++ static flag -static works... yes
checking if i686-pc-mingw32-g++ supports -c -o file.o... yes
checking if i686-pc-mingw32-g++ supports -c -o file.o... (cached) yes
checking whether the i686-pc-mingw32-g++ linker (/opt/mxe/usr/i686-pc-mingw32/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking for i686-pc-mingw32-g++... yes
checking for inline... inline
checking gcc version... 4.7.0
checking for ANSI C header files... (cached) yes
checking whether time.h and sys/time.h may both be included... yes
checking stdbool.h usability... yes
checking stdbool.h presence... yes
checking for stdbool.h... yes
checking for iconv_open... no
checking for pread... no
checking for pwrite... no
checking for lrintf... yes
checking for strlcpy... no
checking for daemon... no
checking for dirname... yes
checking for basename... yes
checking for strcasecmp... yes
checking for localtime_r... no
checking for fallocate64... no
checking for posix_fallocate... no
checking for memmem... no
checking for strsep... no
checking for strtold... yes
checking for syslog... no
checking for valloc... no
checking for getpagesize... yes
checking for posix_memalign... no
checking for statvfs... no
checking for htonll... no
checking for ntohll... no
checking for mkdtemp... no
checking whether make sets $(MAKE)... (cached) yes
checking for the pthreads library -lpthreads... no
checking whether pthreads work without any flags... no
checking whether pthreads work with -Kthread... no
checking whether pthreads work with -kthread... no
checking for the pthreads library -llthread... no
checking whether pthreads work with -pthread... no
checking whether pthreads work with -pthreads... no
checking whether pthreads work with -mthreads... no
checking for the pthreads library -lpthread... no
checking whether pthreads work with --thread-safe... no
checking whether pthreads work with -mt... no
checking for pthread-config... no
checking for library containing cos... none required
checking for library containing socket... no
checking for library containing gethostbyname... no
checking for i686-pc-mingw32-pkg-config... /opt/mxe/usr/bin/i686-pc-mingw32-pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for OPENSSL... yes
checking for LIBCURL... yes
checking for LIBEVENT... yes
checking for /tmp/dummy1_zlib.h... yes
checking for library containing gzopen... -lz
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... unknown
checking for _LARGE_FILES value needed for large files... unknown
checking for lseek64... yes
checking whether posix_fadvise is declared... no
checking for posix_fadvise... no
checking sys/inotify.h usability... no
checking sys/inotify.h presence... no
checking for sys/inotify.h... no
checking sys/event.h usability... no
checking sys/event.h presence... no
checking for sys/event.h... no
checking sys/statvfs.h usability... no
checking sys/statvfs.h presence... no
checking for sys/statvfs.h... no
checking xfs/xfs.h usability... no
checking xfs/xfs.h presence... no
checking for xfs/xfs.h... no
checking how to copy va_list... va_copy
checking for clock_gettime in -lrt... no
checking µTP... yes
checking supported miniupnp library... none
checking whether NLS is requested... yes
checking for intltool >= 0.35.0... 0.50.2 found
checking for intltool-update... /usr/bin/intltool-update
checking for intltool-merge... /usr/bin/intltool-merge
checking for intltool-extract... /usr/bin/intltool-extract
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for perl... /usr/bin/perl
checking for perl >= 5.8.1... 5.14.2
checking libintl.h usability... yes
checking libintl.h presence... yes
checking for libintl.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking for LC_MESSAGES... no
checking for libintl.h... (cached) yes
checking for ngettext in libc... no
checking for bindtextdomain in -lintl... no
checking if -liconv is needed to use gettext... 
checking for ngettext in -lintl... yes
checking for dcgettext in -lintl... yes
checking for bind_textdomain_codeset... yes
checking for msgfmt... (cached) /usr/bin/msgfmt
checking for dcgettext... yes
checking for gmsgfmt... (cached) /usr/bin/msgfmt
checking for xgettext... (cached) /usr/bin/xgettext
checking for i686-pc-mingw32-windres... i686-pc-mingw32-windres
configure: creating ./config.status


Configuration:

   Source code location:                              .
   Compiler:                                          i686-pc-mingw32-g++

   Build libtransmission:                             yes
      * optimized for low-resource systems:           no
      * µTP enabled:                                  yes

   Build Command-Line client:                         no

   Build GTK+ client:                                 no (GTK+ none)
      * libappindicator for an Ubuntu-style tray:     no

   Build Daemon:                                      yes

   Build Mac client:                                  no


 /bin/bash ./config.status
config.status: creating Makefile
config.status: creating transmission-gtk.spec
config.status: creating cli/Makefile
config.status: creating daemon/Makefile
config.status: creating extras/Makefile
config.status: creating libtransmission/Makefile
config.status: creating utils/Makefile
config.status: creating third-party/Makefile
config.status: creating third-party/dht/Makefile
config.status: creating third-party/libutp/Makefile
config.status: creating third-party/libnatpmp/Makefile
config.status: creating third-party/miniupnp/Makefile
config.status: creating macosx/Makefile
config.status: creating gtk/Makefile
config.status: creating gtk/icons/Makefile
config.status: creating qt/config.pri
config.status: creating web/Makefile
config.status: creating web/images/Makefile
config.status: creating web/style/Makefile
config.status: creating web/style/jqueryui/Makefile
config.status: creating web/style/jqueryui/images/Makefile
config.status: creating web/style/transmission/Makefile
config.status: creating web/style/transmission/images/Makefile
config.status: creating web/style/transmission/images/buttons/Makefile
config.status: creating web/javascript/Makefile
config.status: creating web/javascript/jquery/Makefile
config.status: creating po/Makefile.in
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing default-1 commands
config.status: executing po/stamp-it commands
Making all in extras
make[1]: Entering directory `/home/mehran/workspace/temp-tr/extras'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/mehran/workspace/temp-tr/extras'
Making all in third-party
make[1]: Entering directory `/home/mehran/workspace/temp-tr/third-party'
Making all in dht
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/dht'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/dht'
Making all in libnatpmp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/libnatpmp'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/libnatpmp'
Making all in miniupnp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
./updateminiupnpcstrings.sh ./miniupnpcstrings.h.in miniupnpcstrings.h
Detected OS [LinuxMint] version [13]
setting OS_STRING macro value to LinuxMint/13 in miniupnpcstrings.h.
make  all-am
make[3]: Entering directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
  CC     minisoap.o
  CC     miniwget.o
miniwget.c: In function 'getHTTPResponse':
miniwget.c:189:35: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
miniwget.c:226:54: warning: signed and unsigned type in conditional expression [-Wsign-compare]
miniwget.c: In function 'miniwget3':
miniwget.c:343:4: warning: implicit declaration of function 'getnameinfo' [-Wimplicit-function-declaration]
miniwget.c:343:4: warning: nested extern declaration of 'getnameinfo' [-Wnested-externs]
miniwget.c:289:24: warning: unused parameter 'url' [-Wunused-parameter]
  AR     libminiupnp.a
make[3]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/miniupnp'
Making all in libutp
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party/libutp'
  CXX    utp.o
In file included from utp.cpp:3:0:
utp.h:8:0: warning: "WIN32_LEAN_AND_MEAN" redefined [enabled by default]
<command-line>:0:0: note: this is the location of the previous definition
In file included from utp.cpp:80:0:
utp_config.h:8:2: warning: #warning implement this in libtransmission [-Wcpp]
  CXX    utp_utils.o
utp_utils.cpp:9:0: warning: "WIN32_LEAN_AND_MEAN" redefined [enabled by default]
<command-line>:0:0: note: this is the location of the previous definition
  AR     libutp.a
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party/libutp'
make[2]: Entering directory `/home/mehran/workspace/temp-tr/third-party'
make[2]: Nothing to be done for `all-am'.
make[2]: Leaving directory `/home/mehran/workspace/temp-tr/third-party'
make[1]: Leaving directory `/home/mehran/workspace/temp-tr/third-party'
Making all in libtransmission
make[1]: Entering directory `/home/mehran/workspace/temp-tr/libtransmission'
  CC     announcer.o
announcer.c: In function 'on_announce_done':
announcer.c:1020:9: warning: unknown conversion type character 'z' in format [-Wformat]
announcer.c:1020:9: warning: unknown conversion type character 'z' in format [-Wformat]
announcer.c:1020:9: warning: format '%s' expects argument of type 'char *', but argument 13 has type 'size_t' [-Wformat]
announcer.c:1020:9: warning: format '%s' expects argument of type 'char *', but argument 14 has type 'size_t' [-Wformat]
announcer.c:1020:9: warning: too many arguments for format [-Wformat-extra-args]
announcer.c: In function 'on_scrape_error':
announcer.c:1263:5: warning: unknown conversion type character 'z' in format [-Wformat]
announcer.c:1263:5: warning: too many arguments for format [-Wformat-extra-args]
announcer.c:1264:5: warning: unknown conversion type character 'z' in format [-Wformat]
announcer.c:1264:5: warning: too many arguments for format [-Wformat-extra-args]
  CC     announcer-http.o
announcer-http.c: In function 'on_announce_done':
announcer-http.c:260:17: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-http.c:260:17: warning: too many arguments for format [-Wformat-extra-args]
announcer-http.c:266:17: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-http.c:266:17: warning: too many arguments for format [-Wformat-extra-args]
announcer-http.c:271:17: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-http.c:271:17: warning: too many arguments for format [-Wformat-extra-args]
  CC     announcer-udp.o
announcer-udp.c: In function 'tau_tracker_upkeep':
announcer-udp.c:689:5: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-udp.c:689:5: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-udp.c:689:5: warning: unknown conversion type character 'z' in format [-Wformat]
announcer-udp.c:689:5: warning: too many arguments for format [-Wformat-extra-args]
  CC     bandwidth.o
bandwidth.c: In function 'tr_bandwidthSetParent':
bandwidth.c:135:16: warning: variable 'removed' set but not used [-Wunused-but-set-variable]
  CC     bencode.o
  CC     bitfield.o
  CC     blocklist.o
blocklist.c: In function 'blocklistClose':
blocklist.c:71:9: warning: implicit declaration of function 'munmap' [-Wimplicit-function-declaration]
blocklist.c:71:9: warning: nested extern declaration of 'munmap' [-Wnested-externs]
blocklist.c: In function 'blocklistLoad':
blocklist.c:101:5: warning: implicit declaration of function 'mmap' [-Wimplicit-function-declaration]
blocklist.c:101:5: warning: nested extern declaration of 'mmap' [-Wnested-externs]
blocklist.c:101:14: warning: assignment makes pointer from integer without a cast [enabled by default]
  CC     cache.o
cache.c: In function 'tr_cacheFlushFile':
cache.c:422:5: warning: unknown conversion type character 'z' in format [-Wformat]
cache.c:422:5: warning: unknown conversion type character 'z' in format [-Wformat]
cache.c:422:5: warning: too many arguments for format [-Wformat-extra-args]
  CC     clients.o
  CC     completion.o
  CC     ConvertUTF.o
  CC     crypto.o
  CC     fdlimit.o
fdlimit.c:40:42: fatal error: sys/resource.h: No such file or directory
compilation terminated.
make[1]: *** [fdlimit.o] Error 1
make[1]: Leaving directory `/home/mehran/workspace/temp-tr/libtransmission'
make: *** [all-recursive] Error 1
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

i went to this link https://trac.transmissionbt.com/ticket/4160 and downloaded that patch file and patched it on both 2.51 and 2.76 i still get the this error:
fdlimit.c:40:42: fatal error: sys/resource.h: No such file or directory
i don't know what to do anymore maybe the problem is with my distro i'm downloding fedora 18 and see what happens!
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when compiling transmission on Windows

Post by rb07 »

fdlimit.c:40

Code: Select all

#ifdef WIN32
#include <windows.h>
#include <winioctl.h>
#else
#include <sys/resource.h> /* getrlimit */
#endif
Do you understand the cause of the problem?

If you were using a cross-compiler for Windows, then WIN32 would be defined. The error has nothing to do with the patch, my instructions, or anything different than not using the correct procedure.

Thanks for pointing out the outdated links, what links? SF is not down, the message you saw is because you used an outdated link (from somewhere different than the project's page), use http://trqtw.sourceforge.net/blog/
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

about link when i saw the wiki i wanted to do exactly as it said(with exception that i used centos instead of fedora) and this link http://homes.merjis.com/~rich/mingw/fed ... de/x86_64/ in wiki was not working so i could not go any further and also here http://trqtw.sourceforge.net/blog/trans ... r-windows/ you have suggested that we should download QT from nokia but nokia has sold QT digia and digia as far as i know does not let us to download that version anymore
//
i'm downloading fedora 18 it will be finished tomorrow i'll try the steps again with a completely clean environment and see what happens!
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when compiling transmission on Windows

Post by rb07 »

OK, that's an old link. I haven't used Fedora in more than 3 or 4 years, MXE is not for Fedora, it can be used in it but Fedora has its own cross-compiling environment, so why use it?

All those details are irrelevant. Today I recompiled Tr-Qt using Cygwin, yep not even a Linux distro but good old Windows 7 with Cygwin installed in it (I'm talking about cross-compilation, with MXE installed in Cygwin).

The point is: if you know what you are doing, its not difficult to build Transmission. And that point is something I think I made clear on Transmission's Wiki, a long time ago; things like libutp which make changes that break things are very easy to fix.
Jordan
Transmission Developer
Posts: 2312
Joined: Sat May 26, 2007 3:39 pm
Location: Titania's Room

Re: Error when compiling transmission on Windows

Post by Jordan »

rb07, is there an up-to-date page describing how you build trqtw?

It seems like there are a lot of people depending on your builds now, which is kind of awesome :D
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when compiling transmission on Windows

Post by rb07 »

Jordan wrote:rb07, is there an up-to-date page describing how you build trqtw?
The SourceForge Wiki is the most up to date.

The old links (which I corrected yesterday) where mostly the result of SF changing all projects and not with their documentation if you where using Web apps like WordPress. I was too lazy to revise the pages which I had to put up again from a backup after installing WordPress in the project's space.

There are also some old (stale) links on the page I made in Transmission's Wiki... I haven't really updated that page after we got to the point where Transmission-Qt was building out of the box.
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

now i'm pretty sure that this comes from the patch file and nothing else! as you can see there is some errors which i thought it was not a problem but with looking at fdlimit.c i have seen that my version is written like

Code: Select all

#include <sys/types.h>
#include <sys/stat.h>
#include <sys/time.h> /* getrlimit */
#include <sys/resource.h> /* getrlimit */
#include <fcntl.h> /* O_LARGEFILE posix_fadvise */
#include <unistd.h> /* lseek(), write(), ftruncate(), pread(), pwrite(), etc */
but the version you have posted was like

Code: Select all

#ifdef WIN32
#include <windows.h>
#include <winioctl.h>
#else
#include <sys/resource.h> /* getrlimit */
#endif
which gives us the answer my version is different from yours so it is not patched at all!
this is when i do patching as you can see there is some errors (i patched it against transmission 2.51 to be matched with what you have posted in wiki)

Code: Select all

patch -p0  < Transmission-r12283.diff 
patching file libtransmission/utils.c
Hunk #4 succeeded at 528 (offset 12 lines).
Hunk #5 succeeded at 547 (offset 12 lines).
Hunk #6 succeeded at 565 (offset 12 lines).
Hunk #7 succeeded at 1507 (offset 28 lines).
Hunk #8 succeeded at 1534 (offset 28 lines).
Hunk #9 succeeded at 1565 (offset 28 lines).
Hunk #10 succeeded at 1656 (offset 28 lines).
patching file libtransmission/blocklist.c
patching file libtransmission/bencode.c
Hunk #2 succeeded at 1660 (offset 9 lines).
Hunk #3 succeeded at 1723 (offset 12 lines).
Hunk #4 succeeded at 1737 (offset 12 lines).
patching file libtransmission/metainfo.c
Hunk #1 succeeded at 63 (offset -2 lines).
Hunk #2 succeeded at 92 (offset -2 lines).
Hunk #3 succeeded at 106 (offset -2 lines).
Hunk #4 succeeded at 120 (offset -2 lines).
Hunk #5 succeeded at 627 (offset 37 lines).
patching file libtransmission/rpcimpl.c
Hunk #1 FAILED at 1179.
Hunk #2 succeeded at 1291 with fuzz 2 (offset 99 lines).
1 out of 2 hunks FAILED -- saving rejects to file libtransmission/rpcimpl.c.rej
patching file libtransmission/announcer-udp.c
patching file libtransmission/fdlimit.c
Hunk #1 succeeded at 46 (offset -6 lines).
Hunk #2 succeeded at 102 (offset -6 lines).
Hunk #3 succeeded at 279 (offset -6 lines).
Hunk #4 FAILED at 364.
Hunk #5 succeeded at 373 (offset -15 lines).
Hunk #6 succeeded at 382 (offset -15 lines).
1 out of 6 hunks FAILED -- saving rejects to file libtransmission/fdlimit.c.rej
patching file libtransmission/fdlimit.h
patching file libtransmission/tr-dht.c
patching file libtransmission/torrent-magnet.c
patching file libtransmission/platform.c
Hunk #10 succeeded at 605 (offset -4 lines).
Hunk #11 succeeded at 624 (offset -4 lines).
Hunk #12 succeeded at 635 (offset -4 lines).
Hunk #13 succeeded at 650 (offset -4 lines).
Hunk #14 succeeded at 661 (offset -4 lines).
Hunk #15 succeeded at 709 (offset -4 lines).
Hunk #16 succeeded at 728 (offset -4 lines).
patching file libtransmission/platform.h
Hunk #1 succeeded at 84 (offset -12 lines).
patching file libtransmission/resume.c
Hunk #1 succeeded at 885 with fuzz 1 (offset -13 lines).
patching file libtransmission/session.c
Hunk #1 FAILED at 1880.
Hunk #2 FAILED at 1890.
Hunk #3 succeeded at 1923 with fuzz 1 (offset 13 lines).
Hunk #4 succeeded at 2174 (offset 34 lines).
Hunk #5 succeeded at 2182 (offset 34 lines).
Hunk #6 succeeded at 2219 (offset 34 lines).
Hunk #7 succeeded at 2235 (offset 34 lines).
Hunk #8 succeeded at 2371 (offset 34 lines).
Hunk #9 succeeded at 2385 (offset 34 lines).
Hunk #10 succeeded at 2410 (offset 34 lines).
2 out of 10 hunks FAILED -- saving rejects to file libtransmission/session.c.rej
patching file libtransmission/makemeta.c
patching file libtransmission/net.c
patching file libtransmission/net.h
patching file libtransmission/torrent.c
Hunk #1 FAILED at 767.
Hunk #2 succeeded at 788 (offset -12 lines).
Hunk #3 succeeded at 878 (offset -13 lines).
Hunk #4 succeeded at 1596 (offset 46 lines).
Hunk #5 succeeded at 2000 (offset 80 lines).
Hunk #6 FAILED at 2380.
Hunk #7 succeeded at 2658 (offset 69 lines).
Hunk #8 FAILED at 2661.
Hunk #9 FAILED at 2693.
Hunk #10 FAILED at 2769.
Hunk #11 succeeded at 2958 (offset 81 lines).
Hunk #12 succeeded at 3039 (offset 81 lines).
Hunk #13 FAILED at 2976.
6 out of 13 hunks FAILED -- saving rejects to file libtransmission/torrent.c.rej
patching file qt/qtr.pro
Hunk #1 succeeded at 27 with fuzz 2 (offset 3 lines).
patching file qt/make-dialog.cc
Hunk #1 FAILED at 58.
Hunk #2 FAILED at 79.
Hunk #3 FAILED at 144.
3 out of 3 hunks FAILED -- saving rejects to file qt/make-dialog.cc.rej
patching file qt/session.cc
patching file third-party/dht/dht.c
patching file third-party/libutp/utp.cpp
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

rb07 wrote:
Jordan wrote:rb07, is there an up-to-date page describing how you build trqtw?
The SourceForge Wiki is the most up to date.

The old links (which I corrected yesterday) where mostly the result of SF changing all projects and not with their documentation if you where using Web apps like WordPress. I was too lazy to revise the pages which I had to put up again from a backup after installing WordPress in the project's space.

There are also some old (stale) links on the page I made in Transmission's Wiki... I haven't really updated that page after we got to the point where Transmission-Qt was building out of the box.
even the patch on 2.31 gives me at least three errors let alone the newer versions!

Code: Select all

 patch -p0  < Transmission-r12283.diff 
patching file libtransmission/utils.c
patching file libtransmission/blocklist.c
patching file libtransmission/bencode.c
Hunk #3 succeeded at 1714 (offset 3 lines).
Hunk #4 succeeded at 1728 (offset 3 lines).
patching file libtransmission/metainfo.c
Hunk #1 succeeded at 63 (offset -2 lines).
Hunk #2 succeeded at 92 (offset -2 lines).
Hunk #3 succeeded at 106 (offset -2 lines).
Hunk #4 succeeded at 120 (offset -2 lines).
Hunk #5 succeeded at 599 (offset 9 lines).
patching file libtransmission/rpcimpl.c
Hunk #1 succeeded at 1185 (offset 6 lines).
Hunk #2 succeeded at 1198 (offset 6 lines).
patching file libtransmission/announcer-udp.c
patching file libtransmission/fdlimit.c
patching file libtransmission/fdlimit.h
patching file libtransmission/tr-dht.c
patching file libtransmission/torrent-magnet.c
patching file libtransmission/platform.c
patching file libtransmission/platform.h
patching file libtransmission/resume.c
Hunk #1 succeeded at 885 with fuzz 1 (offset -13 lines).
patching file libtransmission/session.c
Hunk #1 succeeded at 1857 (offset -23 lines).
Hunk #2 succeeded at 1867 (offset -23 lines).
Hunk #3 succeeded at 1894 (offset -23 lines).
Hunk #4 succeeded at 2124 (offset -23 lines).
Hunk #5 succeeded at 2132 (offset -23 lines).
Hunk #6 succeeded at 2169 (offset -23 lines).
Hunk #7 succeeded at 2185 (offset -23 lines).
Hunk #8 succeeded at 2321 (offset -23 lines).
Hunk #9 succeeded at 2335 (offset -23 lines).
Hunk #10 succeeded at 2360 (offset -23 lines).
patching file libtransmission/makemeta.c
patching file libtransmission/net.c
Hunk #1 succeeded at 75 (offset 2 lines).
patching file libtransmission/net.h
patching file libtransmission/torrent.c
Hunk #1 FAILED at 767.
Hunk #2 succeeded at 791 (offset -9 lines).
Hunk #3 succeeded at 880 (offset -11 lines).
Hunk #4 succeeded at 1539 (offset -11 lines).
Hunk #5 succeeded at 1909 (offset -11 lines).
Hunk #6 FAILED at 2380.
Hunk #7 succeeded at 2567 (offset -22 lines).
Hunk #8 succeeded at 2639 (offset -22 lines).
Hunk #9 succeeded at 2680 (offset -22 lines).
Hunk #10 succeeded at 2756 (offset -22 lines).
Hunk #11 succeeded at 2864 (offset -22 lines).
Hunk #12 succeeded at 2945 (offset -22 lines).
Hunk #13 FAILED at 2985.
3 out of 13 hunks FAILED -- saving rejects to file libtransmission/torrent.c.rej
patching file qt/qtr.pro
patching file qt/make-dialog.cc
patching file qt/session.cc
patching file third-party/dht/dht.c
patching file third-party/libutp/utp.cpp
would you plz give me your source code that you do your compiling without any patch or at least make a new patch?
Last edited by MehranNZ on Wed Jan 23, 2013 2:19 am, edited 1 time in total.
MehranNZ
Posts: 8
Joined: Wed Jan 16, 2013 6:05 pm

Re: Error when compiling transmission on Windows

Post by MehranNZ »

At last i could compile and run it on windows!
For the future readers i suggest you do not try and build it in linux with cross compiler tools! as far as i have seen the source code is incompatible with mingw if you try to fix them in the transmission source code you will encounter with a lot of errors and you have to jump from one source to the other (it probably is possible to make it work but was a headache for me and i gave up!)
the best way is using cygwin, i do not use windows so i was not familiar with this program, TBH i thought it was a linux emulator but it turned out it is similar to wine and when you do compiling it gives you a .exe binary file not a linux binary! so here it is you have to install this cygwin thing and do this:
1- download libevent and
./configure --prefix=/usr --disable-shared
make
make install

2-go to utp.cpp and add this statement after the last #endif "extern int snprintf(char *, size_t, const char *, ...);" and then
./configure --prefix=/usr --disable-shared --enable-static --disable-nls --without-gtk CPPFLAGS=-DHAVE_STRUCT_TIMESPEC
make

3- copy the cli/transmission-cli.exe to /bin

4- go to /bin and enter $cygcheck "transmission-cli.exe"

5-copy all of listed .dll files into a folder along with transmission-cli.exe and you have an independent binary cli transmission which you can run anywhere you want on windows
Post Reply