LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

multiply defined symbol using *.def file

Hi,
 
I am encountering multiply defined symbol while using a *.def file in the project. I have attached the code here in the post. I have few restrictions on the code.
1. I have no permissions to modify the Core Code files (Pets.c, Pets.h and Pets.def)
2. I have to use the Pets.def file to call the functions in Pets.c (If this does not work I can eliminate the Pets.def file. This would be my last option.)
 
Any pointers or suggestions are helpful.
 
Thanks in Advance.
 
Regards,
Pradeep
 
0 Kudos
Message 1 of 2
(3,086 Views)
Hello Pradeep,

A .def or Module Definition file is used in Visual C/C++ to specify imported and exported functions when creating a DLL.  Here is more information about this from Microsoft's site:
http://msdn.microsoft.com/en-us/library/d91k01sh(VS.80).aspx

Since your Pets.def file has a function definition in it, you need to put this in a .C file and you you can put the declaration in a .h file.

Are you going to be building a DLL in an external compiler?  If so, then you will want to use a .def file to specify import and export functions, otherwise I don't think you should need to have one.




Message Edited by KristenC on 06-19-2008 03:38 PM
Kristen
National Instruments
0 Kudos
Message 2 of 2
(3,060 Views)