Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

EZAudio CocoaPods module import error

When adding EZAudio to my swift project using CocoaPods, I get a compiler error that says:
Could not build Objective-C module 'EZAudio'

My Podfile is this:

platform :ios, '9'
use_frameworks!

pod 'CorePlot'
pod 'SWRevealViewController'
pod 'EZAudio'

I add it to a swift file like so:

import EZAudio

I am not using a bridging header. Does anybody have any insight into why this is happening?

like image 938
rikola Avatar asked Jan 25 '16 05:01

rikola


2 Answers

The problem is in the EZAudioiOS.m and EZAudioOSX.m files. You can find those in: /Pods/EZAudio/Core/EZAudioiOS.m

Change the following lines:

#import <EZAudioiOS/EZAudio.h>

With:

#import "EZAudio.h"

An alert will popup, to Unlock the file, you are editing. Just click "Unlock".

like image 197
Dejan Skledar Avatar answered Oct 20 '22 01:10

Dejan Skledar


I guess you need to add pod 'TPCircularBuffer' to the Podfile as well. Works fine now.

like image 37
rikola Avatar answered Oct 20 '22 01:10

rikola