Current versions of the WFDB Software Package can be compiled and installed on either 32- or 64-bit Linux, but the procedure for doing so depends on which you have. You can check this by running the command
uname -mIf the output is x86_64, your CPU and Linux kernel are both 64-bit, and you should use version 10.4.9, or any later version, of the WFDB Software Package. Although some older versions of the WFDB Software Package can also be compiled and installed on 64-bit Linux, they are not fully supported (see this note).
If neither libcurl nor libwww has been installed already, install one of them now. On Fedora and other RPM-based GNU/Linux distributions, the command 'yum install curl-devel' downloads and installs libcurl; on Ubuntu and other Debian-based GNU/Linux distributions, 'apt-get install libcurl4-openssl-dev' does the same thing.
If (and only if) you are running a 32-bit Linux kernel, and you wish to install WAVE, install the X11 developer's toolkit and XView (optional, requires root permissions) if they have not been installed already. (Check for the presence of Xlib.h, which is usually found in /usr/include/X11, to see if the X11 developer's toolkit has been installed. Check for the presence of textedit, which is usually found in /usr/openwin/bin, to see if XView has been installed.)
If you download the sources (recommended):
tar xfvz wfdb.tar.gzThis creates a directory with a name of the form wfdb-10.m.n.
cd wfdb-10.m.n ./configure make installIf you are running a 64-bit Linux kernel, ./configure will report that WAVE will not be compiled (because WAVE cannot be compiled in 64-bit mode). You will be able to compile a 32-bit version of WAVE in step 6.
The make command requires root permissions, and installs the package in subdirectories of /usr. If you do not have root permissions, you may install the package in any writable directory by adding an appropriate option to the make command above:
make install WFDBROOT=/path/to/another/directoryNote that in this case you will need to add WFDBROOT/bin to your PATH, and WFDBROOT/lib to your LD_LIBRARY_PATH.
make checkThis step compiles a short program that exercises the WFDB library and applications, and prints a summary of test results. The tests are very short (typically less than a second each), except that the last one (xform using NETFILES) may take up to a minute if you have a slow or inoperative Internet connection. If any application test fails, its output (program.out) can be found in the checkpkg subdirectory of the WFDB source tree; compare this output with the file of the same name that can be found in the checkpkg/expected subdirectory.
If you are running a 64-bit Linux kernel, install WAVE now (optional, requires root permissions). WAVE must be compiled in 32-bit mode, because it requires XView libraries that do not support 64-bit mode. On 64-bit Fedora, simply run the installer:
./install-wave32The installer will download and install 32-bit XView and other compatibility libraries, and compile and install a 32-bit version of the WFDB library, before compiling and installing WAVE itself.
If you are not using Fedora, the names of the required 32-bit compatibility libraries may differ; read and modify the install-wave32 script as necessary for your distribution before running it.
wave -r mitdb/200 -a atrIf you have not used WAVE before, you may want to follow through the tutorial material in the beginning of the WAVE User's Guide.
rpm -Uvh wfdb*rpm /sbin/ldconfig
You might need to do this in order to compile other software that uses the WFDB library and that must be compiled into a 32-bit executable, such as ecgpuwave.
If you have run ./install-wave32 successfully as described above, you have installed a 32-bit WFDB library already. Otherwise, install a 32-bit libcurl or libwww library if possible, then run these commands (root permissions will be required for the last one):
make clean ./configure -m32 cd lib make install
As noted above, although there has been limited support for compiling 64-bit versions of the WFDB Software Package for some time, version 10.4.9 is the first version to support this fully. If you wish to try compiling any earlier version in 64-bit mode, uninstall XView before attempting to do so, since the presence of XView will confuse pre-10.4.9 versions of WFDB's configure script, leading to compilation and configuration errors that may be difficult to correct.