Multiple definitions between subfolders [message #1821707] |
Tue, 18 February 2020 21:03 |
Mr Loot Messages: 1 Registered: February 2020 |
Junior Member |
|
|
Hello,
I am developing an application in C needing a lot of code from an external supplier.
Under /src/ I have my main code:
/src/project.c
/src/project.h
I have downloaded code from a supplier that I have put under the folder /src/clientTCP/:
/src/clientTCP/clientTCP.c
/src/clientTCP/clientTCP.h
/src/clientTCP/common.c
/src/clientTCP/common.h
I am using functions of clientTCP in project.c and compilatio and execution works fine. I now need more code from the same supplier and have placed it under the folder /src/clientUDP/:
/src/clientUDP/clientUDP.c
/src/clientUDP/clientUDP.h
/src/clientUDP/common.c
/src/clientUDP/common.h
I now run into the multiple definitions problem. Some functions in clientTCP and clientUDP are called the same and the common files also have differences in implementation. I have tried including these subfolders under respective folder properties but to no avail. I need the functions of all directories but only one executable.
What am I doing wrong? Can I get clientTCP to only use definitions from its folder and the same for clientUDP? What is the simplest way of solving this problem?
I am using:
Eclipse Mars.1 Release (4.5.1)
MinGW GCC toolchain
Gnu Make Builder
CDT
|
|
|
Powered by
FUDForum. Page generated in 0.02495 seconds