Koneki/LDT/Developer Area/Compilation linux

From Eclipsepedia

< Koneki‎ | LDT
Jump to: navigation, search

how to build

See how to build Jnlua
Lua binaries can be found on Lua binaries or in your linux package repository.

To check your binary :
- compare it to the current version (table below), size and dependencies should be almost the same.
- check the SONAME is correct. (same one in lua and jnlua binaries)

Version history glibc to know about dependencies restriction : http://en.wikipedia.org/wiki/GNU_C_Library#Version_history

To understand glibc dependencies : http://stackoverflow.com/questions/4032373/linking-against-an-old-version-of-libc-to-provide-greater-application-coverage

Maybe we should try to build jnlua statically but this could make some problems when C module is required :/

Current binaries status

Linux 32 Lua 51 Linux 64 Lua 51 Linux 32 Lua 52 Linux 64 Lua 52
binaries size (bytes)
jnlua
61,176 68,286 69,194 72,580
binaries size (bytes)
lua
153,668 179,760 202,952 204,488
ldd jnlua
linux-gate.so.1 =>  (0xb77c5000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xb75f1000)
liblua5.1.so.0 => /usr/lib/i386-linux-gnu/liblua5.1.so.0 (0xb75c4000)
/lib/ld-linux.so.2 (0xb77c6000)
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xb7597000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xb7592000)
linux-vdso.so.1 =>  (0x00007fffdebca000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007ff8a5022000)
liblua5.1.so.0 => /usr/lib/x86_64-linux-gnu/liblua5.1.so.0 (0x00007ff8a4df5000)
/lib64/ld-linux-x86-64.so.2 (0x00007ff8a561c000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007ff8a4af0000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007ff8a48ec000)
linux-gate.so.1 =>  (0xb77ba000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xb75e5000)
/lib/ld-linux.so.2 (0xb77bb000)
liblua5.2.so.0 => /usr/lib/i386-linux-gnu/liblua5.2.so.0 (0xb75b3000)
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xb7586000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xb7581000)
linux-vdso.so.1 =>  (0x00007fff6f9fe000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fbd404b8000)
/lib64/ld-linux-x86-64.so.2 (0x00007fbd40ab2000)
liblua5.2.so.0 => /usr/lib/x86_64-linux-gnu/liblua5.2.so.0 (0x00007fbd40286000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fbd3ff81000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fbd3fd7d000)
ldd lua
linux-gate.so.1 =>  (0xb77a8000)
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xb7739000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xb7734000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xb7589000)
/lib/ld-linux.so.2 (0xb77a9000)
linux-vdso.so.1 =>  (0x00007fff8734a000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f3f4ea15000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f3f4e811000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f3f4e448000)
/lib64/ld-linux-x86-64.so.2 (0x00007f3f4ef69000)
linux-gate.so.1 =>  (0xb7768000)
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xb76ef000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xb76ea000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xb753f000)
/lib/ld-linux.so.2 (0xb7769000)
linux-vdso.so.1 =>  (0x00007fffd3dfe000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f344a4ca000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f344a2c6000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f3449efd000)
/lib64/ld-linux-x86-64.so.2 (0x00007f344aa24000)
readelf -d jnlua
0x00000001 (NEEDED) Librairie partagées: [libc.so.6]
0x00000001 (NEEDED) Librairie partagées: [liblua5.1.so.0]
0x0000000e (SONAME) Librairie soname: [libjnlua5.1.so]
0x0000000000000001 (NEEDED) Librairie partagées: [libc.so.6]
0x0000000000000001 (NEEDED) Librairie partagées: [liblua5.1.so.0]
0x000000000000000e (SONAME) Librairie soname: [libjnlua5.1.so]
0x00000001 (NEEDED) Librairie partagées: [libc.so.6]
0x00000001 (NEEDED) Librairie partagées: [ld-linux.so.2]
0x00000001 (NEEDED) Librairie partagées: [liblua5.2.so.0]
0x0000000e (SONAME) Librairie soname: [libjnlua52.so]
0x0000000000000001 (NEEDED) Librairie partagées: [libc.so.6]
0x0000000000000001 (NEEDED) Librairie partagées: [ld-linux-x86-64.so.2]
0x0000000000000001 (NEEDED) Librairie partagées: [liblua5.2.so.0]
0x000000000000000e (SONAME) Librairie soname: [libjnlua52.so]
readelf -d lua
0x00000001 (NEEDED) Librairie partagées: [libm.so.6]
0x00000001 (NEEDED) Librairie partagées: [libdl.so.2]
0x00000001 (NEEDED) Librairie partagées: [libc.so.6]
0x0000000e (SONAME) Librairie soname: [liblua5.1.so.0]
0x0000000000000001 (NEEDED) Librairie partagées: [libm.so.6]
0x0000000000000001 (NEEDED) Librairie partagées: [libdl.so.2]
0x0000000000000001 (NEEDED) Librairie partagées: [libc.so.6]
0x000000000000000e (SONAME) Librairie soname: [liblua5.1.so.0]
0x00000001 (NEEDED) Librairie partagées: [libm.so.6]
0x00000001 (NEEDED) Librairie partagées: [libdl.so.2]
0x00000001 (NEEDED) Librairie partagées: [libc.so.6]
0x0000000e (SONAME) Librairie soname: [liblua5.2.so.0]
0x0000000000000001 (NEEDED) Librairie partagées: [libm.so.6]
0x0000000000000001 (NEEDED) Librairie partagées: [libdl.so.2]
0x0000000000000001 (NEEDED) Librairie partagées: [libc.so.6]
0x000000000000000e (SONAME) Librairie soname: [liblua5.2.so.0]
objdump -p jnlua
  required from libc.so.6:
    0x09691f73 0x00 05 GLIBC_2.1.3
    0x0d696914 0x00 04 GLIBC_2.4
    0x0d696910 0x00 03 GLIBC_2.0
    0x06969191 0x00 02 GLIBC_2.11
  required from libc.so.6:
    0x0d696914 0x00 04 GLIBC_2.4
    0x09691a75 0x00 03 GLIBC_2.2.5
    0x06969191 0x00 02 GLIBC_2.11
  required from ld-linux.so.2:
    0x0d696913 0x00 03 GLIBC_2.3
  required from libc.so.6:
    0x09691f73 0x00 05 GLIBC_2.1.3
    0x0d696914 0x00 04 GLIBC_2.4
    0x0d696910 0x00 02 GLIBC_2.0
  required from ld-linux-x86-64.so.2:
    0x0d696913 0x00 04 GLIBC_2.3
  required from libc.so.6:
    0x06969194 0x00 05 GLIBC_2.14
    0x0d696914 0x00 03 GLIBC_2.4
    0x09691a75 0x00 02 GLIBC_2.2.5
objdump -p lua
  required from libdl.so.2:
    0x0d696911 0x00 10 GLIBC_2.1
    0x0d696910 0x00 08 GLIBC_2.0
  required from libc.so.6:
    0x09691f73 0x00 12 GLIBC_2.1.3
    0x0d696914 0x00 11 GLIBC_2.4
    0x0d696913 0x00 09 GLIBC_2.3
    0x0d696917 0x00 07 GLIBC_2.7
    0x09691974 0x00 06 GLIBC_2.3.4
    0x0d696912 0x00 05 GLIBC_2.2
    0x0d696911 0x00 04 GLIBC_2.1
    0x0d696910 0x00 03 GLIBC_2.0
  required from libm.so.6:
    0x0d696910 0x00 02 GLIBC_2.0
  required from libdl.so.2:
    0x0d696911 0x00 13 GLIBC_2.1
    0x0d696910 0x00 08 GLIBC_2.0
  required from libm.so.6:
    0x0d696910 0x00 03 GLIBC_2.0
  required from libc.so.6:
    0x0d696912 0x00 12 GLIBC_2.2
    0x06969191 0x00 11 GLIBC_2.11
    0x09691974 0x00 10 GLIBC_2.3.4
    0x09691f73 0x00 09 GLIBC_2.1.3
    0x0d696914 0x00 07 GLIBC_2.4
    0x0d696911 0x00 06 GLIBC_2.1
    0x0d696917 0x00 05 GLIBC_2.7
    0x0d696910 0x00 04 GLIBC_2.0
    0x0d696913 0x00 02 GLIBC_2.3
  required from libdl.so.2:
    0x09691a75 0x00 07 GLIBC_2.2.5
  required from libc.so.6:
    0x0d696914 0x00 08 GLIBC_2.4
    0x0d696913 0x00 06 GLIBC_2.3
    0x0d696917 0x00 05 GLIBC_2.7
    0x09691974 0x00 04 GLIBC_2.3.4
    0x09691a75 0x00 03 GLIBC_2.2.5
  required from libm.so.6:
    0x09691a75 0x00 02 GLIBC_2.2.5
  required from libdl.so.2:
    0x09691a75 0x00 09 GLIBC_2.2.5
  required from libm.so.6:
    0x09691a75 0x00 04 GLIBC_2.2.5
  required from libc.so.6:
    0x06969191 0x00 10 GLIBC_2.11
    0x06969194 0x00 08 GLIBC_2.14
    0x09691974 0x00 07 GLIBC_2.3.4
    0x0d696914 0x00 06 GLIBC_2.4
    0x0d696917 0x00 05 GLIBC_2.7
    0x09691a75 0x00 03 GLIBC_2.2.5
    0x0d696913 0x00 02 GLIBC_2.3