简体   繁体   中英

How to import a C++ library into a Xcode Objective C project?

I'm new to developing apps for OSX. I want to write a library that does a specific job in C++ and use it inside my XCode Objective-C/Objective-C++ project.

How should I compile and prepare the C++ library so it can be imported into XCode?

There are Xcode templates for C++ libraries. Just make one of those and copy the library's source into it.

您需要在构建设置中将“编译源”设置为:Objective-C ++。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM