Bonjour,
Je travaille sous Debian Etch AMD64 et je souhaite compiler pour l'architecture i386. Le problème est que je n'arrive pas à compiler GCC pour i386. J'ai suivi le tutoriel aux adresses http://www.z0pe.org/howto/htc-univer...on-d-un-kernel
et http://wiki.debian.org/BuildingCrossCompilers
Après avoir crée et installé les paquets suivants:
binutils-i386-linux-gnu_2.17-3_amd64.deb
binutils-i486-linux-gnu_2.17-3_amd64.deb
libdb1-compat-i386-cross_2.1.3-9_all.deb
libc6-dev-i386-cross_2.3.6.ds1-13etch5_all.deb
linux-kernel-headers-i386-cross_2.6.18-7_all.deb
libc6-i386-cross_2.3.6.ds1-13etch5_all.deb
j'ai tenté de compiler GCC comme suit:
Et voici ce que j'obtiens dans le fichier gcc.build:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5 apt-get source gcc-4.1 cd gcc-4.1-4.1.1ds2 export GCC_TARGET=i386 debian/rules control dpkg-buildpackage -us -uc -rfakeroot -b > ../gcc.build 2>&1 || echo 'Build error'
je relance donc la compilation avec l'option -d et j'obtiens le message d'erreur suivant:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9 willy@SuperMicro:~/tmp/gcc/gcc-4.1-4.1.1ds2$ cat ../gcc.build dpkg-buildpackage: source package is gcc-4.1 dpkg-buildpackage: source version is 4.1.1ds2-21 dpkg-buildpackage: source changed by Matthias Klose <doko@debian.org> dpkg-buildpackage: host architecture amd64 dpkg-buildpackage: source version without epoch 4.1.1ds2-21 dpkg-checkbuilddeps : dépendances de construction non trouvées : libc6-dev-amd64-i386-cross dpkg-buildpackage: Build dependencies/conflicts unsatisfied; aborting. dpkg-buildpackage: (Use -d flag to override.)
J'ai cherché sur Google, mais je n'ai trouvé aucune information pouvant m'aider et c'est pourquoi je sollicite votre aide.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51 willy@SuperMicro:~/tmp/gcc$ tail -n 50 gcc.build checking how to run the C++ preprocessor... /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc -shared-libgcc -B/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc -nostdinc++ -L/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/i486-linux-gnu/64/libstdc++-v3/src -L/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/i486-linux-gnu/64/libstdc++-v3/src/.libs -B/usr/i486-linux-gnu/bin/ -B/usr/i486-linux-gnu/lib/ -isystem /usr/i486-linux-gnu/include -isystem /usr/i486-linux-gnu/sys-include -m64 -E loading cache ./config.cache within ltconfig checking host system type... x86_64-pc-linux-gnu checking build system type... x86_64-pc-linux-gnu checking for objdir... .libs checking for /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc option to produce PIC... -fPIC -DPIC checking if /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc PIC flag -fPIC -DPIC works... yes checking if /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc static flag -static works... no finding the maximum length of command line arguments... (cached) 49153 checking if /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc supports -c -o file.o... (cached) yes checking if /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc supports -fno-rtti -fno-exceptions ... yes checking whether the linker (/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/collect-ld -m elf_x86_64) supports shared libraries... checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking dynamic linker characteristics... GNU/Linux ld.so checking command to parse /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/nm output... failed checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes appending configuration tag "CXX" to libtool checking for exception model to use... call frame checking for compiler with PCH support... yes checking for enabled PCH... yes checking for underlying I/O to use... stdio checking how to run the C preprocessor... /home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/xgcc -B/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build/./gcc/ -B/usr/i486-linux-gnu/bin/ -B/usr/i486-linux-gnu/lib/ -isystem /usr/i486-linux-gnu/include -isystem /usr/i486-linux-gnu/sys-include -m64 -E checking for egrep... grep -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 C locale to use... gnu checking for msgfmt... yes checking libintl.h usability... yes checking libintl.h presence... yes checking for libintl.h... yes checking for library containing gettext... configure: error: Link tests are not allowed after GCC_NO_EXECUTABLES. make[3]: *** [configure-target-libstdc++-v3] Error 1 make[3]: Leaving directory `/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build' make[2]: *** [all] Error 2 make[2]: Leaving directory `/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2/build' s=`cat status`; rm -f status; test $s -eq 0 make[1]: *** [stamps/05-build-stamp] Error 1 make[1]: Leaving directory `/home/willy/tmp/gcc/gcc-4.1-4.1.1ds2' make: *** [stamps/05-build-stamp] Erreur 2
Willy.
Partager