The version of OpenMotif required by LispWorks 5.1 may not be compatible with other applications (including LispWorks 4.2). It is however compatible with LispWorks 5.0, LispWorks 4.4 and 4.3, so you for example you should be able to run LispWorks 5.1, LispWorks 5.0 and LispWorks 4.4 simultaneously with either OpenMotif installed.
Whilst it is not supported for LispWorks 5.1, you can still use LessTif for LispWorks 5.0 and earlier - see the Installation Guide for that version for details.
You may wish to maintain multiple versions of the Motif/LessTif libraries in order to run various applications simultaneously. However, because the filenames of the libraries can conflict, this can only be done by installing libraries in non-standard locations.
When a library has been installed in a non-standard location, you can set the environment variable
to allow an application to find that library. Specifically, if <motiflibdir> denotes the directory containing the Motif 2.2 file
to include <motiflibdir>.
Note: to find out which version of libXm your LispWorks 5.1 image is actually using, look in the bug form. See Generate a bug report template for instructions on generating the bug form.