From 58453a6b7d7a03f61eee6fd8ff6c4a9617b94fe6 Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Fri, 5 Aug 2022 22:18:30 -0700 Subject: [PATCH] [Cog Audio] Rename Semaphore.h to CogSemaphore.h This magically fixes the stupid header maps that were pulling the system semaphore.h into Swift projects, when they shouldn't have been doing that in the first place. This is the same reason that the FLAC library has its assert.h renamed to FLAC_assert.h. Signed-off-by: Christopher Snowhill --- Audio/AudioPlayer.h | 2 +- Audio/Chain/ChunkList.h | 2 +- Audio/Chain/Node.h | 2 +- Audio/CogAudio.xcodeproj/project.pbxproj | 16 ++++++++-------- Audio/Utils/{Semaphore.h => CogSemaphore.h} | 2 +- Audio/Utils/{Semaphore.m => CogSemaphore.m} | 4 ++-- 6 files changed, 14 insertions(+), 14 deletions(-) rename Audio/Utils/{Semaphore.h => CogSemaphore.h} (94%) rename Audio/Utils/{Semaphore.m => CogSemaphore.m} (92%) diff --git a/Audio/AudioPlayer.h b/Audio/AudioPlayer.h index f51fedb64..32cdaa66a 100644 --- a/Audio/AudioPlayer.h +++ b/Audio/AudioPlayer.h @@ -8,7 +8,7 @@ #import -#import +#import #import #import diff --git a/Audio/Chain/ChunkList.h b/Audio/Chain/ChunkList.h index 105e8ff53..f025ca886 100644 --- a/Audio/Chain/ChunkList.h +++ b/Audio/Chain/ChunkList.h @@ -10,7 +10,7 @@ #import "AudioChunk.h" -#import +#import NS_ASSUME_NONNULL_BEGIN diff --git a/Audio/Chain/Node.h b/Audio/Chain/Node.h index f03d3c8fb..a5fe9dfac 100644 --- a/Audio/Chain/Node.h +++ b/Audio/Chain/Node.h @@ -7,7 +7,7 @@ // #import "ChunkList.h" -#import +#import #import #import diff --git a/Audio/CogAudio.xcodeproj/project.pbxproj b/Audio/CogAudio.xcodeproj/project.pbxproj index 19ffc8f99..ee2d6d55e 100644 --- a/Audio/CogAudio.xcodeproj/project.pbxproj +++ b/Audio/CogAudio.xcodeproj/project.pbxproj @@ -28,8 +28,8 @@ 17D21CC50B8BE4BA00D1EBDE /* OutputAVFoundation.h in Headers */ = {isa = PBXBuildFile; fileRef = 17D21C9C0B8BE4BA00D1EBDE /* OutputAVFoundation.h */; settings = {ATTRIBUTES = (Public, ); }; }; 17D21CC60B8BE4BA00D1EBDE /* OutputAVFoundation.m in Sources */ = {isa = PBXBuildFile; fileRef = 17D21C9D0B8BE4BA00D1EBDE /* OutputAVFoundation.m */; }; 17D21CC70B8BE4BA00D1EBDE /* Status.h in Headers */ = {isa = PBXBuildFile; fileRef = 17D21C9E0B8BE4BA00D1EBDE /* Status.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 17D21CF30B8BE5EF00D1EBDE /* Semaphore.h in Headers */ = {isa = PBXBuildFile; fileRef = 17D21CF10B8BE5EF00D1EBDE /* Semaphore.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 17D21CF40B8BE5EF00D1EBDE /* Semaphore.m in Sources */ = {isa = PBXBuildFile; fileRef = 17D21CF20B8BE5EF00D1EBDE /* Semaphore.m */; }; + 17D21CF30B8BE5EF00D1EBDE /* CogSemaphore.h in Headers */ = {isa = PBXBuildFile; fileRef = 17D21CF10B8BE5EF00D1EBDE /* CogSemaphore.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 17D21CF40B8BE5EF00D1EBDE /* CogSemaphore.m in Sources */ = {isa = PBXBuildFile; fileRef = 17D21CF20B8BE5EF00D1EBDE /* CogSemaphore.m */; }; 17D21DAD0B8BE76800D1EBDE /* AudioToolbox.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 17D21DA90B8BE76800D1EBDE /* AudioToolbox.framework */; }; 17D21DAE0B8BE76800D1EBDE /* AudioUnit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 17D21DAA0B8BE76800D1EBDE /* AudioUnit.framework */; }; 17D21DAF0B8BE76800D1EBDE /* CoreAudio.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 17D21DAB0B8BE76800D1EBDE /* CoreAudio.framework */; }; @@ -168,8 +168,8 @@ 17D21C9C0B8BE4BA00D1EBDE /* OutputAVFoundation.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = OutputAVFoundation.h; sourceTree = ""; }; 17D21C9D0B8BE4BA00D1EBDE /* OutputAVFoundation.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = OutputAVFoundation.m; sourceTree = ""; }; 17D21C9E0B8BE4BA00D1EBDE /* Status.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Status.h; sourceTree = ""; }; - 17D21CF10B8BE5EF00D1EBDE /* Semaphore.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = Semaphore.h; sourceTree = ""; }; - 17D21CF20B8BE5EF00D1EBDE /* Semaphore.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = Semaphore.m; sourceTree = ""; }; + 17D21CF10B8BE5EF00D1EBDE /* CogSemaphore.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = CogSemaphore.h; sourceTree = ""; }; + 17D21CF20B8BE5EF00D1EBDE /* CogSemaphore.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = CogSemaphore.m; sourceTree = ""; }; 17D21DA90B8BE76800D1EBDE /* AudioToolbox.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioToolbox.framework; path = /System/Library/Frameworks/AudioToolbox.framework; sourceTree = ""; }; 17D21DAA0B8BE76800D1EBDE /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = /System/Library/Frameworks/AudioUnit.framework; sourceTree = ""; }; 17D21DAB0B8BE76800D1EBDE /* CoreAudio.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreAudio.framework; path = /System/Library/Frameworks/CoreAudio.framework; sourceTree = ""; }; @@ -451,8 +451,8 @@ 8347C73F2796C58800FA8A7D /* NSFileHandle+CreateFile.h */, 8347C7402796C58800FA8A7D /* NSFileHandle+CreateFile.m */, 8384912618080FF100E7332D /* Logging.h */, - 17D21CF10B8BE5EF00D1EBDE /* Semaphore.h */, - 17D21CF20B8BE5EF00D1EBDE /* Semaphore.m */, + 17D21CF10B8BE5EF00D1EBDE /* CogSemaphore.h */, + 17D21CF20B8BE5EF00D1EBDE /* CogSemaphore.m */, ); path = Utils; sourceTree = ""; @@ -611,7 +611,7 @@ 83B74281289E027F005AAC28 /* CogAudio-Bridging-Header.h in Headers */, 831A4FE12865A7DC0049CFE4 /* pf_neon_double.h in Headers */, 17D21CC70B8BE4BA00D1EBDE /* Status.h in Headers */, - 17D21CF30B8BE5EF00D1EBDE /* Semaphore.h in Headers */, + 17D21CF30B8BE5EF00D1EBDE /* CogSemaphore.h in Headers */, 839E56E62879450300DFB5F4 /* Endianness.h in Headers */, 17D21DC70B8BE79700D1EBDE /* CoreAudioUtils.h in Headers */, 839E56ED2879515D00DFB5F4 /* HeadphoneFilter.h in Headers */, @@ -743,7 +743,7 @@ 835C88B2279811A500E28EAE /* hdcd_decode2.c in Sources */, 835FAC5F27BCA14D00BA8562 /* BadSampleCleaner.m in Sources */, 834FD4ED27AF91220063BC83 /* AudioChunk.m in Sources */, - 17D21CF40B8BE5EF00D1EBDE /* Semaphore.m in Sources */, + 17D21CF40B8BE5EF00D1EBDE /* CogSemaphore.m in Sources */, 839B83FA286D91ED00F529EE /* VisualizationController.swift in Sources */, 8347C7422796C58800FA8A7D /* NSFileHandle+CreateFile.m in Sources */, 17D21DC80B8BE79700D1EBDE /* CoreAudioUtils.m in Sources */, diff --git a/Audio/Utils/Semaphore.h b/Audio/Utils/CogSemaphore.h similarity index 94% rename from Audio/Utils/Semaphore.h rename to Audio/Utils/CogSemaphore.h index 91813808c..345fef959 100644 --- a/Audio/Utils/Semaphore.h +++ b/Audio/Utils/CogSemaphore.h @@ -1,5 +1,5 @@ // -// Semaphore.h +// CogSemaphore.h // Cog // // Created by Vincent Spader on 8/2/05. diff --git a/Audio/Utils/Semaphore.m b/Audio/Utils/CogSemaphore.m similarity index 92% rename from Audio/Utils/Semaphore.m rename to Audio/Utils/CogSemaphore.m index dc19f1299..f8a1c5655 100644 --- a/Audio/Utils/Semaphore.m +++ b/Audio/Utils/CogSemaphore.m @@ -1,12 +1,12 @@ // -// Semaphore.m +// CogSemaphore.m // Cog // // Created by Vincent Spader on 8/2/05. // Copyright 2005 Vincent Spader. All rights reserved. // -#import "Semaphore.h" +#import @implementation Semaphore