(C++)
I am trying to use a library called LIBWMP3. I tryed to link using Dev-C++ but I get a linking error. Here is the code and the error.
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
|
#include <cstdlib>
#include <iostream>
#include "libwmp3.h"
using namespace std;
int main()
{
/* create class instance */
CWMp3* mp3 = CreateCWMp3();
/* open file from disk */
mp3->OpenFile("Believe.mp3",800, 0, 0);
mp3->Play();
/* ... wait here in some loop */
MP3_STATUS status;
mp3->GetStatus(&status);
while(status.fPlay)
{
Sleep(200);
mp3->GetStatus(&status);
}
/* destroy class instance */
mp3->Release();
}
|
Error:
-----------------
File format not recognized
ld returned 1 exit status
C:\C++\Library testing\Makefile.win [Build Error] [Project2.exe] Error 1
-----------------
Compile Log:
-----------------
Compiler: Default compiler
Building Makefile: "C:\C++\Library testing\Makefile.win"
Executing make...
make.exe -f "C:\C++\Library testing\Makefile.win" all
g++.exe main.o -o "Project2.exe" -L"C:/Dev-Cpp/lib" -lwinmm ../libwmp3-2.51-win/libwmp3.lib
../libwmp3-2.51-win/libwmp3.lib: file not recognized: File format not recognized
collect2: ld returned 1 exit status
make.exe: *** [Project2.exe] Error 1
Execution terminated
------------------
I have the libmp3.lib in my project options, parameters tab and the proper include. Any help would be useful I cannot find any support for this error on Dev-C++ whatsoever. Here is a link to the main website of the library.
http://www.inet.hr/~zcindori/libwmp3/index.html
I am using Dev-C++, vista 32-bit.
Also here is a list of the files from the library.
dsp_superequ.txt
GPL.txt
LGPL.txt
libmad_copyright.txt
libmad_readme.txt
LIBWMP3.txt
libwmp3.d
libwmp3.dll
libwmp3.h
libwmp3.lib
LIBWMP3 (Delphi source file)
LIBWMP3 (VB File)
mp3.d
Readme.txt
|
Thankyou.
PS. There is 0 support on this topic that I could find on the Dev-C++ website.
If any more info is needed please let me know.