auval says "Cannot open component: -1"

SDK for VST 3 audio plug-in and host development.
Post Reply
howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

auval says "Cannot open component: -1"

Post by howardantares »

I have made an AudioUnit plug-in component following the again/auwrapper guidelines, but when auval (-a) runs, it says "Cannot open component: -1". When run it with -v and the three id values, it says:
...
--------------------------------------------------
TESTING OPEN TIMES:
COLD:
FATAL ERROR: OpenAComponent: result: -1,0xFFFFFFFF
Any ideas on what might be wrong? It recognizes the Manufacturer String, the three IDs, and the Component version correctly (and says "PASS" for that first section), but won't open. Could having spaces in the Audio Unit Name be a problem? There are no spaces in the "Bundle name", which matches the "Executable file". The plugin.vst3 has been written to the Contents/Resources folder. I'm stumped.

When I try to debug, it doesn't stop on any breakpoints in the auwrapper.mm file. It just gives me that fatal error.

Any thoughts as to how I can find out what's wrong?

willpirkle
Posts: 67
Joined: Tue Jun 21, 2016 12:53 pm

Re: auval says "Cannot open component: -1"

Post by willpirkle »

Not sure what your problem is, but I have AU's with spaces in the Audio Unit Name that pass validation.

I do not use the AU Wrapper though, mine are native AUs.

- Will

howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

Re: auval says "Cannot open component: -1"

Post by howardantares »

Yeah, it's not the spaces. Took those out and it still won't load. It's as if the plugin.vst3 file is not there, or is not recognized as a VST3 component. But I can't even debug using auvaltool. It runs, and the output shows in the debug window, but it doesn't stop on any breakpoints, and no NSLog statements I add ever get executed, no matter where I put them. Is there something I need to do to the VST3 plug-in that is different under VST3 SDK v3.6.6 than in earlier versions, that is not reflected in the auwrapper's doc.cpp comments?

Arne Scheffler
Posts: 383
Joined: Mon Jun 20, 2016 7:53 am

Re: auval says "Cannot open component: -1"

Post by Arne Scheffler »

howardantares wrote:Is there something I need to do to the VST3 plug-in that is different under VST3 SDK v3.6.6 than in earlier versions, that is not reflected in the auwrapper's doc.cpp comments?
Not that I know of. Did you update the CoreAudio Utility classes ?

howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

Re: auval says "Cannot open component: -1"

Post by howardantares »

I have what seems to be the most recent CoreAudioUtilityClasses, although they don't appear to have been updated since 2014. I got them from https://developer.apple.com/library/con ... Intro.html. Isn't that the latest?

The auwrapper library builds fine, as does my wrapper copied and modified from the again project inside the auwrapper folder, as well as my VST3 project, which copies the product into the .component/Contents/Resources folder as plugin.vst3. But auvaltool acts as if it is not there, and I can't get it to stop in the debugger (at least when I hit Run from my VST3 project, which includes the wrapper component project and the auwrapper library project).

The only obvious difference I see between this new project and the one from the field that was built several years ago is the addition of a section in the .plist called "AudioComponents". Naturally, the binary contents are different, but those things that I can examine look the same to me.

howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

Re: auval says "Cannot open component: -1"

Post by howardantares »

If I build the again project itself, I get several duplicate symbol errors:
duplicate symbol __ZN12AUBaseLookup6LookupEs in:
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(AUPlugInDispatch.o)
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(ausdk.o)
duplicate symbol __ZN19AUBaseProcessLookup6LookupEs in:
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(AUPlugInDispatch.o)
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(ausdk.o)
duplicate symbol __ZN27AUBaseProcessMultipleLookup6LookupEs in:
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(AUPlugInDispatch.o)
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(ausdk.o)
duplicate symbol __ZN13AUMusicLookup6LookupEs in:
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(AUPlugInDispatch.o)
/Software_Development/SDKs/VST/VST3 SDK/public.sdk/source/vst/auwrapper/build/Debug/libauwrapper.a(ausdk.o)
ld: 10 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I can get it to build by changing OTHER_LDFLAGS to include only libauwrapper.a. HOWEVER, once I do that, then again has the SAME problem that it will not load.

So I'm guessing that the issue is something is not linking that should. But other than linking explicitly to libauwrapper.a, how can I resolve the duplicate symbols?

Arne Scheffler
Posts: 383
Joined: Mon Jun 20, 2016 7:53 am

Re: auval says "Cannot open component: -1"

Post by Arne Scheffler »

Hi Howard,
you must have modified the au wrapper project otherwise you would not get these linker errors. But anyway, this can not be the reason for the auval failure. Try to get rid of the "AudioComponents" section in the plist, if I remember correctly the AU stuff in the SDK was built with an earlier version of the CoreAudio utility classes and there maybe changes that result in the failure you see.

howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

Re: auval says "Cannot open component: -1"

Post by howardantares »

You are right about my modifying the project. I had an old note to remove a couple of non-existent files and replace them with the AUPlugInDispatch files. I guess that's no longer what I want to do. So I removed those two files from the again project and it builds now. It now loads in auval, but gives me an error -4 doing the Render Test at 512 frames.

My own project, however, still gives me -1. If I simply remove the AudioComponents section, it gives me error -50 and still cannot open.

I notice one thing: the binary for the again project (inside again.component/Contents/MacOS) is 866k. The binary for my project is only 17k! Something is not being linked, apparently, when creating the wrapper component.

howardantares
Posts: 130
Joined: Tue Jun 21, 2016 1:46 pm

Re: auval says "Cannot open component: -1"

Post by howardantares »

I found what was missing! Apparently, the Link Binary With Libraries step lost the libauwrapper.a entry somehow. Now it's building and gets further into the auval test.

(I suspect part of the reason it got lost is because Xcode does NOT like when you have a sub-project open in two different projects, and it disables access to it in the project that is opened second. While trying to compare mine against again, I probably removed and was unable to add it back properly.)

Now it is failing with the Format Tests, saying it cannot initialize the unit for 1-1, 1-2 or 2-2 inputs-outputs.

At least it opens now.

Post Reply