motorollin
Member
- Joined
- Jul 31, 2007
- Messages
- 163
I have #include-ed mikmod.h in my app and added the following lines to my code:
CODE
MikMod_RegisterAllDrivers();
MikMod_RegisterLoader(&load_mod);
md_mode |= DMODE_SOFT_MUSIC;
MikMod_Init("");
module = Player_Load("snd/stardust.mod", 32, 0 );
if (module) {
Player_Start(module);
while (Player_Active()){
MikMod_Update();
}
Player_Stop();
Player_Free(module);
}else printf("impossible de lire le module\n");
MikMod_Exit();
When I compile I get the following errors:
win/main.o:main.c.text+0x3664): undefined reference to `MikMod_RegisterAllDrivers'
win/main.o:main.c.text+0x366b): undefined reference to `load_mod'
win/main.o:main.c.text+0x3670): undefined reference to `MikMod_RegisterLoader'
win/main.o:main.c.text+0x3677): undefined reference to `md_mode'
win/main.o:main.c.text+0x3680): undefined reference to `md_mode'
win/main.o:main.c.text+0x368c): undefined reference to `MikMod_Init'
win/main.o:main.c.text+0x36a8): undefined reference to `Player_Load'
win/main.o:main.c.text+0x36c3): undefined reference to `Player_Start'
win/main.o:main.c.text+0x36c8): undefined reference to `Player_Active'
win/main.o:main.c.text+0x36d1): undefined reference to `MikMod_Update'
win/main.o:main.c.text+0x36d8): undefined reference to `Player_Stop'
win/main.o:main.c.text+0x36e5): undefined reference to `Player_Free'
win/main.o:main.c.text+0x36f8): undefined reference to `MikMod_Exit'
I have googled the errors but can't find anything in English :blink:
CODE
MikMod_RegisterAllDrivers();
MikMod_RegisterLoader(&load_mod);
md_mode |= DMODE_SOFT_MUSIC;
MikMod_Init("");
module = Player_Load("snd/stardust.mod", 32, 0 );
if (module) {
Player_Start(module);
while (Player_Active()){
MikMod_Update();
}
Player_Stop();
Player_Free(module);
}else printf("impossible de lire le module\n");
MikMod_Exit();
When I compile I get the following errors:
win/main.o:main.c.text+0x3664): undefined reference to `MikMod_RegisterAllDrivers'
win/main.o:main.c.text+0x366b): undefined reference to `load_mod'
win/main.o:main.c.text+0x3670): undefined reference to `MikMod_RegisterLoader'
win/main.o:main.c.text+0x3677): undefined reference to `md_mode'
win/main.o:main.c.text+0x3680): undefined reference to `md_mode'
win/main.o:main.c.text+0x368c): undefined reference to `MikMod_Init'
win/main.o:main.c.text+0x36a8): undefined reference to `Player_Load'
win/main.o:main.c.text+0x36c3): undefined reference to `Player_Start'
win/main.o:main.c.text+0x36c8): undefined reference to `Player_Active'
win/main.o:main.c.text+0x36d1): undefined reference to `MikMod_Update'
win/main.o:main.c.text+0x36d8): undefined reference to `Player_Stop'
win/main.o:main.c.text+0x36e5): undefined reference to `Player_Free'
win/main.o:main.c.text+0x36f8): undefined reference to `MikMod_Exit'
I have googled the errors but can't find anything in English :blink: