Re: Debugging an AudioServer plugin
Re: Debugging an AudioServer plugin
- Subject: Re: Debugging an AudioServer plugin
- From: Eric Gorouben <email@hidden>
- Date: Tue, 12 Mar 2013 22:24:21 +0100
From the xcode gurus:
> Yeah, there seems to be a bug if you use Product > Attach to Process.
>
> But I was able to get it to work if I set up a new Scheme and use the Scheme to debug as Root and to do a wait for. You should be prompted to enter the administrator password.
It works!
Eric
Le 7 mars 2013 à 20:20, Eric Gorouben <email@hidden> a écrit :
> Well, I've tried to ask xcode to wait for coreaudiod, or to run coreaudiod, etc. xcode allows to attach to a process or run as root. However, this doesn't work.
> I've also tried to run xcode as root, and everything is fine, except that my plugin crashes constantly...
>
> Does anybody have successfully debugged an AudioServer plugin using xcode around there?
>
> Otherwise I'll ask on the xcode list.
>
> Thanks
> Eric
> Le 7 mars 2013 à 20:06, Jeff Moore <email@hidden> a écrit :
>
>> Honestly, I've never actually tried =)
>>
>> At any rate, it may be feasible. I know Xcode has some functionality for attaching the debugger to processes. For instance, you can set the executable in your Scheme to be coreaudiod and tell it to wait for it to launch. The real problem is that you have to be running the debugger as root to attach to coreaudiod. I don't know if Xcode will let you do that.
>>
>> If you come up with a good way to do this, please post your procedure so others can follow it. I'm sure having the GUI will make life a little easier for everybody.
>>
>> --
>>
>> Jeff Moore
>> Core Audio
>> Apple
>>
>>
>>
>> On Mar 7, 2013, at 11:01 AM, Eric Gorouben <email@hidden> wrote:
>>
>>> Thanks Jeff. Is it possible to have lldb/gdb working within xcode to have the gui?
>>> Eric
>>> Le 7 mars 2013 à 19:41, Jeff Moore <email@hidden> a écrit :
>>>
>>>> The right way to debug coreaudiod at startup is:
>>>>
>>>> 0) Unload coreaudiod
>>>> % sudo launchctl unload /System/Library/LaunchDaemons/com.apple.audio.coreaudiod.plist
>>>>
>>>> 1) Start lldb/gdb up such that they await the launch of coreaudiod (note that you need to be root to debug coreaudiod):
>>>> % sudo lldb --wait-for coreaudiod
>>>>
>>>> 2) Start coreaudiod again:
>>>> % sudo launchctl load /System/Library/LaunchDaemons/com.apple.audio.coreaudiod.plist
>>>>
>>>> --
>>>>
>>>> Jeff Moore
>>>> Core Audio
>>>> Apple
>>>>
>>>>
>>>>
>>>> On Mar 7, 2013, at 9:14 AM, Eric Gorouben <email@hidden> wrote:
>>>>
>>>>> I'm trying to debug my AudioServer plugin with xcode 4.6 and Mac OS 10.8.2.
>>>>> Therefore, I want to attach the debugger to coreaudiod and restart it. But it doesn't work.
>>>>> What is he proper recipe for this?
>>>>
>>>>
>>>> _______________________________________________
>>>> Do not post admin requests to the list. They will be ignored.
>>>> Coreaudio-api mailing list (email@hidden)
>>>> Help/Unsubscribe/Update your Subscription:
>>>>
>>>> This email sent to email@hidden
>>>
>>>
>>> _______________________________________________
>>> Do not post admin requests to the list. They will be ignored.
>>> Coreaudio-api mailing list (email@hidden)
>>> Help/Unsubscribe/Update your Subscription:
>>>
>>> This email sent to email@hidden
>>
>>
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> Coreaudio-api mailing list (email@hidden)
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Coreaudio-api mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden