Package Documentation

Object: gdl-app (The :gendl Package)
Mixins: gdl-app-scripts-mixin

Author

Dave Cooper, Genworks International

Description

This object serves as the driver for the build process for GDL runtime applications. There is also an undocumented function called make-gdl-app; in order to perform a runtime build process, simply make an instance of this object with the appropriate input values, and invoke (the make!) on it, or call make-gdl-app with the same arguments as the input-slot you give to this object. Note that for very large applications, including all the application fasls in (the application-fasls) list can cause the Lisp heap to blow up fatally during the build. This is because Allegro CL turns off global garbage collecting during the load of the standard list of application fasls. For these cases, the suggested workaround is to include explicit "load" statements for your application fasls in the :post-load-form argument in the generate-application-args list, as in the second example below.


Input Slots (optional)

application-fasls list of pathnames

This list should contain the pre-compiled fasls for your GDL application, in correct load order. These can be produced, for example, by calling genworks:cl-lite with the :create-fasl? keyword argument set to t. If you are using the ASDF build management system, note that ASDF3 is now capable of producing a single fasl file for your application including its ASDF/Quicklisp dependencies, using

         (asdf:operate 'asdf:monolithic-compile-bundle-op :your-application-system-name)
         (asdf:output-file 'asdf:monolithic-compile-bundle-op :your-application-system-name)
See the ASDF documentation for details.


application-name string

The name which will be used for your application's executable and dxl file. Defaults to "gdl-test-runtime".


destination-directory pathname

Indicates the directory to be created or overwritten for producing the runtime distribution. Defaults to a directory called (the application-name) in the system temporary directory, returned by (glisp:temporary-folder).


gdlinit-content string

The contents of this string will be copied to a file gdlinit.cl and placed in the destination-directory. Default is empty string.


generate-application-args

Plist of arguments suitable for Allegro CL's generate-application function. These args will be passed to the internal call to generate-application. This list of arguments will take precedence over individual inputs that you pass to make:gdl-app --- for example if you pass a :lisp-heap-size as an input to this object as well as including it on the :generate-application-args, the one on the :generate-application-args will take effect.


hidden? [from vanilla-mixin*] boolean

Indicates whether the object should effectively be a hidden-object even if specified in :objects. Default is nil.


include-ssl-support? boolean

Indicates whether the SSL support libraries will be copied into the runtime. Applies only to MS Windows platform. Default is nil.


include-swank? boolean

Indicates whether to include the Swank slime editor server in the generated runtime. Defaults to nil.


lisp-heap-size number

The size of the reserved space which will be requested from the OS when the produced application starts up. Defaults to 800000000 (eight hundred million) bytes.


newspace number

The amount of default initial newspace in the generated image. Defaults to make:*newspace*.


oldspace number

The amount of default initial oldspace in the generated image. Defaults to make:*oldspace*


overwrite-validation-function

Function which should take one argument and return non`nil` if that directory is confirmed to be a valid candidate for deletion. Defaults to nil


overwrite? boolean

Indicates whether a build will overwrite a previously existing destination directory. To use this, you also need to specify a `overwrite-validation-function`, which should take one argument and return non`nil` if that directory is confirmed to be a valid candidate for deletion. Defaults to nil.


patch-directory pathname or string naming a directory

. The location of patches for the runtime build. Defaults to *patches-root-dir-default*.


post-load-form lisp expression

This form will be evaluated after the loading of application-fasls is complete. Defaults to nil.


post-make-function lisp function of zero arguments

. This function will be run after the build is finished.


pre-load-form lisp expression

This form will be evaluated before the loading of application-fasls begins, but after the GDL runtime modules are loaded. Defaults to nil.


pre-make-function lisp function of zero arguments

. This function will be run before the build is begun.


purify? boolean

Indicates whether the build should create a PLL, so-called Purified Lisp Library file. This separates string and code-vector constants into a separate file and can save space in the Lisp heap. Defaults to t.


restart-init-function

Lambda expression with empty argument list or symbol naming a function with no arguments. This will be run when the runtime application starts up. The alternative to using this to achieve initializations is to put expressions in a gdlinit.cl or .gdlinit.cl in the application directory or user home directory. Defaults to nil.


root [from vanilla-mixin*] gdl instance

The root-level node in this object's ``tree'' (instance hierarchy).


safe-children [from vanilla-mixin*] list of gdl instances

All objects from the :objects specification, including elements of sequences as flat lists. Any children which throw errors come back as a plist with error information


strings-for-display [from vanilla-mixin*] string or list of strings

Determines how the name of objects of this type will be printed in most places. This defaults to the name-for-display (generally the part's name as specified in its parent), followed by an index number if the part is an element of a sequence.


visible-children [from vanilla-mixin*] list of gdl instances

Additional objects to display in Tatu tree. Typically this would be a subset of hidden-children. Defaults to NIL.



GDL Functions

make! void

Does the application build and creates or replaces (the destination-directory) .


Examples


 (in-package :gdl-user)

 (make-gdl-app :application-name "moon-shot" :destination-directory  "/tmp/moon-shot/" 
               :overwrite? t :application-fasls (list "/fasl-home/booster-rocket.fasl" 
                                                      "/fasl-home/lunar-module.fasl"))

 (make-gdl-app :application-name "moon-shot" :destination-directory  "/tmp/moon-shot/" 
               :overwrite? t :generate-application-args 
                           (list :post-load-form '(progn (load "/fasl-home/booster-rocket.fasl")
                                                         (load "/fasl-home/lunar-module.fasl"))))


Package Documentation