Cygwin Build Notes

  1. Cygwin build commands

    bash buildall.sh -c gcc -x g++ --with-configure-env="LDFLAGS='\
        -no-undefined'"
  2. Building dbxml-tcl lib on cygwin

    Install tcl libs on cygwin by cygwin setup application.

    Modify db-6.1.x/dist/Makefile.in:

    - LIBTSO_LIBS=    @LIBTSO_LIBS@ @LIBSO_LIBS@
    + LIBTSO_LIBS=    @LIBTSO_LIBS@ @LIBSO_LIBS@ -ltcl

    Modify dbxml/Makefile.in:

    - libdbxml_tcl_la_LDFLAGS = -release $(DBXML_VERSION_MAJOR).$(DBXML_
    VERSION_MINOR) $(TCL_LIBRARY_EXTENSION)
    + libdbxml_tcl_la_LDFLAGS = -release $(DBXML_VERSION_MAJOR).$(DBXML_
    VERSION_MINOR) $(TCL_LIBRARY_EXTENSION) -no-undefined -ltcl -ltclstub

    Build dbxml:

    ./buildall.sh --enable-test --with-tcl=/usr/lib/ \
    --with-configure-env="LDFLAGS='-no-undefined'"

    Now the static libs of dbxml_tcl are generated. If you want dbxml_tcl.dll, continue to next step:

    Build dbxml_tcl-6-0.dll

    cd dbxml/build_unix
    g++ -shared -nostdlib .libs/libdbxml_tcl_la-dbxml_tcl_wrap.o \
    -ldbxml -o ../../install/bin/cygdbxml_tcl-6-0.dll -lstdc++ \
    -ltcl -lgcc -lcygwin -lkernel32 -ldb_tcl-6.1 \
    -L../../install/lib -L.libs/
    
    cd ../../install/bin
    
    ln -sf cygdb_tcl-6.1.dll libdb_tcl-6.1.dll
    
    ln -sf cygdbxml_tcl-6-0.dll libdbxml_tcl-6-0.dll