gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > Help : How to use the DSMI library ?!

#170648 - Ben_j - Fri Oct 09, 2009 2:33 pm

Hi
I'm not new to DS developpement, I did a homebrew a few years ago. I've just come back to DS developpement, but somehow, I can't figure an answer to a dumb problem.

I use PAlib and used the PALib template project to do my stuff. I also wanna use libdsmi (MIDI library for the DS. I already used it in my first homebrew program), I placed the libdsmi.h and libdsmi.a in the libnds directory, as stated in the libdsmi doc, but when I build the project, it says "undefined reference to `dsmi_connect'", dsmi_connect being a function of the dsmi lib.
I've got everything ready for some hot coding, and it's the only thing that's getting on my way now. I'm out of ideas here, and the solution is probably simple, but if someone can help, it would be nice :)

#170653 - a128 - Fri Oct 09, 2009 4:00 pm

you have to link the lib with your project
_________________
"Hey! It compiles! Ship it!"

#170659 - Ben_j - Fri Oct 09, 2009 5:13 pm

a128 wrote:
you have to link the lib with your project


How do I do that ? It's been 3 years since I've done a Makefile :s

And I think the PALib makefile automatically links the libraries

EDIT : OK I finally figured that out. just had to add -ldsmi in the PA_Makefile, before -ldswifi9

Working fine now !