0

I am Building android project for arm64-v8 and I am using NDK-r10e.I have build build Libnice 0.13 using its dependency (Glib 2.35.8) and I have all the dependencies of Glib compiled(intl,iconv,ffi). So I was successfull in building the static libraries of Glib and then using my glib libraries to build a Libnice static library . Now I am using these static libraries to build my android project ,I am getting the following errors and i have no clue why its giving me this linker errors because at the time of building those libraries everything was fine for me.

libnice.a(pseudotcp.o): In function `pseudo_tcp_socket_get_type':
/Users/aagman/Desktop/LibNIce/libnic/Newlibnice/jni/files/agent/pseudotcp.c:78:  undefined reference to `G_STATIC_ASSERT'

In function `nice_agent_get_type':
/Users/aagman/Desktop/LibNIce/libnic/Newlibnice/jni/files/agent/agent.c:85:      undefined reference to `G_STATIC_ASSERT'
/Users/aagman/Desktop/LibNIce/libnic/Newlibnice/jni/files/agent/agent.c:85:  undefined reference to `G_STATIC_ASSERT'
mateuscb
  • 10,150
  • 3
  • 52
  • 76
Aagman
  • 684
  • 6
  • 18
  • 1
    What platform are you building for and how did you build libnice.so? `[arm64-v8a]` is ARM 64-bit. Is the rest of your code targeting 64 bit ARM-v8 too else the linker will fail as the binaries are incompatible – rcbevans Sep 15 '15 at 08:38
  • I am building for ARM 64 ,I builded my libnice.so for ARM64 only and I used all the dependencies of Libnice which were builded for ARM 64. – Aagman Sep 15 '15 at 08:43

1 Answers1

0

This error occur if the address of an "unsigned int" is passed for a 64 bit build, which would be okay for a 32 bit build but should be an unsigned long for 64 bit. Pass -m64 / -m32 on the command line to control the build target.

Aagman
  • 684
  • 6
  • 18