ld error when trying to include mikmodlib

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
matkeupon
Posts: 26
Joined: Sat Jul 02, 2005 10:58 pm

ld error when trying to include mikmodlib

Post by matkeupon »

Hi,

I'm trying to add music to my game, and I'm having trouble including mikmodlib to my project. I compiled the lib with no problem, and compiled the example included. But when I add and use the lib in my project, ld returns this error:

Code: Select all

load_uni.c:22: relocation truncated to fit: R_MIPS_GPREL16 against 'modfp'
Well, a dozen of them actually. And the last says 'load_uni.c:71: additional relocation overflows omitted from the output'

I don't know what those errors mean, and I don't know why the example compiles fine.

Thanks in advance for any help.

mATkEUpON
matkeupon
Posts: 26
Joined: Sat Jul 02, 2005 10:58 pm

Post by matkeupon »

Well, made it run anyways. I had to change a few globals to static, and it compiled and ran just fine in my game :)

If anyone has the same problem, feel free to pm me.
User avatar
Jim
Posts: 476
Joined: Sat Jul 02, 2005 10:06 pm
Location: Sydney
Contact:

Post by Jim »

Sounds like one of the modules (either yours or mikmodlib) have been built using the global base register option. I think this might be the -G option.

Jim
Post Reply