[gdome]libgdome dll and test programs



Hi,

I thought this might be of interest for other people trying to use
libgdome on windows so I am cc'ing to the mailing list.

There are test programs included in the gdome2 distribution (directory
"test"). They can be compiled with the command line

gcc -o <prog>.exe <prog>.c `gdome-config --cflags --libs` \
    -DLOCALDIR=\"$PWD\"

from within the cygwin bash shell, using gcc. The output of

gdome-config --cflags --libs

is

-I/usr/local/include -I/usr/local/include/libgdome \
-I/usr/local/include/glib-1.3 -I/usr/local/include/libxml \
-L/usr/local/lib -lgdome.dll -lglib-1.3 -lxml2.dll

It sets the proper include search path and links the import libraries
libgdome.dll.a, libglib-1.3.a, libxml2.dll.a from /usr/local/lib in.

Most of the test programs included in the gdome2 distribution work. You
can compile them all with the command line

for src in *.c; do exe=`echo $src | sed -e 's/\.c/.exe/'`; gcc -o \
$exe $src `gdome-config --cflags --libs` -DLOCALDIR=\"$PWD\"; done

while in the test subdirectory.

test-cdata.c does not compile, but that's ok since it wants to include a
private header file. You can check that the resulting executables are
linked to the dll using cygcheck.

Execution of all generated test programs succeeds. Note that bench.exe
needs a command line argument.

Delphi might be another story. I have Borland's "C++Builder command line
tools" 5.5 installed and I am willing to try to use the dll with this
compiler. From what I know, Delphi and C++Builder share a common base, so
if one of these compilers works, the other should also. I have only used
this compiler for a simple cout<<"Hello World"; program so far, so it
might take a little time to discover what command line options it needs
and how to link to a dll.

Bye, Tobias






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]