Install the needed Debian packages first. I needed the following Debian packages

libcurl4-gnutls-dev (for NETFILES feature support in WFDB, which allows you to work on portions of the PhysioBank data records online, without having to download the entire record on your computer)

libexpat1-dev (for XML parsing, some files did not compile successfully while installig the WFDB library because this package was missing)

Follow the steps under "if you download the sources (recommended):" in the official quick start guide. If you are on a 64-bit system (like me!) then do NOT install the WAVE application now

If you installed the WFDB library in a non-standard path (as I did), then probably you will need to adjust the $PATH and $LD_LIBRARY_PATH environment variables. I added the following snippet to my ~/.bashrc, (this will be automatically executed every time you login into a shell -- run '. ~/.bashrc' ('DOT SPACE ~/.bashrc') to execute the profile script immediately!) -- I also needed to manually copy the 'man' folder from the "(path to WFDB installation)/share/man" to '/usr/share/man' for manual enteries to be installed into the system!

# add WFDB binaries to PATH

PATH="$PATH:(path to WFDB installation)/bin"

# add WFDB libraries to LD_LIBRARY_PATH

LD_LIBRARY_PATH="$LD_LIBRARY_PATH:(path to WFDB installation)/lib64"

Now you are ready to install the optional WAVE application in case you are running a 64-bit system. For this, I followed the instructions in this post. (Note: package ia32-libs must be installed!) Finally, you will need to further modify your ~/.bashrc to append the following

# add WFDB-32 binaries to PATH

PATH="$PATH:(path to WFDB-32 installation)/bin"

# add WFDB-32 libraries to LD_LIBRARY_PATH

LD_LIBRARY_PATH="$LD_LIBRARY_PATH:(path to WFDB-32 installation)/lib"

Update1: With WFDB version 10.5.13 on Ubuntu 12.04, I had to manually change two lines in each Makefile of the subdirectories (app,checkpkg,convert,examples,fortran,psd,xml) to compile with libcurl successfully

10 comments:

The configure file does NOT generate the correct Makefile in subdirectories. Specifically, the variables $LC and $LL are set incorrectly in all subdirectories except for “lib”. This may be fixed byby making the following changes to conf/linux.def:LC = ‘curl-config --cflags”LL = ‘curl-config --libs’

This is a better solution than manually modifying Makefiles in all directories since those Makefiles are auto-generated.

I'm the author of the WFDB package. Sorry that youencountered this problem. The solution quoted by Murari Srinivasan was originally included in the comments in conf/linux.def, immediately above the lines that need to be changed, in every libcurl-compatible version of the WFDB library (the first one was version 10.3.17 in August 2005). (BTW, Murari used 2 backquotes (`), a double quote ("), and an apostrophe (') -- but all four of these should be backquotes.) In that file, LC and LL are empty by default, because (depending on how you wish to use the WFDB library) libcurl is not required in all cases. For example, in embedded devices with no network connections, libcurl is unneeded. The 'configure' script is intended to set the values of LC and LL.

The problem appears to result from changes in Debian's packaging or default installation of libcurl, which is called bythe WFDB library but not directly by typical WFDB applications. In most cases, the locations of shared libraries need to be specified only when compiling the code that invokes them (as is done when compiling the WFDB library). It's generally harmless to include this information even if it is unnecessary, however. I didn't do so originally because it causes complications (which I have since worked out) when compiling 32-bit code on 64-bit platforms.

Since Ubuntu 12.04 is based on Debian, this problem occurs there, too. It does not seem to be happening on RPM-based Linux distributions, but it's probably just a matter of time until it does.

To avoid this problem in the future, I've made a small change in the 'configure' script in the latest release (10.5.17, which I'll post on PhysioNet within the next hour), so that the line that was

if [ $LIBTYPE = "static" -a $NETLIB != "none" ]

is now

if [ $NETLIB != "none" ]

This change causes 'configure' to set LC and LL as needed by current versions of Debian and Ubuntu, without causing problems on other GNU/Linux distributions, as far as I can tell. Please let me know if you encounter any related problems in the future.

Favorite Quotes

"Try not to become a man of success but rather try to become a man of value" - Albert Einstein

- "Life is like riding a bicycle. To keep your balance you must keep moving" - Albert Einstein

"The only thing that interferes with my learning is my education" - Albert Einstein

"Computer science is no more about computers than astronomy is about telescopes" - Edsger Dijkstra

"Adding manpower to a late software project makes it later" - Brooks's Law

- "Engineering is the art of making what you want from things you can get" - Jerry Avins (?)

"Engineering for me is about being inventive, solving problems, being creative, and actually making things" - James Dyson

"For humans, honesty is a matter of degree. Engineers are always honest in matters of technology and human relationships. That's why it's a good idea to keep engineers away from customers, romantic interests, and other people who can't handle the truth" - Scott Adams

"Hate has a reason for everything. Love is unreasonable" - V. Raiuhes Ahaefvthe

"Tell me and I forget, teach me and I remember, involve me and I learn" -Benjamin Franklin