DCHK Client Version 0.5.7 - Documentation |
![]() |
There are two ways to get the sourcecode:
You can download an official release from http://dchk.sourceforge.net/. This is usually a ".tar.gz" or ".zip"-file, which contain the sources. There is also an installer for Microsoft Windows, which contains precompiled binaries as well as the sources and documentation.
You can check out the source code from our CVS repository at sourceforge.net through anonymous (pserver) CVS with the following instruction set. When prompted for a password for anonymous, simply press the Enter key. Please keep in mind, that the files in the CVS repository can be newer than the ones in the latest release and even unstable.
cvs -d:pserver:anonymous@dchk.cvs.sourceforge.net:/cvsroot/dchk login cvs -z3 -d:pserver:anonymous@dchk.cvs.sourceforge.net:/cvsroot/dchk co -P client
You can find more information here: http://sourceforge.net/cvs/?group_id=239063
DCHK needs the following packages / libraries:
If you want to compile the GUI, you will need QT Version 4.3.3 or above from Trolltech.
So far, the dchk library and client was successfully compiled and tested on the following systems:
Hardware | OS | Remarks |
---|---|---|
AMD/Intel 32Bit | Windows XP SP2 | Compiled with MinGW. It does not run on Windows 2000, you will get an error message that "freeaddrinfo" is not found in WS2_32.dll. |
AMD/Intel 32Bit | Fedora Core 5-8 | - |
AMD/Intel 64Bit | Fedora Core 5 | Should work on other Versions, too |
AMD/Intel 32Bit | FreeBSD 7 | Should also work on older versions |
AMD/Intel 64Bit | Debian | - |
AMD/Intel 32/64Bit | Ubuntu | - |
Sun Sparc | Solaris 9 | -Setting of timeout does not work. If you get the error message |
First, unpack the source distribution:
tar -xzf dchk-1.0.0.tar.gz
Then change into the newly created sub directory dchk-1.0.0
cd dchk-1.0.0
DCHK comes with a GNU Autoconf configure-script. In most cases it will be sufficient, if you simply type "configure" without any options.
./configure make make install
If configure can't find something, you have to add a few optional parameter, the path to libxml or zlib for example:
./configure --with-zlib=/usr/local --with-xml-prefix=/usr/local
By default the library and client will be installed under /usr/local
. If you want to install in a different path, use --prefix=PATH
as another option:
./configure --prefix=/home/patrick --with-zlib=/usr/local --with-xml-prefix=/usr/local
After installation, you will find the following files:
$PREFIX/bin/dchk | the DCHK client |
$PREFIX/lib/libdchk.a | the static library |
$PREFIX/include/dchk.h | the header file |
$PREFIX
is either /usr/local
or whatever prefix you defined in the configure process.
By default the Makefile will produce a "release" version, which is compiled with optimization flags and without any debug information. But you can also build a "debug" version:
make debug
will build the debug versionmake install_debug
will install the debug versionPlease note that the names are slightly different in this version:
$PREFIX/bin/dchk-debug | the DCHK client |
$PREFIX/lib/libdchk-debug.a | the static library with debug informations |
$PREFIX/include/dchk.h | the header file |
$PREFIX
is either /usr/local
or whatever prefix you defined in the configure process.
If you want to install both versions, you can simply type make all
, which builds and installs everything.
You need Windows 2000 or Windows XP to compile the DCHK library and client. Windows Vista could work, but I have no possibility to test it.
The DCHK-Library comes with Visual Studio 2008 project files for the library and the client. You can find them in the sub directory "vs2008". Please make sure that the required libraries are already installed and that your Visual Studio can find the include files and libraries.
You can compile the library and DCHK client with MinGW. You need to install MingW, MSys and the required libraries first. Then open the MSys shell. Configuration and compilation is the same as for UNIX (see above).
If you run the configure script described above, it will also tries to configure the GUI. This is experimental yet, so it may work or not. If it works, you can simply type make gui
to build the GUI. If not, you have to do some manual work.
You will find the source code of the GUI in the sub directory src_gui
. Open the "qdchk.pro"
file and edit the marked lines to match your paths:
qdchk.pro:
CONFIG += debug_and_release TEMPLATE = app INCLUDEPATH += app unix:INCLUDEPATH += /usr/local/include unix:QMAKE_CXXFLAGS += -I/usr/include/libxml2 win32:INCLUDEPATH += c:/mingw/msys/1.0/local/include
QT += core \ gui HEADERS += qdchk.h \ qdchk.h SOURCES += main.cpp \ qdchk.cpp FORMS += qdchk.ui \ qdchk.ui RESOURCES += res.qrc \ res.qrc \ res.qrc RC_FILE = qdchk.rc CONFIG(debug, debug|release) { TARGET = qdchk-debug unix:LIBS += -lstdc++ -lresolv -L/usr/lib -lxml2 -lz -lm -ldchk-debug win32:LIBS += -lstdc++ \ -Lc:/mingw/msys/1.0/local/lib \ -ldchk-debug \ -lxml2 \ -lws2_32 \ -ldnsapi
} else { TARGET = qdchk unix:LIBS += -lstdc++ -lresolv -L/usr/lib -lxml2 -lz -lm -ldchk-debug win32:LIBS += -lstdc++ \ -Lc:/mingw/msys/1.0/local/lib \ -ldchk \ -lxml2 \ -lws2_32 \ -ldnsapi
}
On some systems you need the "-lresolve", on others this will result in an error message like "cannot find -lresolv". Please try what works on your system.
After that, type qmake
or qmake-qt4
or whatever it is called on your system. Please be careful: on some systems both files exists, but qmake
ist linked to the old version 3 of Qt, which will not work for this program.
If everything went fine, you should have a Makefile
now. Type make release
to build the release version. If you build with MinGW on windows, you should use "mingw32-make" instead of "make". On successful compilation, you should find a qdchk
binary in the release directory.