mwasoftware.co.uk

Even if you are familiar with our Merge Modules for Firebird 1.0, you should read this page.

Although functionally, Firebird 1.5 is a straightforward upgrade of Firebird 1.0.3, the names of all the executables have changed. The process names are different as it the name of the client library. Only the TCP Port Number used for remote access to a database has stayed the same. For an installer, Firebird 1.5 is a new product. However, because it uses the same TCP Port, the Firebird 1.5 Server cannot be installed on the same system as InterBase or earlier versions of Firebird without conflicts arising.

Additionally, there is the problem of backwards compatibility with applications that expect the old library (dll) name: especially Delphi applications using IBX. There is also the new embedded server to consider.

Building a set of install modules for Firebird 1.5 is straightforward, but taking into account the issues of compatibility and backwards compatibility makes for a more complex decision process.

Our set of merge modules will allow you to build the following installations:

·       A Firebird 1.5 client which should have no compatibility issues with older versions of Firebird or InterBase

·       A Firebird 1.5 client as above, but with additional support for IBX based applications and any other application that expects to use the gds32.dll interface.

·       A Firebird 1.5 Server which will silently upgrade an older Firebird or InterBase server installed with our merge modules.

The Server install will complain if it finds an InterBase or Firebird Server installed by any other means and refuse to install until it is removed. This is because it is not possible, in general, to uninstall the incompatible Server and the user must do it explicitly. Our earlier merge modules solved this problem by simply over-writing the installed files, but this is not possible now that they have been renamed.

Client Install

For a basic client install, all you need to do is to include the fb152client.msm merge module in your installation package. This will install the fbclient.dll in its default location along with the firebird.conf, firebird.msg and the all important licence file. The default Firebird registry entry will also be created.

It will also set the PATH environment variable to include the directory containing fbclient.dll. This is so that your application can readily load the dll without having to know its exact location. The effect is similar to placing the file in the Windows system directory.

This install has no conflicts with earlier InterBase and Firebird installations.

IBX Compatible Client Install

If you also want IBX compatibility or to install any application that expects the Firebird client library to be called gds32.dll. Then you need to do a bit more work.

Firstly, the fb152client.msm should be included in your installation package. We then recommend including in your application directory a copy of fbclient.dll renamed to gds32.dll and patched so that its version number is 6.3. A suitable copy of fbclient.dll is included in the distribution zip for our merge modules in the “client” subdirectory. You include it in the install script in the same way that you include your own application’s files.

Including this gds32.dll in your application’s directory means that it will always be loaded by your application in preference to any other copy of gds32.dll that may be on the same computer. It is thus possible to have other InterBase or Firebird 1 clients on the same computer. Patching it to version 6.3 also allows IBX to detect it as an InterBase version 6 library providing the additional functions available in InterBase 6.

You must also include the fb152client.msm merge module as this includes the configuration and message files that the patch gds32.dll needs.

Note that this file cannot be provided as a merge module, as merge modules are intended to be common components installed in a single location and available to all users. The gds32.dll file is installed as part of the application and not as a common component.

Command Line Tools

The command line tools: gbak, isql, etc. are contained in the fb152tools.msm. Include this merge module in your client installation if you also want these tools available to your application.

Including this merge module automatically includes the fb15client.msm merge module. As this already adds the installation directory to the environment PATH, the command line tools can be invoked from a DOS box without having to include the full installation path.

Firebird Server

The Firebird 1.5 Server is included in the fb152server.msm merge module. Include this merge module when you want to include the Firebird Server in your installation. The fb152client.msm and the fb152tools.msm merge modules will automatically be included.

This merge module will install the Firebird Server files in their default location.

  • Under Windows NT/2000/XP, it will automatically install and start the server as a Windows Service under the “LocalSystem” user. The Firebird Control Panel applet will also be installed.
  • Under Windows 9x, the service has to be run as an application. The installation will automatically start this application after the installation and update the registry so that the Firebird 1.5 Server is started automatically on system start up.

If an earlier version of InterBase or Firebird is detected and had been installed by our merge modules then this will be silently uninstalled before the new version is installed.

If the security database “isc4.gdb” is located then this is copied to the Firebird 1.5 installation directory and renamed “security.fdb”. Usernames and passwords should thus be preserved on upgrade.

If a version of InterBase or Firebird is detected and had been installed by any other means then the installation will abort with an error message informing the user that the installation cannot be completed until this earlier version is removed. Note that the installation is detected by determining the presence of the “ibserver.exe” or “fbserver.exe” file and is independent of whether or not the server is actually running.

Server Install Issues

These merge modules cannot prevent a user subsequently installing an incompatible version of InterBase or Firebird that failed to detect the Firebird 1.5 installation. This is likely to result in unpredictable results depending on which service gains access to the TCP Port.

There is also a possible problem if two separate products had installed our merge modules (server) on the same system prior to the upgrade to Firebird 1.5. In this situation, the earlier Server may not be uninstalled and unpredictable results may again follow.

Your release notes should alert users to this potential problems.

Preventing a Silent Install/Uninstall

The default server installation script will silently stop any running server on both install and uninstall. This may not always be desirable with production servers as users may still be active. Data loss may result.

To avoid this problem, you should also include the fb152StopServer merge module. This adds an additional check that:

a)     Aborts the install/uninstall if no user interface is active and the server is running.

b)     Alerts the user if the user interface is active and the server is running, and gives the option of stopping the server or aborting the installation.

Installing the Embedded Server

There is no merge module for the embedded server. This is because merge modules are intended to be common components installed in a single location and available to all users. The embedded server is installed as part of the application and not as a common component.

The embedded server files should be included along with your application’s files as part of the installation script. There should be no compatibility issues with other InterBase or Firebird installations because the embedded server does not listen on a TCP Port. If only for this reason, you should use the embedded server whenever there is no requirement for remote access to database files.

The embedded server is provided in the fbembed.dll file that is available from the Firebird SQL website. This file has to be renamed to either fbclient.dll or gds32.dll depending on how your application accesses the Firebird library. For IBX based applications, fbembed.dll must be renamed to gds32.dll and patched so that its version number is 6.3.

In the distribution zip for our merge modules, we have also included a minimal set of files for the embedded server in the “embed” subdirectory. This includes “fbclient.dll” and “gds32.dll” files that are renamed versions of fbembed.dll. In the latter cases, gds32.dll has been patch to version 6.3.

To install an embedded server, all you should need to do is to include, in your installation script, all the files in the embed directory including subdirectories, and install them into your application directory. You may omit either “fbclient.dll” or “gds32.dll” depending on which version your application uses.