[U-Boot] [PATCH] Switch from library archives to partial linking

Andreas Bießmann andreas.devel at googlemail.com
Sun Nov 7 16:30:40 CET 2010


Dear Sebastien Carlier,
Am 07.11.2010 um 16:11 schrieb Sebastien Carlier:

> Dear Peter,
> 
> On 11/07/2010 03:16 PM, Peter Tyser wrote:

>> - You shouldn't be making changes to stuff like CONFIG_CMD_NFS in this
>> patch.  Its unrelated, and should be dealt with in another patch.  eg
>> your patches could be:
>> 1/2: Fix boards with CONFIG_CMD_NFS but !CONFIG_CMD_NET
>> 2/2: Switch from library archives to partial linking
>> 
> 
> Sounds good, will do.
> 
>> I'm guessing lots of boards will have this same issue.  I imagine its
>> due to include/config_cmd_defaults.h, so maybe if you fix the issue in
>> that one place all the compile issues will go away.
>> 
> 
> The generic fix is to include the following lines somewhere at the end 
> of the config.h generated in the mkconfig script:
> 
> #ifndef CONFIG_CMD_NET
> # undef CONFIG_CMD_NFS
> #endif
> 
> These lines should probable be put in a new header file; would 
> config_checks.h be an ok name for it?  I suppose there might be other 
> cases where a module (that is included by default) needs to be excluded 
> when one of its dependencies is disabled.
> 

I guess the boards are broken before your library changes too. So yes you need to split these patches.
But two points regarding your described approach.
 - The respective boards need a fix, if they do (conditionally) disable CMD_NET and miss CMD_NFS it is their fault and the respective boards config should be fixed
 - The build for net commands need a fix if they will build NFS stuff without NET stuff

I dunno if it is required to have some config_checks.h, this may grow up to unexpected complexity.

regards

Andreas Bießmann




More information about the U-Boot mailing list