Closed rj1102 closed 6 years ago
Please don't forget to "star" (like) this project in Ghitub! It's cost nothing but help to reference the code
Saying that, just to be sure, in the iOSapi.Foundation.pas do you see this code :
// ===== Interface declarations =====
// Base Cocoa NSObject
NSObjectClass = interface(IObjectiveCClass)
['{84CDD025-E02A-4128-B1AC-35A7A5A4643B}']
procedure cancelPreviousPerformRequestsWithTarget(target: Pointer); cdecl;
end;
NSObject = interface(IObjectiveCInstance)
['{C8CC567E-50C3-461C-BAA7-AD96D2CDC5C6}']
procedure retain; cdecl;
procedure release; cdecl;
function retainCount: NSUInteger; cdecl;
function isKindOfClass(cls: Pointer): Boolean; cdecl;
function isMemberOfClass(cls: Pointer): Boolean; cdecl;
procedure performSelector(aSelector: SEL; withObject: Pointer; afterDelay: NSTimeInterval); cdecl;
procedure performSelectorOnMainThread(aSelector: SEL; withObject: Pointer; waitUntilDone: Boolean;
modes: NSArray); cdecl;
function respondsToSelector(aSelector: SEL): Boolean; cdecl;
[MethodName('setValue:forKey:')] // https://quality.embarcadero.com/browse/RSP-19877
procedure setValueforKey(value: Pointer; forKey: NSString); cdecl; // https://quality.embarcadero.com/browse/RSP-19877
[MethodName('setValue:forKeyPath:')] // https://quality.embarcadero.com/browse/RSP-19877
procedure setValueforKeyPath(value: Pointer; forKeyPath: NSString); cdecl; // https://quality.embarcadero.com/browse/RSP-19877
end;
TNSObject = class(TOCGenericImport<NSObjectClass, NSObject>) end;
If yes, are you sure that you project compile with this unit (try to edit it and write some bad code in it and see if your project compile). Also With version of delphi are you using ? CE ?
That code was in the file, but it was probably not high enough in the project's Search path. I moved demos\ALFmxControls_source\embarcadero\tokyo at the top of he Search path, rebuilt, and now these errors do not occur anymore.
But now I get:
[DCC Fatal Error] RjComps.pas(9): F2051 Unit System.Net.HttpClient.Mac was compiled with a different version of Macapi.Helpers.NSStrToStr
So I copied C:\Program Files (x86)\Embarcadero\Studio\19.0\source\rtl\net\System.Net.HttpClient.Mac.pas to demos\ALFmxControls_source\embarcadero\tokyo, and then I get:
[DCC Fatal Error] RjComps.pas(10): F2051 Unit FMX.PushNotification.iOS was compiled with a different version of iOSapi.Foundation.NSUUID
And so on (tried couple of units more, not sure when it will end).
BTW I use Embarcadero® Delphi 10.2 Version 25.0.29899.2631 with installed update 3.
Did you read my previous answer, especially what is after the "please" ????
Ha ha, I've just starred it;)
thanks :) to finish yes unfortunately you will need to include all the units the compiler will complain, and this still you will have no more complain :( Firemonkey is still not yet a really mature suite, so in any case you will often need to play with the original code
I've ended up with adding 6 units, so not so bad;)
For future reference: after that, at the end of the iOSDevice64 build (using SDK 11.2), I got error [DCC Error] E2597 ld: file not found: /System/Library/Frameworks/ImageIO.framework/ImageIO But this I've solved by manually adding ImageIO to Tools, Options, SDK Manager, iOS Device 64 bits, Remote paths, Frameworks.
== issue closed
I have built my project succesfully for Windows and Android (using Alcinoe r862 and Delphi 10.2.3), but now when i build for iOS for the first time, I get: [DCC Error] ALGraphics.pas(3348): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3348): E2003 Undeclared identifier: 'kCIInputImageKey' [DCC Error] ALGraphics.pas(3351): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3352): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3352): E2003 Undeclared identifier: 'kCIInputRadiusKey' [DCC Error] ALGraphics.pas(3538): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3538): E2003 Undeclared identifier: 'kCIInputImageKey' [DCC Error] ALGraphics.pas(3541): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3542): E2003 Undeclared identifier: 'setValueforKey' [DCC Error] ALGraphics.pas(3542): E2003 Undeclared identifier: 'kCIInputRadiusKey' [DCC Fatal Error] ALFmxObjects.pas(38): F2063 Could not compile used unit 'alGraphics.pas'
It looks partly similar with closed issue at https://github.com/Zeus64/alcinoe/issues/16. So I added demos\ALFmxControls_source\embarcadero\tokyo\iOSapi.CoreImage.pas and iOSapi.Foundation.pas to my project, but i get still the same errors.
Any help is appriciated.