bonjour;
je suis élève ingénieur et j'ai un problème lors de la compilation de mon prg les détails sont la suivant:
je travail sur QT intégrer sous eclipse (OS:windows).
lors de la compilation d'une main simple (c-à-d un int main(int argc, char *argv[]) { printf("helloword"); return0;}) tout est parfait.Mais lorsque je fait l'intégration de mon prg qui est la suivant:
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 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83
|
/************************************************************************************************/
#include "premier_pa.h"
#include <QtGui>
#include <QApplication>
#include "asf.h"
static void
print_metadata(asf_metadata_t *metadata) {
int i;
printf("----- PRINT METADATA -----\n");
if (metadata->title)
printf("title: %s\n", metadata->title);
if (metadata->artist)
printf("artist: %s\n", metadata->artist);
if (metadata->copyright)
printf("copyright: %s\n", metadata->copyright);
if (metadata->description)
printf("description: %s\n", metadata->description);
if (metadata->rating)
printf("rating: %s\n", metadata->rating);
for (i=0; i<metadata->extended_count; i++) {
printf("\"%s\" - \"%s\"\n", metadata->extended[i].key, metadata->extended[i].value);
}
printf("----- END METADATA -----\n");
}
int main(int argc, char *argv[]) {
asf_file_t *file;
asf_metadata_t *metadata;
asf_packet_t *pkt;
int i;
if (argc != 2) {
printf("Incorrect number of arguments\n");
return -1;
}
file = asf_open_file(argv[1]);
if (!file) {
printf("Error opening file %s\n", argv[1]);
return -1;
}
asf_init(file);
metadata = asf_header_get_metadata(file);
if (metadata) {
print_metadata(metadata);
asf_metadata_destroy(metadata);
}
pkt = asf_packet_create();
for (i=0; i<10; i++) {
int tmp;
if ((tmp = asf_seek_to_msec(file, (uint64_t) i*1000)) < 0) {
printf("Seek failed\n");
}
if ((tmp = asf_get_packet(file, pkt)) < 0) {
printf("Error %d getting packet\n", tmp);
break;
}
if (!tmp) {
printf("EOF found\n");
break;
}
}
asf_packet_destroy(pkt);
/*
printf("position after seek %lld\n",
asf_seek_to_msec(file, 18000));
*/
asf_close(file);
return 0;
}
/********************************************************************************************************/ |
sachant que j'ai tout les fichier .h et .c de toutes les fonctions il m'affiche la liste d'erreur suivante:
mingw32-make debug
mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory `E:/wseclipsemingw/premier_pa'
g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -DQT_NEEDS_QMAIN -I"c:\Qt\4.4.3\include\QtCore" -I"c:\Qt\4.4.3\include\QtCore" -I"c:\Qt\4.4.3\include\QtGui" -I"c:\Qt\4.4.3\include\QtGui" -I"c:\Qt\4.4.3\include" -I"c:\Qt\4.4.3\include\ActiveQt" -I"debug" -I"." -I"c:\Qt\4.4.3\mkspecs\default" -o debug\main.o main.cpp
g++ -enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runtime-pseudo-reloc -mthreads -Wl -Wl,-subsystem,windows -o debug\premier_pa.exe object_script.premier_pa.Debug -L"c:\Qt\4.4.3\lib" -lmingw32 -lqtmaind -lQtGuid4 -lQtCored4
./debug\main.o(.text+0x23e): In function `Z5qMainiPPc':
E:/wseclipsemingw/premier_pa/main.cpp:41: undefined reference to `asf_open_file(char const*)'
./debug\main.o(.text+0x276):E:/wseclipsemingw/premier_pa/main.cpp:47: undefined reference to `asf_init(asf_file_s*)'
./debug\main.o(.text+0x281):E:/wseclipsemingw/premier_pa/main.cpp:48: undefined reference to `asf_header_get_metadata(asf_file_s*)'
./debug\main.o(.text+0x2a0):E:/wseclipsemingw/premier_pa/main.cpp:51: undefined reference to `asf_metadata_destroy(asf_metadata_s*)'
./debug\main.o(.text+0x2a5):E:/wseclipsemingw/premier_pa/main.cpp:54: undefined reference to `asf_packet_create()'
./debug\main.o(.text+0x2d0):E:/wseclipsemingw/premier_pa/main.cpp:58: undefined reference to `asf_seek_to_msec(asf_file_s*, long long)'
./debug\main.o(.text+0x2f8):E:/wseclipsemingw/premier_pa/main.cpp:62: undefined reference to `asf_get_packet(asf_file_s*, asf_packet_s*)'
./debug\main.o(.text+0x33f):E:/wseclipsemingw/premier_pa/main.cpp:72: undefined reference to `asf_packet_destroy(asf_packet_s*)'
./debug\main.o(.text+0x34a):E:/wseclipsemingw/premier_pa/main.cpp:77: undefined reference to `asf_close(asf_file_s*)'
collect2: ld returned 1 exit status
mingw32-make[1]: Leaving directory `E:/wseclipsemingw/premier_pa'
mingw32-make[1]: *** [debug\premier_pa.exe] Error 1
mingw32-make: *** [debug] Error 2
j'ai déja cherché sur les forum mais rien de nouveau
j'ai besoin de l'aide et je suis à votre disposition pour tout autre détail
Merci d'avance pour tout aide
Partager