I'm trying to elevate my app's privileges, to write some audio plugins to a system locations: (/Library/Application Support/Digidesign/Plug-Ins) and (/Library/Audio/Plug-ins/VST3). I am trying to do this in C on OSX.
After "Elevating Privileges Safely" doc from Mac Developer Library, there are several ways to do it, none of them easy at all.
One of them is forking a child process that uses authopen to create and write to a file. After several hours figuring out why XCode does not like to debug, even to run the child process, I've abandoned. The other method suggested by Apple is launchd which is harder at first sight.
So, my question is: does anybody have an 'off-the-shelf' solution example to copy a plugin file in the proper system location elevating privileges?