Omnis Technical Note TNSQ0040March 2021

Replacing the PostgreSQL Client in MacOS Big Sur and Later

for Omnis Studio 10.2 or above
by Gary Ashford, Omnis Engineering

The PostgreSQL DAM in Studio 10.2 ships with its dynamic client library; libpq.dylib in the folder, and this is digitally signed as part of Omnis Studio's code signature. This technote discusses how you can replace the client library should you need to.

See also: technote TNSQ0031 which discusses upgrading the client library on Windows, macOS and Linux.

Replacing the Client Library
If you want to replace or update the supplied client library; for instance if you require OpenSSL support, then you will need to obtain the library from a PostgreSQL distribution or binary archive. These are noramlly SSL-enabled and have additional dependencies on libcrypto.dylib and libssl.dylib. For example:

Download your PostgreSQL archive from the PostgreSQL website, then extract the following files (from the lib folder):

libpq.dylib -> libpq.5.13.dylib

These files should be copied into the /Applications/Omnis Studio 10.2 folder, replacing the existing libpq.dylib when prompted.

Now copy the two files; libcrypto.1.1.dylib and libssl.1.1.dylib. Because the RPATH of the replacement libpq.5.13.dylib refers to:

@loader_path/../lib/libssl.1.1.dylib    and

using a relative path, these files need to be copied to the /Applications/Omnis Studio 10.2 folder, creating the lib folder as required.

Having copied the files: libpq.5.13.dylib (in this example), plus the libpq.dylib symlink, libssl.1.1.dylib and libcrypto.1.1.dylib into their respective locations, then connection using the PostgreSQL DAM should resume as normal:

If you encounter the error; "Client or interface function not available", please check the preceding steps, since this indicates a problem loading the libpq.dylib or one of its dependencies. Versions and revision numbers used in this technote are illustrative only. Please adapt the steps above based on the file versions you are using.


Search Omnis Developer Resources


Hit enter to search