With Xcode 6 we get ability to create own Dynamic Cocoa Frameworks.

Because of:
Simulator still use
32-bitlibrary-
beginning June 1, 2015 app updates submitted to the App Store must include 64-bit support and be built with the iOS 8 SDK (developer.apple.com)
We have to make fat library to run project on devices and simulators. i.e. support both 32 and 64 bit in Frameworks.
But I didn't find any manuals, how to export universal fat Framework for future integration with other projects (and share this library with someone).
Here is my steps to reproduce:
Set
ONLY_ACTIVE_ARCH=NOin theBuild Settings
Add support
armv7 armv7s arm64 i386 x86_64toArchitectures(for sure)

- Build Framework and open it in Finder:

- Add this framework to another project
Actual result:
But in the end I still have problem with running project with this framework on devices and simulator at once.
if I take framework from
Debug-iphoneosfolder - it works on devices and gets error on simulators:ld: symbol(s) not found for architecture i386xcrun lipo -info CoreActionSheetPickerArchitectures in the fat file: CoreActionSheetPicker are: armv7 armv7s arm64
if I take framework from
Debug-iphonesimulatorfolder - it works on simulators. and I have error on device:ld: symbol(s) not found for architecture arm64xcrun lipo -info CoreActionSheetPickerArchitectures in the fat file: CoreActionSheetPicker are: i386 x86_64
So, how to create a dynamic framework that works on devices and simulators?
This answer related to Xcode 6 iOS Creating a Cocoa Touch Framework - Architectures issues but it's not duplicate.
Update:
I found a "dirty hack" for this case. See my answer below. If someone knows more convenient way - please, let me know!


The actuality of this answer is: July 2015. It is most likely that things will change.
TLDR;
Currently Xcode does not have tools for automatic export of universal fat framework so developer must resort to manual usage of
lipotool. Also according to this radar before submission to AppStore developer who is framework's consumer also must uselipoto strip off simulator slices from a framework.Longer answer follows
I did similar research in the topic (the link at the bottom of the answer).
I had not found any official documentation about distribution of so my research was based on exploration of Apple Developer Forums, Carthage and Realm projects and my own experiments with
xcodebuild,lipo,codesigntools.Here's long quote (with a bit of markup from me) from Apple Developer Forums thread Exporting app with embedded framework:
This describes process pretty much the same as @skywinder did it in his answer.
This is how Carthage uses lipo and Realm uses lipo.
IMPORTANT DETAIL
There is radar: Xcode 6.1.1 & 6.2: iOS frameworks containing simulator slices can't be submitted to the App Store and a long discussion around it on Realm#1163 and Carthage#188 which ended in special workaround:
before submission to AppStore iOS framework binaries must be stripped off back from simulator slices
Carthage has special code: CopyFrameworks and corresponding piece of documentation:
Realm has special script: strip-frameworks.sh and corresponding piece of documentation:
Also there is good article: Stripping Unwanted Architectures From Dynamic Libraries In Xcode.
I myself used Realm's
strip-frameworks.shwhich worked for me perfectly without any modifications though of course anyone is free to write a one from scratch.The link to my topic which I recommend to read because it contains another aspect of this question: code signing - Creating iOS/OSX Frameworks: is it necessary to codesign them before distributing to other developers?