Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support mac platform static library compilation #4859

Merged
merged 7 commits into from Aug 11, 2023

Conversation

Baiyuetribe
Copy link
Contributor

@Baiyuetribe Baiyuetribe commented Jul 14, 2023

修复mac设备编译vulkan静态库时缺少相关依赖的问题

Undefined symbols for architecture arm64:
  "_CACurrentMediaTime", referenced from:
      MVKSwapchain::recordPresentTime(MVKImagePresentInfo const&, unsigned long long) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
Undefined symbols for architecture arm64:
  "_CACurrentMediaTime", referenced from:
      MVKSwapchain::recordPresentTime(MVKImagePresentInfo const&, unsigned long long) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
  "_CFArrayAppendValue", referenced from:
      MVKImage::useIOSurface(__IOSurface*) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
Undefined symbols for architecture arm64:
  "_CACurrentMediaTime", referenced from:
Undefined symbols for architecture arm64:
  "_CACurrentMediaTime", referenced from:
      MVKSwapchain::recordPresentTime(MVKImagePresentInfo const&, unsigned long long) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
      MVKSwapchain::recordPresentTime(MVKImagePresentInfo const&, unsigned long long) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
  "_CFArrayCreateMutable", referenced from:
  "_CFArrayAppendValue", referenced from:
      MVKImage::useIOSurface(__IOSurface*) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
      MVKImage::useIOSurface(__IOSurface*) in libMoltenVK.a(libMoltenVK.a-arm64-master.o)
...

添加后,可成功编译为静态库,可被用于其它应用调用,而无需像vkpeak里那样使项目代码和ncnn代码夹杂在同一个目录里。

@tencent-adm
Copy link

tencent-adm commented Jul 14, 2023

CLA assistant check
All committers have signed the CLA.

@codecov-commenter
Copy link

codecov-commenter commented Jul 27, 2023

Codecov Report

Merging #4859 (540e930) into master (e8645e9) will decrease coverage by 4.78%.
Report is 7 commits behind head on master.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           master    #4859       +/-   ##
===========================================
- Coverage   94.53%   89.75%    -4.78%     
===========================================
  Files         779      309      -470     
  Lines      221835    84270   -137565     
===========================================
- Hits       209706    75637   -134069     
+ Misses      12129     8633     -3496     

see 637 files with indirect coverage changes

@nihui nihui merged commit 75e10c6 into Tencent:master Aug 11, 2023
92 of 94 checks passed
@nihui
Copy link
Member

nihui commented Aug 11, 2023

Thanks for your contribution !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants