I ran kextlibs
against my kext, and it told me to use:
com.apple.kpi.bsd = 12.2
com.apple.kpi.libkern = 12.2
this runs fine on my development machine (10.8). But when I run it on another machine (running 10.7) it doesn't load, saying:
Dependency Resolution Failures:
Only incompatible kexts found for these libraries:
com.apple.kpi.bsd
com.apple.kpi.libkern
How do I work out which versions to link against if I want to target a range of Mac OS versions (10.6 to 10.8)?
The KPI "bundles" (com.apple.kpi.*) are versioned by the Kernel's Darwin version number.
The IOKit Families (e.g. IOPCIFamily, IOStorageFamily, etc.) have their own versioning schemes. The way to handle these is to look at the bundle version (CFBundleVersion) property in the Info.plist in the relevant kext (IOPCIFamily.kext, IOStorageFamily.kext, etc.) for the oldest OSX version you want to support. Or, just run kextlibs while running that OS version - kextlibs will always print the kext/kpi version numbers for the running version of OSX.