From: BNCarper AT cs DOT com Message-ID: Date: Sat, 14 Jul 2001 12:44:44 EDT Subject: Using .lib files To: djgpp AT delorie DOT com CC: eliz AT is DOT elta DOT co DOT il MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Mailer: CompuServe 2000 32-bit sub 107 Reply-To: djgpp AT delorie DOT com On Sun, 1 Jul 2001 BNCarper AT cs DOT com wrote: > I'm trying to build some custom software for my CCD Astronomy camera. The > mfg. provides a header file (.h) and a library file (.lib) for persons > wanting to write the software in DOS. They then provide several .dll for Win > 32 programming using MSVC or VB. I have already written some of the software > in MSVC 6.0 but I have always preferred using DJGPP. >Did you try any of the methods listed in section 17.5 of the FAQ? They >are you only hope. Thanks for your help. I have found where the mfg. has let someone build the library in LINUX, so I have a library file in .a format. Can I use that in DJGPP? I have tried but the header file has the following code at the end of the header file. I can't seem to get the program to find the ParDrvCommand(). Do I need to change the ENV_DOS to DJGPP somehow? /* Function Prototypes This are the driver interface functions. ParDrvCommand() Supports Cameras Each function takes a command parameter and pointers to parameters and results structs. The calling program needs to allocate the memory for the parameters and results structs and these routines read them and fill them in respectively. */ #if TARGET == ENV_DOS #ifdef __cplusplus extern "C" short ParDrvCommand(short command, void*Params, void*Results); #else extern short ParDrvCommand(short command, void*Params, void*Results); #endif #elif TARGET == ENV_WIN #ifdef __cplusplus "C" short __export ParDrvCommand(short command, void far *Params, void far *Results); #else short __export ParDrvCommand(short command, void far *Params, void far *Results); #endif #else #ifdef __cplusplus extern "C" __declspec(dllexport) short ParDrvCommand(short command, void*Params, void*Results); #else extern __declspec(dllexport) short ParDrvCommand(short command, void*Params, void*Results); #endif #endif Thanks, Bob