[rtmpdump] bad reloc address 0x0 in section `.data'
Joshua Finch
joshf87 at live.com
Mon Mar 19 05:50:50 CET 2012
I'm trying to compile librtmp with MinGW-w64 4.6.4 32-bit toolchain,
from rubenvb personal build for Windows 32-bit. I repeat, it builds
32-bit, it's not his 64-bit toolchain. I can't seem to get librtmp to
correctly link, I keep getting 'bad reloc address' (address varies, I
tried removing optimizations, opts change the address). I'm not sure
where exactly the problem is, this is the ONLY library I'm having
problems with. It works correctly with MinGW from mingw.org, but I want
to use rubenvb's 32-bit toolchain since it is tons better "out of the box".
I compiled 34 other libs for/in MPlayer without issue. Even if I use a
precompiled lib from another toolchain that worked, it gives the same error.
I'm using polarssl. I have everything set up correctly so it will
use/find polarssl, it looks like it can't find it but I don't think
those are caused by not finding polarssl but rather whatever is causing
the bad reloc address.
#include <librtmp/rtmp.h>
int main(void) { RTMP_Socket(NULL); return 0; }
gcc -Wundef -Wall -Wno-switch -Wno-parentheses -Wpointer-arith
-Wredundant-decls -Wstrict-prototypes -Wmissing-prototypes
-Wdisabled-optimization -Wno-pointer-sign -Wdeclaration-after-statement
-std=gnu99 -Werror-implicit-function-declaration -O4 -march=i486
-mtune=generic -pipe -ffast-math -fomit-frame-pointer
-fno-tree-vectorize /tmp/mplayer-configure-14565-5896/tmp.c
-Ilibdvdread4 -I. -Iffmpeg
-I/E/Buildsys/mingw32/msys/home/Joshua/mplayer/live -DFRIBIDI_ENTRY=
-fno-common -I/mingw/i686-w64-mingw32/include/freetype2
-I/mingw/i686-w64-mingw32/include -static
/E/Buildsys/mingw32/msys/home/Joshua/mplayer/live/liveMedia/libliveMedia.a
/E/Buildsys/mingw32/msys/home/Joshua/mplayer/live/UsageEnvironment/libUsageEnvironment.a
/E/Buildsys/mingw32/msys/home/Joshua/mplayer/live/BasicUsageEnvironment/libBasicUsageEnvironment.a
/E/Buildsys/mingw32/msys/home/Joshua/mplayer/live/groupsock/libgroupsock.a
-lm -lwinmm -ffast-math -lws2_32 -liconv -lpng -lz -lmng -lz -ljpeg
-lungif -lbluray -L/mingw/i686-w64-mingw32/lib -lfreetype -lz
-lfontconfig -lexpat -lfreetype -lz -liconv -lfribidi -lenca -lz -llzo2
-lmad -ltheoradec -logg -lmpg123 -la52 -ladvapi32 -lole32 -lstdc++
-lws2_32 -lSDL -lwinmm -lgdi32 -ldxguid -lopengl32 -lgdi32 -lwinmm
-lgdi32 -o /tmp/mplayer-configure-14565-5896/tmp.exe -lrtmp
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x52):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x6a):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x8b):
undefined reference to `havege_random'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xaa):
undefined reference to `dhm_make_public'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xcc):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xee):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x106):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x11e):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x140):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x15c):
undefined reference to `dhm_calc_secret'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x1ac):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x1e1):
undefined reference to `mpi_lset'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x1f3):
undefined reference to `mpi_cmp_mpi'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x229):
undefined reference to `mpi_copy'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x243):
undefined reference to `mpi_sub_int'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x255):
undefined reference to `mpi_cmp_mpi'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2a4):
undefined reference to `mpi_exp_mod'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2b7):
undefined reference to `mpi_cmp_int'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2da):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x333):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x35d):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x37a):
undefined reference to `mpi_read_string'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x3a1):
undefined reference to `mpi_lset'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x3d7):
undefined reference to `dhm_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x3e4):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x3ff):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x41b):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x437):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x4b2):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x4cd):
undefined reference to `mpi_read_string'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x52f):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x54b):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x57a):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x5c2):
undefined reference to `mpi_size'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x61e):
undefined reference to `mpi_write_binary'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x676):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x68f):
undefined reference to `mpi_read_binary'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x6b9):
undefined reference to `mpi_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x6d4):
undefined reference to `mpi_read_string'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x757):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x76d):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x7d8):
undefined reference to `sha2_hmac_starts'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x7f5):
undefined reference to `sha2_hmac_update'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x811):
undefined reference to `sha2_hmac_finish'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x85c):
undefined reference to `arc4_setup'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x881):
undefined reference to `sha2_hmac_starts'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x89e):
undefined reference to `sha2_hmac_update'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x8ba):
undefined reference to `sha2_hmac_finish'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x905):
undefined reference to `arc4_setup'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xc94):
undefined reference to `sha2_hmac_starts'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xcb0):
undefined reference to `sha2_hmac_update'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xccc):
undefined reference to `sha2_hmac_finish'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x20a4):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x20de):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2eff):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2f39):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x2fab):
undefined reference to `_imp__timeGetTime at 0'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x3131):
undefined reference to `havege_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x46de):
undefined reference to `ssl_init'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x46f7):
undefined reference to `ssl_set_endpoint'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x4710):
undefined reference to `ssl_set_authmode'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x472c):
undefined reference to `havege_random'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x4734):
undefined reference to `ssl_set_rng'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x4745):
undefined reference to `ssl_default_ciphersuites'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x474d):
undefined reference to `ssl_set_ciphersuites'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x477d):
undefined reference to `ssl_set_session'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x47a4):
undefined reference to `net_send'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x47b0):
undefined reference to `net_recv'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x47b8):
undefined reference to `ssl_set_bio'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x47c9):
undefined reference to `ssl_handshake'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x55e8):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x568d):
undefined reference to `arc4_crypt'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x9faf):
undefined reference to `dhm_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x9fbc):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x9fd7):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0x9ff3):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xa00f):
undefined reference to `mpi_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xa10d):
undefined reference to `ssl_read'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xa213):
undefined reference to `ssl_write'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xa26c):
undefined reference to `ssl_close_notify'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xa27d):
undefined reference to `ssl_free'
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o):rtmp.c:(.text+0xb5e4):
undefined reference to `_imp__WSASetLastError at 4'
e:/buildsys/mingw32/bin/../lib/gcc/i686-w64-mingw32/4.6.4/../../../../i686-w64-mingw32/bin/ld.exe:
E:/Buildsys/mingw32/i686-w64-mingw32/lib\librtmp.a(rtmp.o): bad reloc
address 0x0 in section `.data'
e:/buildsys/mingw32/bin/../lib/gcc/i686-w64-mingw32/4.6.4/../../../../i686-w64-mingw32/bin/ld.exe:
final link failed: Invalid operation
collect2: ld returned 1 exit status
More information about the rtmpdump
mailing list