1
我正在嘗試爲OSX的PCI複合視頻採集卡編寫驅動程序。加載kext時IOPCIDevice未鏈接
的內核擴展構建就好了,但是當我嘗試加載它,我得到這個:
Diagnostics for /System/Library/Extensions/Conexant878.kext:
Code Signing Failure: code signature is invalid
WARNING - Invalid signature -67030 0xFFFFFFFFFFFEFA2A for kext "/System/Library/Extensions/Conexant878.kext"
(kernel) kxld[com.akasaka.Conexant878]: The following symbols are unresolved for this kext:
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice16Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice17Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice18Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice19Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice20Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice22_RESERVEDIOPCIDevice21Ev
(kernel) kxld[com.akasaka.Conexant878]: __ZN11IOPCIDevice24getDeviceMemoryWithIndexEj
(kernel) Can't load kext com.akasaka.Conexant878 - link failed.
(kernel) Failed to load executable for kext com.akasaka.Conexant878.
(kernel) Kext com.akasaka.Conexant878 failed to load (0xdc008016).
(kernel) Failed to load kext com.akasaka.Conexant878 (error 0xdc008016).
Failed to load /System/Library/Extensions/Conexant878.kext - (libkern/kext) link error.
Check library declarations for your kext with kextlibs(8).
的kextlibs輸出如下:
For all architectures:
com.apple.iokit.IOPCIFamily = 2.9
com.apple.kpi.iokit = 13.4
com.apple.kpi.libkern = 13.4
For x86_64:
7 symbols not found in any library kext:
__ZN11IOPCIDevice24getDeviceMemoryWithIndexEj
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice16Ev
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice18Ev
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice20Ev
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice17Ev
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice19Ev
__ZN11IOPCIDevice22_RESERVEDIOPCIDevice21Ev
我Info.plist中包含了所有的OSBundleLibraries我可以認爲在這種情況下是必要的,但這仍然是一個不行:
...
<key>IOClass</key>
<string>ConexantTuner</string>
<key>OSBundleRequired</key>
<string>Local-Root</string>
<key>IOPCIMatch</key>
<string>0x036e109e</string>
<key>IOProviderClass</key>
<string>IOPCIDevice</string>
<key>IOKitPersonalities</key>
<dict/>
<key>OSBundleLibraries</key>
<dict>
<key>com.apple.iokit.IOPCIFamily</key>
<string>1.0.0b1</string>
<key>com.apple.kpi.mach</key>
<string>8.0</string>
<key>com.apple.kpi.unsupported</key>
<string>8.0</string>
<key>com.apple.kpi.iokit</key>
<string>8.0</string>
<key>com.apple.kpi.libkern</key>
<string>8.0</string>
<key>com.apple.kpi.bsd</key>
<string>8.0</string>
</dict>
</dict>
</plist>
我還有什麼可以嘗試確定還需要依賴哪些方面才能使其發揮作用?
在此先感謝。
C++懸而未決的符號Filt員工輸出:
IOPCIDevice::getDeviceMemoryWithIndex(unsigned int)
IOPCIDevice::_RESERVEDIOPCIDevice16()
IOPCIDevice::_RESERVEDIOPCIDevice18()
IOPCIDevice::_RESERVEDIOPCIDevice20()
IOPCIDevice::_RESERVEDIOPCIDevice17()
IOPCIDevice::_RESERVEDIOPCIDevice19()
IOPCIDevice::_RESERVEDIOPCIDevice21()
GetDeviceMemoryWithIndex問題現在消失了,但其餘的仍然存在:( –
很奇怪,你有沒有設置任何自定義標題搜索路徑或類似的東西?任何特殊的鏈接標誌,比如隱藏符號? ,你的'info.plist'看起來不太對,具體來說,你的'IOKitPersonalities'字典是空的,但你在根中有一些IOKit匹配鍵,這些鍵幾乎肯定是個性的,它們不應該導致鏈接錯誤 – pmdj
是否有IOKit PCI擴展的個性? –