docs/0 - Table of content.txt
author "Benoît Thébaudeau" <benoit.thebaudeau@advansee.com>
Fri Jan 27 13:31:16 2012 +0100 (2012-01-27)
changeset 2854 a70abdbfa342
parent 2563 e17f35b05539
child 2908 dcdb309b7967
permissions -rw-r--r--
complibs/cloog: fix linking with libm

In Ubuntu 11.04 and 11.10, the default options for ld have changed.
--no-copy-dt-needed-entries and --as-needed are now enabled by default, which
causes errors like:

[EXTRA] Checking CLooG/ppl
[DEBUG] ==> Executing: 'make' '-j3' '-s' 'check'
[ALL ] Making check in .
[ALL ] config.status: creating include/cloog/cloog-config.h
[ALL ] config.status: include/cloog/cloog-config.h is unchanged
[ALL ] libtool: link: i686-build_pc-linux-gnu-gcc -Wall -fomit-frame-pointer
-pipe -o cloog cloog.o -L/<snip>/build/static/lib ./.libs/libcloog.a -lm
/<snip>/build/static/lib/libppl_c.a /<snip>/build/static/lib/libpwl.a
/<snip>/build/static/lib/libppl.a /<snip>/build/static/lib/libgmpxx.a
/<snip>/build/static/lib/libgmp.a -lstdc++
[ALL ] /usr/bin/ld: /<snip>/build/static/lib/libppl.a(MIP_Problem.o):
undefined reference to symbol 'sqrt@@GLIBC_2.0'
[ALL ] /usr/bin/ld: note: 'sqrt@@GLIBC_2.0' is defined in DSO
/usr/lib/gcc/i686-linux-gnu/4.6.1/../../../i386-linux-gnu/libm.so so try adding
it to the linker command line
[ALL ] /usr/lib/gcc/i686-linux-gnu/4.6.1/../../../i386-linux-gnu/libm.so:
could not read symbols: Invalid operation
[ALL ] collect2: ld returned 1 exit status
[ERROR] make[2]: *** [cloog] Error 1
[ERROR] make[1]: *** [check-recursive] Error 1

See:
https://wiki.ubuntu.com/NattyNarwhal/ToolchainTransition

This patch fixes these errors by placing '-lm' at the right place on the command
line as libppl requires libm when linking cloog.

Signed-off-by: "Benoît Thébaudeau" <benoit.thebaudeau@advansee.com>
yann@2076
     1
File.........: 0 - Table of content.txt
antony@2563
     2
Copyright....: (C) 2010 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
yann@2076
     3
License......: Creative Commons Attribution Share Alike (CC-by-sa), v2.5
yann@2076
     4
yann@2076
     5
yann@2076
     6
Table Of Content  /
yann@2076
     7
_________________/
yann@2076
     8
yann@2076
     9
yann@2076
    10
1- Introduction
yann@2076
    11
    - History
yann@2076
    12
    - Referring to crosstool-NG
yann@2076
    13
yann@2076
    14
2- Installing crosstool-NG
yann@2076
    15
    - Install method
yann@2076
    16
    - The hacker's way
yann@2076
    17
    - Preparing for packaging
yann@2076
    18
    - Shell completion
yann@2076
    19
    - Contributed code
yann@2076
    20
yann@2076
    21
3- Configuring a toolchain
yann@2076
    22
    - Interesting config options
yann@2076
    23
    - Re-building an existing toolchain
yann@2076
    24
    - Using as a backend for a build-system
yann@2076
    25
yann@2076
    26
4- Building the toolchain
yann@2076
    27
    - Stopping and restarting a build
yann@2076
    28
    - Testing all toolchains at once
yann@2076
    29
    - Overriding the number of // jobs
yann@2076
    30
    - Note on // jobs
yann@2076
    31
    - Tools wrapper
yann@2076
    32
yann@2076
    33
5- Using the toolchain
yann@2076
    34
    - The 'populate' script
yann@2076
    35
yann@2076
    36
6- Toolchain types
yann@2076
    37
    - Seemingly-native toolchains
yann@2076
    38
yann@2076
    39
7- Contributing
yann@2076
    40
    - Sending a bug report
yann@2076
    41
    - Sending patches
yann@2076
    42
yann@2076
    43
8- Internals
yann@2076
    44
    - Makefile front-end
yann@2076
    45
    - Kconfig parser
yann@2076
    46
    - Architecture-specific
yann@2076
    47
    - Adding a new version of a component
yann@2076
    48
    - Build scripts
yann@2076
    49
yann@2321
    50
9 - How is a toolchain constructed?
yann@2321
    51
    - I want a cross-compiler! What is this toolchain you're speaking about?
yann@2321
    52
    - So, what are those components in a toolchain?
yann@2321
    53
    - And now, how do all these components chained together?
yann@2321
    54
    - So the list is complete. But why does crosstool-NG have more steps?
yann@2321
    55
yann@2076
    56
A- Credits
yann@2076
    57
yann@2076
    58
B- Known issues
yann@2385
    59
    - gcc is not found, although I *do* have gcc installed
yann@2385
    60
    - The extract and/or path steps fail under Cygwin
yann@2385
    61
    - uClibc fails to build under Cygwin
yann@2385
    62
    - On 64-bit build systems, the glibc (possibly eglibc too) build
yann@2385
    63
      fails for 64-bit targets, because it can not find libgcc
yann@2569
    64
    - libtool.m4: error: problem compiling FC test program
yann@2569
    65
    - unable to detect the exception model
yann@2569
    66
    - configure: error: forced unwind support is required
yann@2569
    67
    - glibc start files and headers fail with: [/usr/include/limits.h] Error 1
yann@2076
    68
yann@2076
    69
C- Misc. tutorials
yann@2076
    70
    - Using crosstool-NG on FreeBSD (and other *BSD)
yann@2076
    71
    - Using crosstool-NG on MacOS-X
yann@2077
    72
    - Using Mercurial to hack crosstool-NG