Page 1 of 1
POLINK: error: Unresolved external symbol '__fltused'.
Posted: Wed Sep 22, 2004 2:10 pm
by dmoc
Just upgraded to 3.91 and getting the above error. I've search the forums but the posts about this type of error all seem to be about compiling libs. I'm only compiling PB code (which compiled ok in 3.81). Anyone know the solution?
PS: jaPBe does not report linker errors. I had to used PB's own editor.
Posted: Wed Sep 22, 2004 3:20 pm
by FloHimself
example source to reproduce this?
Posted: Wed Sep 22, 2004 3:24 pm
by dmoc
Bit difficult - last line count was in the thousands!
Posted: Wed Sep 22, 2004 6:23 pm
by GreenGiant
Maybe you have a library with a function named the same as one of the new functions in 3.91 and thats causing a conflict? You could have a look at the list of functions added since 3.81 and see if any ring any bells. Just an idea though, I don't know that that would cause a linker error.
Posted: Wed Sep 22, 2004 6:30 pm
by FloHimself
@greengiant: in that case the compiler will raise a "Duplicated library command" error..
@dmoc: any chance to cut down the source to locate the code causing the linker error?
Posted: Wed Sep 22, 2004 7:38 pm
by GreenGiant
It was this
viewtopic.php?t=12398 that made me think of it. A problem with a native command that was caused by a user library, I assumed because of a duplicated command (doesn't actually say that). Hmm so if it cant be a duplicated command then it seems userlibs can mess up native functions some other way. You could try uninstalling all the userlibs even if they're not being used in the program.
Posted: Wed Sep 22, 2004 7:42 pm
by wichtel
You want an easy exsample to produce the linker error?
Here it is:
Some functions that worked before 3.91 no give this error.
This happens on a fresh installed PC as well, no userlibs at all.
(only jaPBe installed)
Posted: Wed Sep 22, 2004 8:23 pm
by TerryHough
I had a similar error when I first installed 3.91. Worked sometimes, sometimes I got a POLink error.
I don't remember the details, but the Debugger portion of the install was all messed up somehow. I deleted some files, reinstalled, and all was well. At the time I just thought I had done something wrong myself.
Posted: Wed Sep 22, 2004 9:11 pm
by dmoc
Thanks for the suggestions. I will check for conflicting libs although I have already removed a couple of custom commands that PB identified itself and also changed memory allocation code. These changes got me pass the compiler but maybe the compiler isn't catching everything. I imagined Fred could finger the likely problem with no trouble. It maybe my code or some incompatibility with 391 but like I said it compiled fine in 382.
The code is spread between at least a dozen files so I dread the idea of hacking it to bits just to isolate the offending code (if it actually is the code). Maybe I'll try a fresh install - the PB directory is overdue a spring cleaning

Anyway, keep the suggestions coming and thanks.
Posted: Wed Sep 22, 2004 9:39 pm
by GreenGiant
Well if the program is compiling now then you can make use of the handy new OnError commands.
Posted: Thu Sep 23, 2004 12:04 am
by dmoc
@GreenGiant: Yes, if I had a month of Sundays to go through heaps of code! Call me dumb but if I update PB and only change my code where absolutely required then the problem lies elsewhere.
I have now performed a fresh install and copied over three required userlibs: GLU32F, minifmod170 and ScreenEx. Does anyone have a clue about what "fltused" refers to?
Posted: Thu Sep 23, 2004 12:08 am
by jack
Posted: Thu Sep 23, 2004 7:54 am
by Rings
GreenGiant wrote:Well if the program is compiling now then you can make use of the handy new OnError commands.
the new OnError is now over a year included in Purebasic
7. Juni 2003 : Version 3.70
Posted: Thu Sep 23, 2004 1:35 pm
by dmoc
OK, an update: I removed all references to screenex and minifmod170 functions and then removed the actual libs from the libs dir. My guess is minifmod170 is/was causing the linking problem.
My code now compiles and runs but throws up an error. Remembering that this all compiled and ran fine in 382, it now seems to have a file-reading/ memory problem :roll: I had already modified memory management code to do away with mem id's and will now double check this area. In the mean time has anyone come across any gotcha's with files/ file reading/ memory?
Thanks again for the replies.