Aller au contenu

Problème de compilation de kqemu


Poulpatine

Messages recommandés

Salut @ tous :)

Voilà, en cours pour faire des tests j'utilise qemu, le problème c'est que c'est relativement lent ... Je me suis donc mis en tête de compiler le module d'accélération pour qemu : kqemu mais je n'arrive pas à le compiler. J'ai lu qu'il était incompatible avec gcc 4.0 alors j'ai fait un pti :

export CC="gcc-3.4" et export CXX="gcc-3.4" mais toujours la même erreur.

Voici la sortie

bidule:/home/poulp/tmp/qemu-0.7.2# make
gcc -Wall -O2 -g -fno-strict-aliasing  -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -o dyngen dyngen.c
dyngen.c: In function ‘load_object’:
dyngen.c:508: warning: pointer targets in assignment differ in signedness
dyngen.c:544: warning: pointer targets in assignment differ in signedness
gcc -DQEMU_TOOL -Wall -O2 -g -fno-strict-aliasing  -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -o qemu-img qemu-img.c block.c block-cow.c block-qcow.c aes.c block-vmdk.c block-cloop.c block-dmg.c block-bochs.c block-vpc.c block-vvfat.c -lz
block-qcow.c:26:18: error: zlib.h: Aucun fichier ou répertoire de ce type
block-qcow.c: In function ‘decompress_buffer’:
block-qcow.c:408: error: ‘z_stream’ undeclared (first use in this function)
block-qcow.c:408: error: (Each undeclared identifier is reported only once
block-qcow.c:408: error: for each function it appears in.)
block-qcow.c:408: error: syntax error before ‘strm1’
block-qcow.c:411: error: ‘strm’ undeclared (first use in this function)
block-qcow.c:418: warning: implicit declaration of function ‘inflateInit2’
block-qcow.c:419: error: ‘Z_OK’ undeclared (first use in this function)
block-qcow.c:421: warning: implicit declaration of function ‘inflate’
block-qcow.c:421: error: ‘Z_FINISH’ undeclared (first use in this function)
block-qcow.c:423: error: ‘Z_STREAM_END’ undeclared (first use in this function)
block-qcow.c:423: error: ‘Z_BUF_ERROR’ undeclared (first use in this function)
block-qcow.c:425: warning: implicit declaration of function ‘inflateEnd’
block-qcow.c: In function ‘qcow_compress_cluster’:
block-qcow.c:620: error: ‘z_stream’ undeclared (first use in this function)
block-qcow.c:620: error: syntax error before ‘strm’
block-qcow.c:633: error: ‘strm’ undeclared (first use in this function)
block-qcow.c:634: warning: implicit declaration of function ‘deflateInit2’
block-qcow.c:634: error: ‘Z_DEFAULT_COMPRESSION’ undeclared (first use in this function)
block-qcow.c:635: error: ‘Z_DEFLATED’ undeclared (first use in this function)
block-qcow.c:636: error: ‘Z_DEFAULT_STRATEGY’ undeclared (first use in this function)
block-qcow.c:647: warning: implicit declaration of function ‘deflate’
block-qcow.c:647: error: ‘Z_FINISH’ undeclared (first use in this function)
block-qcow.c:648: error: ‘Z_STREAM_END’ undeclared (first use in this function)
block-qcow.c:648: error: ‘Z_OK’ undeclared (first use in this function)
block-qcow.c:650: warning: implicit declaration of function ‘deflateEnd’
block-cloop.c:26:18: error: zlib.h: Aucun fichier ou répertoire de ce type
block-cloop.c:37: error: syntax error before ‘z_stream’
block-cloop.c:37: warning: no semicolon at end of struct or union
block-cloop.c:38: warning: type defaults to ‘int’ in declaration of ‘BDRVCloopState’
block-cloop.c:38: warning: data definition has no type or storage class
block-cloop.c: In function ‘cloop_open’:
block-cloop.c:55: error: ‘s’ undeclared (first use in this function)
block-cloop.c:55: error: (Each undeclared identifier is reported only once
block-cloop.c:55: error: for each function it appears in.)
block-cloop.c:96: warning: implicit declaration of function ‘inflateInit’
block-cloop.c:96: error: ‘Z_OK’ undeclared (first use in this function)
block-cloop.c: At top level:
block-cloop.c:105: error: syntax error before ‘*’ token
block-cloop.c: In function ‘cloop_read_block’:
block-cloop.c:107: error: ‘s’ undeclared (first use in this function)
block-cloop.c:107: error: ‘block_num’ undeclared (first use in this function)
block-cloop.c:120: warning: implicit declaration of function ‘inflateReset’
block-cloop.c:121: error: ‘Z_OK’ undeclared (first use in this function)
block-cloop.c:123: warning: implicit declaration of function ‘inflate’
block-cloop.c:123: error: ‘Z_FINISH’ undeclared (first use in this function)
block-cloop.c:124: error: ‘Z_STREAM_END’ undeclared (first use in this function)block-cloop.c: In function ‘cloop_read’:
block-cloop.c:135: error: ‘s’ undeclared (first use in this function)
block-cloop.c: In function ‘cloop_close’:
block-cloop.c:150: error: ‘s’ undeclared (first use in this function)
block-cloop.c:156: warning: implicit declaration of function ‘inflateEnd’
block-dmg.c:27:18: error: zlib.h: Aucun fichier ou répertoire de ce type
block-dmg.c:49: error: syntax error before ‘z_stream’
block-dmg.c:49: warning: no semicolon at end of struct or union
block-dmg.c:50: warning: type defaults to ‘int’ in declaration of ‘BDRVDMGState’block-dmg.c:50: warning: data definition has no type or storage class
block-dmg.c: In function ‘dmg_open’:
block-dmg.c:78: error: ‘s’ undeclared (first use in this function)
block-dmg.c:78: error: (Each undeclared identifier is reported only once
block-dmg.c:78: error: for each function it appears in.)
block-dmg.c:166: warning: implicit declaration of function ‘inflateInit’
block-dmg.c:166: error: ‘Z_OK’ undeclared (first use in this function)
block-dmg.c: At top level:
block-dmg.c:174: error: syntax error before ‘*’ token
block-dmg.c: In function ‘is_sector_in_chunk’:
block-dmg.c:177: error: ‘chunk_num’ undeclared (first use in this function)
block-dmg.c:177: error: ‘s’ undeclared (first use in this function)
block-dmg.c:177: error: ‘sector_num’ undeclared (first use in this function)
block-dmg.c: At top level:
block-dmg.c:184: error: syntax error before ‘*’ token
block-dmg.c: In function ‘search_chunk’:
block-dmg.c:187: error: ‘s’ undeclared (first use in this function)
block-dmg.c:190: error: ‘sector_num’ undeclared (first use in this function)
block-dmg.c: At top level:
block-dmg.c:200: error: syntax error before ‘*’ token
block-dmg.c: In function ‘dmg_read_chunk’:
block-dmg.c:202: error: ‘s’ undeclared (first use in this function)
block-dmg.c:202: error: ‘sector_num’ undeclared (first use in this function)
block-dmg.c:235: warning: implicit declaration of function ‘inflateReset’
block-dmg.c:236: error: ‘Z_OK’ undeclared (first use in this function)
block-dmg.c:238: warning: implicit declaration of function ‘inflate’
block-dmg.c:238: error: ‘Z_FINISH’ undeclared (first use in this function)
block-dmg.c:239: error: ‘Z_STREAM_END’ undeclared (first use in this function)
block-dmg.c: In function ‘dmg_read’:
block-dmg.c:259: error: ‘s’ undeclared (first use in this function)
block-dmg.c: In function ‘dmg_close’:
block-dmg.c:274: error: ‘s’ undeclared (first use in this function)
block-dmg.c:285: warning: implicit declaration of function ‘inflateEnd’
block-vpc.c: In function ‘vpc_probe’:
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘strlen’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘strlen’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘__builtin_strcmp’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘strlen’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘__builtin_strcmp’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘__builtin_strcmp’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘__builtin_strcmp’ differ in signedness
block-vpc.c:84: warning: pointer targets in passing argument 1 of ‘strncmp’ differ in signedness
block-vvfat.c: In function ‘create_long_filename’:
block-vvfat.c:325: warning: pointer targets in passing argument 1 of ‘short2long_name’ differ in signedness
block-vvfat.c: In function ‘fat_get’:
block-vvfat.c:393: warning: pointer targets in initialization differ in signedness
block-vvfat.c: In function ‘long2unix_name’:
block-vvfat.c:446: warning: pointer targets in passing argument 1 of ‘__builtin_strncpy’ differ in signedness
block-vvfat.c:446: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness
block-vvfat.c:453: warning: pointer targets in passing argument 1 of ‘__builtin_strncpy’ differ in signedness
block-vvfat.c:453: warning: pointer targets in passing argument 2 of ‘__builtin_strncpy’ differ in signedness
block-vvfat.c: In function ‘create_short_filename’:
block-vvfat.c:492: warning: pointer targets in passing argument 1 of ‘__builtin_strncpy’ differ in signedness
block-vvfat.c: In function ‘init_directory’:
block-vvfat.c:719: warning: pointer targets in passing argument 1 of ‘snprintf’ differ in signedness
block-vvfat.c: In function ‘vvfat_write’:
block-vvfat.c:1620: warning: pointer targets in passing argument 1 of ‘long2unix_name’ differ in signedness
make: *** [qemu-img] Erreur 1
bidule:/home/poulp/tmp/qemu-0.7.2#

Voilà, donc si vous pouviez m'aider ça serait cool :oops:

Merci :)

Lien vers le commentaire
Partager sur d’autres sites

depuisquand les sources de kqemu sont dispo ?

c'est nouveau ?

Aucune idée, mais je l'ai toujours vu comme ça ( en même temps toujours ça fait pas beaucoup dans ce cas ;-) )

bah enfait ya un bout a compiler. Sinon c'est pas plutot ln -s /usr/bin/cc /usr/bin/gcc-3.4 ?

tu voulais pas dire plutot ln -s /usr/bin/gcc-3.4 /usr/bin/cc ?

( ça ne résoud pas le problème ) j'ai aussi testé ln -s /usr/bin/gcc-3.4 /usr/bin/gcc :(

Bon, alors finalement j'ai réussi à compiler le truc :)

Pour info, il fallait installer la zlib1g-dev puis effectivement faire un lien : ln -s /usr/bin/gcc-3.4 /usr/bin/gcc :)

Mais bon, petit soucis, mon noyau a été compilé avec gcc 4 alors que j'ai compilé le module avec gcc 3.4 du coup il ne se charge pas, j'aurais du m'en douter :)

Je vous tiens au courant des mes aventures. :)

Lien vers le commentaire
Partager sur d’autres sites

Pas de soucis :)

Pour la suite de l'histoire :

j'ai réussi à compiler le module mais mon noyau étant compilé en gcc 4 et le module en gcc 3.4 ce dernier refusait de se charger. J'ai donc recompilé mon noyau en gcc 3.4.

Mais finalement, qemu déconne et je n'arrive pas à installer correctement une debian.

Lien vers le commentaire
Partager sur d’autres sites

Archivé

Ce sujet est désormais archivé et ne peut plus recevoir de nouvelles réponses.

×
×
  • Créer...