Hi, A question reguarding project structuring in LpcXpresso, My file structure as follows :
MyProj1
|- src
MyProj2
|- src
CMSIS
|-Cmsis files
Drivers
|-USB
|-OtherDrivers
Shared_Src
|-SharedCode1
I have Lpcxpresso projects set up in Myproj1 and Myproj2, linked to CMSIS and compiling.
Now I want to use shared source in the Shared_Src folder between projects, rather than duplicating it. The shared source files are stored outside of the project folder as shown above.
I've done two things, first added it to the include search path, using the following : "${build_project}../../shared_src/" this works and header files in the shared_src can be reference by my project.
Next I need to use code in the shared_src dir, so I imported it into the project chosing the link option "Create links in workspace" this then adds to the shared_src folder and it's files as links, rather than duplicating them.
But the code fails to link when calling a function in shared_src from the project.
Any ideas, my goal is to have 1 or more projects share some of the same code. This shared code is configured based upon defines in the project so isn't a standalone lib.
Found it,
It seems LPCxpresso ticks the "Exclude resource from build" option when you import and link a directory into a project, helpful!
Right click the folder/file you have imported and make sure "Exclude resource from build" is unchecked.