Darling: Xcode 9 and 10 need some stubs

Created on 23 Oct 2018  路  15Comments  路  Source: darlinghq/darling

This prevents running Xcode 9 CLI tools or any other recent Swift version.

Application Compatibility

Most helpful comment

Xcode 10 finally has all the symbols it wants before it starts executing any code. It of course does not work yet, but that is outside of the scope of this issue.

For those who are curious, this is what happens when it is run:

objc[23]: Class CIAffineTransform is implemented in both /System/Library/Frameworks/CoreImage.framework/Versions/A/CoreImage (0x7ffff01a3b20) and /System/Library/Frameworks/QuartzCore.framework/Versions/A/QuartzCore (0x7ffff36e4860). One of the two will be used. Which one is undefined.
Assertion failed: (isRealized()), function isMetaClass, file /home/andrewhyatt/darling/src/external/objc4/runtime/objc-runtime-new.h, line 1221.
Abort trap: 6 (core dumped)

All 15 comments

seconded

Darling [/Volumes/SystemRoot/home/philix/tmp/darling/autoconf-2.69]$ make
dyld: Symbol not found: _NSAffectedObjectsErrorKey
  Referenced from: /Volumes/SystemRoot/opt/chain/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/../../../../Frameworks/libswiftCoreData.dylib (which was built for Mac OS X 10.9)
  Expected in: /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData
 in /Volumes/SystemRoot/opt/chain/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/../../../../Frameworks/libswiftCoreData.dylib
Abort trap: 6

XCode comes with a version of make, so I just replaced the "system" one with that.

There's more

NSPersistentStoreSaveConflictsErrorKey
NSValidationKeyErrorKey
NSValidationObjectErrorKey
NSValidationPredicateErrorKey
NSValidationValueErrorKey

and now also

Darling [/home/philix/git/darling/build]$ xcrun make dyld: Symbol not found: _OBJC_CLASS_$_NSMergeConflict

Next ones needed:

dyld: Symbol not found: __xpc_event_key_name
  Referenced from: /Volumes/SystemRoot/media/sf_Applications/Xcode.app/Contents/MacOS/../Frameworks/libswiftXPC.dylib (which was built for Mac OS X 10.9)
  Expected in: /usr/lib/libSystem.B.dylib
 in /Volumes/SystemRoot/media/sf_Applications/Xcode.app/Contents/MacOS/../Frameworks/libswiftXPC.dylib

I'm quite ignorant to the internals of all this, but I recall using the same version of XCode previously and not having such problems - maybe I'm mistaken/confused

thanks for your time @ahyattdev

Hi Dekken,

I am going off of all the symbols that the main 'Xcode' application executable relies on here. I'm not sure exactly which program is being run that creates this issue but hopefully this also fixes that.

Next is _kSecAttrAccess.

Next is _NSAccessibilityActivationPointAttribute, in AppKit.

Next is _NSAccessibilitySupportsMainThreadIdleNotificationAttribute, in AppKit

Next is _kCGWindowAlpha, in CoreGraphics. I will be away for a few days, will pick up later.

Next is _OBJC_CLASS_$_NSScriptCommand in Foundation.

Next is _OBJC_CLASS_$_CAReplicatorLayer in QuartzCore.

Next is _NSAnimateBinding in AppKit.

Xcode 10 finally has all the symbols it wants before it starts executing any code. It of course does not work yet, but that is outside of the scope of this issue.

For those who are curious, this is what happens when it is run:

objc[23]: Class CIAffineTransform is implemented in both /System/Library/Frameworks/CoreImage.framework/Versions/A/CoreImage (0x7ffff01a3b20) and /System/Library/Frameworks/QuartzCore.framework/Versions/A/QuartzCore (0x7ffff36e4860). One of the two will be used. Which one is undefined.
Assertion failed: (isRealized()), function isMetaClass, file /home/andrewhyatt/darling/src/external/objc4/runtime/objc-runtime-new.h, line 1221.
Abort trap: 6 (core dumped)

Related is #488.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

LubosD picture LubosD  路  5Comments

CuriousTommy picture CuriousTommy  路  6Comments

wusikijeronii picture wusikijeronii  路  4Comments

ahyattdev picture ahyattdev  路  5Comments

xlmnxp picture xlmnxp  路  7Comments