Recent

Author Topic: Apple Developer Transition Kit  (Read 12987 times)

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #75 on: September 25, 2020, 06:36:01 pm »
You have to reinstall FPC 3.2.0 after restoring your DTK.

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #76 on: September 27, 2020, 05:05:04 pm »
Jonas,
Thanks! So stupid mistake after many recompilations :)

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #77 on: October 02, 2020, 01:53:07 pm »
Jonas,

I have a problem with compiling native FPC for ARM64.

It fails on this stage:

Code: Pascal  [Select][+][-]
  1. mac@Igors-Mac freepascal % make FPC=$PWD/ppca64 OPT="-ap -FD/Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin -XR/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk" -j 4 FPMAKEOPT="-T 4" OVERRIDEVERSIONCHECK=1 all > build.log
  2. make: *** clean: No such file or directory.  Stop.
  3. make[5]: *** [rtlclean] Error 2
  4. make[4]: *** [next] Error 2
  5. make[3]: *** [ppc1.exe] Error 2
  6. make[2]: *** [cycle] Error 2
  7. make[1]: *** [compiler_cycle] Error 2
  8. make: *** [build-stamp.-] Error 2

I just downloaded the latest source code of FPC:

Code: Pascal  [Select][+][-]
  1. git clone https://github.com/graemeg/freepascal

Xcode 12.2 Beta is installed in Applications.

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #78 on: October 02, 2020, 02:20:28 pm »
What does build.log contain?

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #79 on: October 02, 2020, 02:28:31 pm »
Code: Pascal  [Select][+][-]
  1. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make compiler_cycle RELEASE=1
  2. You have overriden the starting compiler versioncheck while using starting compiler version . This situation is not supported and strange things and errors may happen. Remove OVERRIDEVERSIONCHECK=1 to fix this.
  3. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make -C compiler cycle
  4. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make tempclean
  5. /bin/rm -f ppcross ppc ppc1.exe ppc2.exe ppc3.exe ./msg2inc.exe pp1.wpo pp2.wpo
  6. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make ppc3.exe
  7. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make 'OLDFPC=' next CYCLELEVEL=1
  8. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make rtlclean
  9. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make -C  clean
  10.  

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #80 on: October 02, 2020, 02:48:03 pm »
If you go in the compiler directory and execute the following, what does it print?
Code: [Select]
make FPC=$PWD/../ppca64 OPT="-ap -FD/Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin -XR/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk" -j 4 FPMAKEOPT="-T 4" OVERRIDEVERSIONCHECK=1 RELEASE=1 info

Also, what does "make --version" print?
« Last Edit: October 02, 2020, 02:55:19 pm by Jonas Maebe »

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #81 on: October 02, 2020, 03:19:40 pm »
In /freepascal/compiler folder:

Code: Pascal  [Select][+][-]
  1. mac@Igors-Mac compiler % make FPC=$PWD/../ppca64 OPT="-ap -FD/Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin -XR/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk" -j 4 FPMAKEOPT="-T 4" OVERRIDEVERSIONCHECK=1 RELEASE=1 info
  2.  
  3. == Package info ==
  4. Package Name..... compiler
  5. Package Version.. 3.3.1
  6.  
  7. == Configuration info ==
  8.  
  9. FPC.......... /Users/mac/WnSoft/Development/freepascal/compiler/../ppca64
  10. FPC Version.. 3.3.1
  11. Source CPU... aarch64
  12. Target CPU... aarch64
  13. Source OS.... darwin
  14. Target OS.... darwin
  15. Full Source.. aarch64-darwin
  16. Full Target.. aarch64-darwin
  17. SourceSuffix. aarch64-darwin
  18. TargetSuffix. aarch64-darwin
  19. FPC fpmake... /Users/mac/WnSoft/Development/freepascal/compiler/../ppca64
  20.  
  21. == Directory info ==
  22.  
  23. Required pkgs... rtl rtl
  24.  
  25. Basedir......... /Users/mac/WnSoft/Development/freepascal/compiler
  26. FPCDir.......... ..
  27. CrossBinDir.....
  28. UnitsDir........
  29. PackagesDir..... .. ../packages
  30.  
  31. GCC library.....
  32. Other library...
  33.  
  34. == Tools info ==
  35.  
  36. As........ as
  37. Ld........ ld
  38. Ar........ ar
  39. Rc........ rc
  40.  
  41. Mv........ /bin/mv
  42. Cp........ /bin/cp
  43. Rm........ /bin/rm
  44. GInstall.. /usr/bin/install
  45. Echo...... /bin/echo
  46. Shell..... /bin/sh
  47. Date...... /bin/date
  48. FPCMake... /usr/local/bin/fpcmake
  49. PPUMove... /usr/local/bin/ppumove
  50. Zip....... /usr/bin/zip
  51.  
  52. == Object info ==
  53.  
  54. Target Loaders........
  55. Target Units..........
  56. Target Implicit Units.
  57. Target Programs....... pp
  58. Target Dirs........... utils
  59. Target Examples.......
  60. Target ExampleDirs....
  61.  
  62. Clean Units.........
  63. Clean Files.........
  64.  
  65. Install Units.......
  66. Install Files.......
  67.  
  68. == Install info ==
  69.  
  70. DateStr.............. 20201002
  71. ZipName.............. compiler
  72. ZipPrefix............
  73. ZipCrossPrefix.......
  74. ZipSuffix............ .aarch64-darwin
  75. FullZipName.......... compiler.aarch64-darwin
  76. Install FPC Package.. y
  77.  
  78. Install base dir..... /usr/local/lib/fpc/3.3.1
  79. Install binary dir... /usr/local/bin
  80. Install library dir.. /usr/local/lib
  81. Install units dir.... /usr/local/lib/fpc/3.3.1/units/aarch64-darwin/compiler
  82. Install source dir... /usr/local/share/src/fpc-3.3.1/compiler
  83. Install doc dir...... /usr/local/share/doc/fpc-3.3.1/compiler
  84. Install example dir.. /usr/local/share/examples/fpc-3.3.1/compiler
  85. Install data dir..... /usr/local/lib/fpc/3.3.1
  86.  
  87. Dist destination dir. /Users/mac/WnSoft/Development/freepascal/compiler
  88. Dist zip name........

Code: Pascal  [Select][+][-]
  1. mac@Igors-Mac compiler % make --version
  2. GNU Make 3.81
  3. Copyright (C) 2006  Free Software Foundation, Inc.
  4. This is free software; see the source for copying conditions.
  5. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
  6. PARTICULAR PURPOSE.
  7.  
  8. This program built for i386-apple-darwin11.3.0

P.S. I have Beta 9 on this DTK. I restored DTK in DFU mode to Beta 8, installed Xcode 12.2 Beta and then updated to Beta 9.

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #82 on: October 02, 2020, 08:29:09 pm »
It turns out to be yet another bug in the codesigning verification functionality. It works if you copy instead of move compiler/ppca64 to the current directory (i.e., use "cp compiler/ppca64 ." as step 2)

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #83 on: October 05, 2020, 02:32:18 pm »
Jonas,

Thanks, I used cp command on Step 2:

Code: Pascal  [Select][+][-]
  1. cp compiler/ppca64 .

But the same error on Step 3:

Code: Pascal  [Select][+][-]
  1. mac@Igors-Mac freepascal % make FPC=$PWD/ppca64 OPT="-ap -FD/Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin -XR/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk" -j 4 FPMAKEOPT="-T 4" OVERRIDEVERSIONCHECK=1 all > build.log
  2. make: *** clean: No such file or directory.  Stop.
  3. make[5]: *** [rtlclean] Error 2
  4. make[4]: *** [next] Error 2
  5. make[3]: *** [ppc1.exe] Error 2
  6. make[2]: *** [cycle] Error 2
  7. make[1]: *** [compiler_cycle] Error 2
  8. make: *** [build-stamp.-] Error 2

Code: Pascal  [Select][+][-]
  1. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make compiler_cycle RELEASE=1
  2. You have overriden the starting compiler versioncheck while using starting compiler version . This situation is not supported and strange things and errors may happen. Remove OVERRIDEVERSIONCHECK=1 to fix this.
  3. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make -C compiler cycle
  4. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make tempclean
  5. /bin/rm -f ppcross ppc ppc1.exe ppc2.exe ppc3.exe ./msg2inc.exe pp1.wpo pp2.wpo
  6. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make ppc3.exe
  7. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make 'OLDFPC=' next CYCLELEVEL=1
  8. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make rtlclean
  9. /Applications/Xcode-beta.app/Contents/Developer/usr/bin/make -C  clean
  10.  

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #84 on: October 05, 2020, 02:41:24 pm »
It worked for me... Maybe try deleting the old ppca64 in the top-level fpc directory before copying the new one. You can check whether it worked without executing the "make" command by just executing that ppca64 binary (./ppca64). If you immediately get a "killed" message, it indicates codesigning shenanigans. There's also a thread about this issue on the Apple developer forums.

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #85 on: October 05, 2020, 03:54:09 pm »
Jonas,

I deleted fps and lazarus and downloaded them again.

Now fps compiles fine for arm64.

Thanks for your help.

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #86 on: October 06, 2020, 03:36:11 pm »
Jonas,

Every time I start Lazarus I see an error message that Fppcfg is missing (fppcfg.cfg).
Can you advice how to fix it?

Jonas Maebe

  • Hero Member
  • *****
  • Posts: 803
Re: Apple Developer Transition Kit
« Reply #87 on: October 06, 2020, 03:37:57 pm »
No, I only work on the compiler. I have no clue what that file is for or how it is supposed to be created. It's not part of fpc itself.

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1052
  • Former Delphi 1-7, 10.2 User
Re: Apple Developer Transition Kit
« Reply #88 on: October 07, 2020, 11:47:16 am »
Every time I start Lazarus I see an error message that Fppcfg is missing (fppcfg.cfg).

Do you mean /etc/fppkg.cfg ?
o Lazarus v2.1.0 r63871, FPC v3.3.1 r47164, macOS 10.14.6 (with sup update), Xcode 11.3.1
o Lazarus v2.1.0 r61574, FPC v3.3.1 r42318, FreeBSD 12.1 amd64 (VMware Fusion VM)
o FPC 3.0.4, FreeBSD 12.2-STABLE r365646 amd64
o Lazarus v2.1.0 r61574, FPC v3.0.4, Ubuntu 20.04 (Parallels VM)

Igor Kokarev

  • Sr. Member
  • ****
  • Posts: 269
Re: Apple Developer Transition Kit
« Reply #89 on: October 07, 2020, 01:26:22 pm »
Do you mean /etc/fppkg.cfg ?

Yes, and I can't create a new fppkg.cfg file. No rights.

It seems to be some new problem with Apple DTK on Beta 9.

Earlier I didn't had this problem with macOS Big Sure Beta 1-5. Recently I restored DTK to Beta 9 and have this problem with Lazarus. As you can see from my previous posts, I downloaded Trunk version of FPC and Lazarus and compiled it according instructions from Jonas.

 

TinyPortal © 2005-2018