10.4 and JUCE/AudioPlugin


#1

I just tried creating a new project in the new jucer, an audio plugin. I wanted to build it against 10.4SDK so i changed the base SDK and GCC to 4.0 (otherwise XCode says gcc 4.2 is incopatible). And i get errors but not in JUCE code but in AU code includes in the project, so i was wondering how to fix this (i’m on 10.6)

CompileC build/TestPlug.build/Debug/TestPlug.build/Objects-normal/i386/CAAudioChannelLayout.o /Developer/Extras/CoreAudio/PublicUtility/CAAudioChannelLayout.cpp normal i386 c++ com.apple.compilers.gcc.4_0
cd /Users/atom/devel/Builds/MacOSX
setenv LANG en_US.US-ASCII
/Developer/usr/bin/gcc-4.0 -x c++ -arch i386 -fmessage-length=0 -pipe -Wno-trigraphs -fpascal-strings -fasm-blocks -O0 -Wreturn-type -Wnon-virtual-dtor -Wformat -Wparentheses -Wswitch -Wunused-variable -DJUCER_XCODE_MAC_F6D2F4CF=1 -D_DEBUG=1 -DDEBUG=1 -isysroot /Developer/SDKs/MacOSX10.4u.sdk -fvisibility-inlines-hidden -mmacosx-version-min=10.4 -gdwarf-2 -iquote /Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/TestPlug-generated-files.hmap -I/Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/TestPlug-own-target-headers.hmap -I/Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/TestPlug-all-target-headers.hmap -iquote /Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/TestPlug-project-headers.hmap -F/Users/atom/devel/Builds/MacOSX/build/Debug -I/Users/atom/devel/Builds/MacOSX/build/Debug/include -I/Users/atom/devel/vstsdk2.4 -I/Developer/Extras/CoreAudio/PublicUtility -I/Developer/Extras/CoreAudio/AudioUnits/AUPublic/Utility -I/Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/DerivedSources/i386 -I/Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/DerivedSources -w -c /Developer/Extras/CoreAudio/PublicUtility/CAAudioChannelLayout.cpp -o /Users/atom/devel/Builds/MacOSX/build/TestPlug.build/Debug/TestPlug.build/Objects-normal/i386/CAAudioChannelLayout.o

/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicAdd32Barrier(SInt32, volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:79: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:79: error:   initializing argument 2 of 'int32_t OSAtomicAdd32Barrier(int32_t, int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicOr32Barrier(UInt32, volatile UInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:93: error: invalid conversion from 'volatile uint32_t*' to 'uint32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:93: error:   initializing argument 2 of 'int32_t OSAtomicOr32Barrier(uint32_t, uint32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicAnd32Barrier(UInt32, volatile UInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:107: error: invalid conversion from 'volatile uint32_t*' to 'uint32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:107: error:   initializing argument 2 of 'int32_t OSAtomicAnd32Barrier(uint32_t, uint32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'bool CAAtomicCompareAndSwap32Barrier(SInt32, SInt32, volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:120: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:120: error:   initializing argument 3 of 'bool OSAtomicCompareAndSwap32Barrier(int32_t, int32_t, int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicIncrement32(volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:130: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:130: error:   initializing argument 1 of 'int32_t OSAtomicIncrement32(int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicDecrement32(volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:139: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:139: error:   initializing argument 1 of 'int32_t OSAtomicDecrement32(int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicIncrement32Barrier(volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:148: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:148: error:   initializing argument 1 of 'int32_t OSAtomicIncrement32Barrier(int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'SInt32 CAAtomicDecrement32Barrier(volatile SInt32*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:157: error: invalid conversion from 'volatile int32_t*' to 'int32_t*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:157: error:   initializing argument 1 of 'int32_t OSAtomicDecrement32Barrier(int32_t*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'bool CAAtomicTestAndClearBarrier(int, void*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:167: error: invalid conversion from 'volatile void*' to 'void*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:167: error:   initializing argument 2 of 'bool OSAtomicTestAndClearBarrier(uint32_t, void*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'bool CAAtomicTestAndClear(int, void*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:177: error: invalid conversion from 'volatile void*' to 'void*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:177: error:   initializing argument 2 of 'bool OSAtomicTestAndClear(uint32_t, void*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'bool CAAtomicTestAndSetBarrier(int, void*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:187: error: invalid conversion from 'volatile void*' to 'void*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:187: error:   initializing argument 2 of 'bool OSAtomicTestAndSetBarrier(uint32_t, void*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'void CASpinLockLock(volatile CASpinLock*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:262: error: invalid conversion from 'volatile CASpinLock*' to 'OSSpinLock*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:262: error:   initializing argument 1 of 'void OSSpinLockLock(OSSpinLock*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'void CASpinLockUnlock(volatile CASpinLock*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:272: error: invalid conversion from 'volatile CASpinLock*' to 'OSSpinLock*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:272: error:   initializing argument 1 of 'void OSSpinLockUnlock(OSSpinLock*)'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h: In function 'bool CASpinLockTry(volatile CASpinLock*)':
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:281: error: invalid conversion from 'volatile CASpinLock*' to 'OSSpinLock*'
/Developer/Extras/CoreAudio/PublicUtility/CAAtomic.h:281: error:   initializing argument 1 of 'bool OSSpinLockTry(OSSpinLock*)'

#2

Yeah, you need to make sure that the SDK and Apple AU files are compatible. There have been other threads about this on the forum, though not sure what keywords to search for to find them!


#3

ok i’ll look


#4

I wasn’t able to use the 10.4 SDK for my latest plugin (http://www.valhalladsp.com/shimmer.html). However, I have built 10.4 compatible plugins by using the 10.5 SDK, and having 10.4 as a target. Use gcc 4.0.

Sean Costello