Hello,
As I noticed during the compilation of a project all object files are placed in the build directory.
When two files have the same name this runs into problems, with a few files this is no problem and easy to rename.
However I am using a few external libraries now and this is starting to become a problem.
I was wondering if anyone else had encountered this and might have a solution?
It would be great if somehow can rebuild the directory tree in the build directory or get multiple build directories on different levels.
I tried editing the rules.mk myself but I seem to be breaking more than fixing. I am using the 2.6.x release.
Cheers,
Gerard
prevent duplicate object files
Moderators: RoccoMarco, lbednarz, tfAteba
- Giovanni
- Site Admin
- Posts: 14891
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 996 times
Re: prevent duplicate object files
You may compile external libraries into actual .a libraries using a separate makefile, that should not cause conflicts.
I don't think that building an objects subtree is even possible because paths are not necessarily below the project directory, objects could .. out of the build/obj directory.
Giovanni
I don't think that building an objects subtree is even possible because paths are not necessarily below the project directory, objects could .. out of the build/obj directory.
Giovanni
-
gvandenbosch
- Posts: 21
- Joined: Sat Nov 22, 2014 8:23 pm
Re: prevent duplicate object files
Hi Giovanni,
Ok I see, making it to a library is on my list.
On your other suggestion, moving the object files out of the build directory, would that have a big impact on the current makefiles?
Cheers,
Gerard
Ok I see, making it to a library is on my list.
On your other suggestion, moving the object files out of the build directory, would that have a big impact on the current makefiles?
Cheers,
Gerard
- Giovanni
- Site Admin
- Posts: 14891
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 996 times
Re: prevent duplicate object files
You could take the old rules.mk from 2.4, it puts objects in the same directory of source files. Probably there are small changes to do.
Giovanni
Giovanni
-
gvandenbosch
- Posts: 21
- Joined: Sat Nov 22, 2014 8:23 pm
Re: prevent duplicate object files
Hi Giovanni,
Thanks for the pointer, I had to go one version back to 2.2.10.
There were a few changes to be done and then it worked like a charm.
Attached is the modified rules.mk as reference for people that might want to do the same.
This is rules.mk form ARMCMX port.
Cheers,
Gerard
Thanks for the pointer, I had to go one version back to 2.2.10.
There were a few changes to be done and then it worked like a charm.
Attached is the modified rules.mk as reference for people that might want to do the same.
This is rules.mk form ARMCMX port.
Cheers,
Gerard
- Attachments
-
- rules.mk.zip
- armcmx rules.mk
- (1.6 KiB) Downloaded 453 times