You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/07/29 07:50:34 UTC

[GitHub] [incubator-nuttx] SPRESENSE opened a new pull request #1470: Makefile: Fix Make.dep not updated by config changes

SPRESENSE opened a new pull request #1470:
URL: https://github.com/apache/incubator-nuttx/pull/1470


   ## Summary
   
   Make.dep file should be updated by .config changed after first make.
   There are 2 cases affected for this problem:
   
    1) Add source files by config symbol
    2) Include header files in #ifdef directive
   
   These 2 cases may not be included in Make.dep and this may prevent the
   differential build from working correctly.
   
   
   ## Impact
   
   Build system
   
   ## Testing
   
   Change configuration and check that Make.dep files are updated
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] v01d edited a comment on pull request #1470: Makefile: Fix Make.dep not updated by config changes

Posted by GitBox <gi...@apache.org>.
v01d edited a comment on pull request #1470:
URL: https://github.com/apache/incubator-nuttx/pull/1470#issuecomment-665084124


   I agree with the idea, in fact, it is always problematic to realize a build failure is due to out-of-date Make.dep files. I personally I'm used to deleting Make.dep/.depend files whenever I add new sources files (not so problematic because you know what you're doing) or I change configuration and something does not work right (this is the difficult case, since it becomes trial and error).
   
   However, I'm not so sure that simply recreating dependencies whenever .config changes is the best idea as the dependency generation is REALLY slow. I tried to see why it is so slow and could not find a way to improve it. Again, I agree with the change but I wouldn't like if it add so much overhead after every configuration change. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] patacongo commented on pull request #1470: Makefile: Fix Make.dep not updated by config changes

Posted by GitBox <gi...@apache.org>.
patacongo commented on pull request #1470:
URL: https://github.com/apache/incubator-nuttx/pull/1470#issuecomment-665101348


   > However, I'm not so sure that simply recreating dependencies whenever .config changes is the best idea as the dependency generation is REALLY slow. I tried to see why it is so slow and could not find a way to improve it. Again, I agree with the change but I wouldn't like if it add so much overhead after every configuration change.
   
   There is a way to make the dependency generation faster in some cases.  The Make.dep file has to be recreated when any .c file modified.  Since the Make.dep creation recreates the dependencies for all .c files, that takes a long time.
   
   An alternative is to keep all of the dependencies in separate .d files in a sub-directory.  Then when a .c file changes, only one .d file needs to be recreated.
   
   I have not looked at Linux in a long time but I believe that they implemented a lot of tricks to keep from rebuilding everything.  I think they did things like:
   
   - Put the inclusion of config.h on the gcc command line rather than in the C code (that, of course, is not portable to other compilers so we should not consider it).
   - I recall that Linux breaks config.h in many separate, small header files in sub-directories.  I am not sure how this helps the rebuild time.
   
   Looking at how Linux has optimized the use of .config files might be worth the time.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] xiaoxiang781216 merged pull request #1470: Makefile: Fix Make.dep not updated by config changes

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 merged pull request #1470:
URL: https://github.com/apache/incubator-nuttx/pull/1470


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-nuttx] v01d commented on pull request #1470: Makefile: Fix Make.dep not updated by config changes

Posted by GitBox <gi...@apache.org>.
v01d commented on pull request #1470:
URL: https://github.com/apache/incubator-nuttx/pull/1470#issuecomment-665084124






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org