Recent

Author Topic: macOS - commandline for UseAppBundle  (Read 656 times)

Jon

  • New Member
  • *
  • Posts: 23
macOS - commandline for UseAppBundle
« on: April 25, 2022, 04:19:12 pm »
I use the LCL but without Lazarus as my IDE and (cross)-compile from the command line.

Cross-compiling from Linux to macOS (-Tdarwin -Px86_64 -dLCLcocoa) works well.

But I cannot produce an app bundle from any fpc command-line option that I have tried.

Lazarus has the UseAppBundle option in the project.lpi file to enable creating an app bundle:

Code: XML  [Select][+][-]
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <CONFIG>
  3.   <ProjectOptions>
  4.     <General>
  5.       <UseAppBundle Value="True"/>
  6.     </General>
  7.   </ProjectOptions>
  8. </CONFIG>
  9.  

Is there an fpc / ppc command line option that will build the app bundle, not just the executable?

trev

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2020
  • Former Delphi 1-7, 10.2 user
Re: macOS - commandline for UseAppBundle
« Reply #1 on: April 26, 2022, 11:54:02 am »
There is a command line tool to create app bundles. Open /Applications/Lazarus/components/macfiles/examples/createmacapplication.lpr in your IDE. Compile after changing "FileUtil" in the Uses clause to "LazFileUtils". (Bug logged).

Alternatively, there is a script in the Wiki here to do it.

Jon

  • New Member
  • *
  • Posts: 23
Re: macOS - commandline for UseAppBundle
« Reply #2 on: April 30, 2022, 07:47:20 pm »
Perfect - thank you very much.

 

TinyPortal © 2005-2018