Xcode DBG( ) attach to process


#1

Hello,

I have a question about debugging in XCode. When I run a stand-alone application, I can use the DBG macro, in order to show output on the XCode debug output console. 

But that does not work, when I want to debug my audio plugin from inside Garage Band, by "attach to process". Nothing is showing up in the Xcode debug console. Can someone give me a hint, what I need to do? 


#2

I'm pretty sure I've used that in lots of hosts. Is it loading the release build, perhaps?


#3

Its in Debug Mode. 

I use the following construct to check:

#if JUCE_DEBUG

    Logger::writeToLog("Debug Mode");

#else

    Logger::writeToLog("Release Mode");

#endif

And it says "Debug" (redirected the otput to a file). 

PS: I am using XCode 5.1.1, in case that should make any difference.


#4

Dunno. Try another host, it could be garageband messing with the console streams.


#5

Actually it is the same from within the Juce plugin host demo.

I guess the next step would be to test with a non-Juce plugin, to see if this is Juce related or not. But I don't know how to do that. Maybe this is a general XCode lldb problem. Byt most probably just an option, I am missing somewhere... :-)

 

 

 


#6

Why don't you just launch the host as a custom executable, DBG statements will work this way. I'm not quite sure why they fail if you attach a process afterwards but if you find out let me know!