Sunday, January 22, 2017

FFMPEG Binary in OSX Package


Hiiiiii All,
Spent my last working day to solve issue related to packaging of FFMPEG binary in OSX release build.Every time i made a package its build correctly but the moment when FFMPEG binary is invoked i get error :

CMSampleBufferGetImageBuffer signalled err=-12731(kCMSampleBufferError_RequiredParameterMissing)

So the way to avoid this error we have to do following steps :
  • Project Settings
  • Click Target
  • Click Capabilities
  • Enable App-Sandbox
  • A file is added in project named Target.entitlements

Inside Entitlements file add following info :
  • com.apple.security.inherit [Boolean] YES
  • App Sandbox [Boolean] YES

Also add a RunScript in Target's Build Phase:

codesign -f -s "your certificate" 
--entitlements ./ffmpeg.entitlements 
./Build/Intermediates/ArchiveIntermediates/App\ Store/InstallationBuildProductsLocation/Applications/<my app>/Contents/MacOS/ffmpeg


Hope it hepls :)

No comments:

Post a Comment