All Manuals > Delivery User Guide

7 Delivery on Microsoft Windows

This chapter describes several issues relevant to delivery with LispWorks for Windows.

7.1 Run time library requirement

Applications that you build with LispWorks for Windows require the Microsoft Visual Studio run time library msvcr80.dll, so you must ensure it is available on target machines. It is part of Windows Vista and later version, but for earlier Windows operating systems you should use the Microsoft redistributable mentioned below.

At the time of writing, the redistributable vcredist_x86.exe for use with for LispWorks (32-bit) applications is freely available at:

http://www.microsoft.com/downloads/details.aspx?familyid=32BC1BEE-A3F9-4C13-9C99-220B62A191EE&displaylang=en

The redistributable vcredist_x64.exe for use with LispWorks (64-bit) applications is freely available at:

http://www.microsoft.com/downloads/details.aspx?FamilyID=90548130-4468-4bbc-9673-d6acabd5d13b&DisplayLang=en

Run the redistributable from your application's installer, or tell your users to run it directly themselves before running your application.

7.2 Application Manifests

LispWorks for Windows is supplied with an embedded application manifest. This default manifest tells the Operating System:

You can change the manifest in your delivered image by passing the keyword argument :manifest-file to deliver. The value must be the name of a file that is a legal application manifest, which is is used as the manifest. The manifest must contain at least the "dependency" element for Microsoft.VC80.CRT (without it, your application will fail to start with error messages "Failed to find msvcr80.dll" or "The application configuration is incorrect"). If the manifest does not contain the "dependency" element for Microsoft.Windows.common-controls your application will use Common Controls 5, and therefore will not be a "Themed" application.

The value of :manifest-file can also be the special value :no-common-controls-6, in which case a default manifest without the element for Common Controls is used.

The default manifests that LispWorks uses are provided by way of documentation in the lib/8-0-0-0/config directory. If desired, you can base your application manifests as supplied via :manifest-file on these files:

The default manifests used by LispWorks
32-bit LispWorks64-bit LispWorks

With Common Controls 6

winlisp32.manifest

winlisp64.manifest

Without Common Controls 6

lisp32.manifest

lisp64.manifest

Note: the above only applies when LispWorks is an executable. If LispWorks is a DLL, then it will be themed if the executable that loads it contains the Common Controls 6 manifest.

7.3 DOS windows and message logs

7.3.1 Controlling use of a DOS window

A graphical Windows application does not usually have a console (or "DOS window").

You can achieve this by supplying the keyword argument :console :input when delivering your application.

7.3.2 Logging debugging messages

Output to *terminal-io* from an application without a console will not ordinarily be visible to the user, so debugging messages should be written to a log file.

Log files are recommended for any complex application as they make it easier for you to get information back from your users.

You can use dbg:log-bug-form for logging errors. See the LispWorks® User Guide and Reference Manual for details.

7.4 File associations for a Windows application

To create an association between your LispWorks for Windows application and files with a specified type (file extension), create a DDE server in Lisp and register the file types in Windows.

There is an example of this (for the LispWorks IDE) in:

(example-edit-file "dde/lispworks-ide")

but the technique is the same for any file extension.

7.5 Editor emulation

If your application uses capi:editor-pane or its subclasses, your should consider the input style. The editor in the delivered application can emulate Emacs or Microsoft Windows style editing. The deliver keyword :editor-style controls which emulation is used.

7.6 ActiveX controls

If your library foo is a Windows ActiveX control (that is, it uses capi:ole-control-component and capi:define-ole-control-component) you may choose to specify file "foo.ocx" as the file argument to deliver. The file type defaults to "dll".

The file extension does not alter functionality - the system simply loads the file referenced in the Windows registry.

7.7 Example of delivering a Service

This example in the LispWorks library illustrates delivering an application that can be run as a Windows Service:

(example-edit-file "delivery/ntservice/README.txt")


Delivery User Guide - 01 Dec 2021 19:35:04