ListBoxModel and SparseSet question (linking error)

Hi Everybody!

I’ve got a linking error, when I use a ListBoxModel (like in DragAndDropDemo) in my project, in Debug mode.

[quote]1>ObjectPanel.obj : error LNK2019: unresolved external symbol “bool __stdcall juce::juce_isRunningUnderDebugger(void)” (?juce_isRunningUnderDebugger@juce@@YG_NXZ) referenced in function "public: int __thiscall juce::Array<int,class juce::DummyCriticalSection>::getUnchecked(int)const " (?getUnchecked@?$Array@HVDummyCriticalSection@juce@@@juce@@QBEHH@Z)
1>…\bin\LeoStartd.exe : fatal error LNK1120: 1 unresolved externals[/quote]

I think, the trouble appears, when I get selectedRows[i]:

[quote]const String ObjectList::getDragSourceDescription(const SparseSet& selectedRows)
{
String desc;
for(int i = 0; i < selectedRows.size(); ++i)
desc << (selectedRows [i] + 1) << T(" ");
return desc.trim();
}[/quote]

The jucedemo compiled correctly (in Debug mode), but I can’t compile my project, only in Release mode. Can anybody help me? Thanks a lot!

Best regards

Goldmund

Did you try a clean rebuild? That symbol is right there in juce_win32_Threads.cpp, so shouldn’t cause any problems.

(Or if you’re using an old juce version, try grabbing the latest one from SVN)

Yes, I did (clean & rebuild).

I used version 1.45 (2007.10.10.), so I tried to use the latest version too (I checked this out from SVN), but the result is same :?

And you’re positive that you’re trying to link to the correct target lib? There must be something screwy with your build, because that’s a straightforward bit of code that’s used all over the place.