0INBerkeley DB: Building Shared Libraries for the GNU GCC compiler[PH

Building Shared Libraries for the GNU GCC compiler



IIf you're using gcc and there's no better shared library example for yourHarchitecture, the following shared library build procedure will probablywork.

    D
  1. Add the -fpic option to the CFLAGS value in the Makefile.

    

  2. =Rebuild all of your .o files. This will create a Berkeley DBBlibrary that contains .o files with PIC code. To build the sharedFlibrary, then take the following steps in the library build directory:

    


GNote, you may have to change the gcc line depending on the requirementsof your system.

)The file libdb.so is your shared library.ÿÿ