In order to compile your applications using the Universal Driver, you must first perform several tasks: You must ensure that the proper header and library files are copied to a known location. For DOS, Windows 95/98, and Windows NT/2000/XP development, you may install the files anywhere you like, and point to this location when you compile your project. In Linux, when you install the RPM, the files will be located in the /usr/local/dscud5 directory. You must include the above-mentioned header and library files in your project when compiling. Your INCLUDE directory must point to the location of the dscud.h file, and your LIB directory must point to the appropriate library file (dscudbcl.lib for 16-bit DOS, dscud.lib for 32-bit Windows 95/98/NT/2000, or libdscud5.a for Linux). If you are using DOS or Windows 95/98/NT/2000/XP, you must remember to compile your applications using single byte alignment packed data structures. For DOS applications, you can set this in the Borland IDE by setting the compiler options to compile using BYTE rather than WORD alignment. For Windows applications, you can set this in Microsoft Visual Studio by setting the Code Generation options in the project settings to use 1-byte structure alignment. If you are using Linux, you do not have to worry about this issue.
Notes for Linux
The driver uses Pthreads internally for multithreading. For this reason, developers must link with libpthread when compiling their applications. An example compile command is:
$ gcc -o myapp myapp.c -L/usr/local/dscud5 -ldscud5 -lpthread
This page was last modified 22:29, 2 Aug 2005.
Copyright (c) 2004 Diamond Systems. All Rights Reserved.