Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Multiple definitions between subfolders
Multiple definitions between subfolders [message #1821707] Tue, 18 February 2020 21:03
Mr Loot is currently offline Mr LootFriend
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
Previous Topic:Lib symbols could not be resolved
Next Topic:How to import a custom library into the Arduino project?
Goto Forum:
  


Current Time: Thu Sep 26 04:21:03 GMT 2024

Powered by FUDForum. Page generated in 0.02495 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top