patacongo commented on issue #1880:
URL: 
https://github.com/apache/incubator-nuttx/issues/1880#issuecomment-698640629


   > 
   > 
   > @patacongo @btashton @xiaoxiang781216 It seems cygwin build using 
copydir.sh as DIRLINK in tools/Config.mk. In cygwin case, there are two copies: 
include/arch/chip and arch/arm/include/chip. And it finally only clean 
include/arch/chip. So could we switch to use link.sh as DIRLINK for cygwin 
build to keep one copy firstly? I have tested using link.sh locally and 
distclean verify ok. As to copydir.sh case, it may need separate out a 
clean_links target as @patacongo suggests.
   
   The Cygwin build does NOT use copydir.sh unless CONFIG_CYGWIN_WINTOOL is 
selected.   That is the problem.
   
   - Then Make runs during configuration, it includes .config.  But that is not 
 complete configuration file.  It is a defconfig file.
   - CONFIG_CYGWIN_WINTOOL is the default setting for the selected toolchain so 
it is NOT selected in the .config file
   - As a result, the dirlinks target uses symbolic links to create the links 
(WRONG)
   - After configuring, CONFIG_CYGWIN_WINTOOL will be be defined in the 
expanded, complete .config file
   - The next time Make runs, copydir.sh re-creates all of links with directory 
copy copies EXCEPT for the two links at arch/arm/include/chip and 
arch/arm/include/board.  Those are NOT replaced because the directory is copied 
into include/arch/board and include/arch/chip (the symbolic links are probably 
copied into include/arch as well (ALSO WRONG)
   - When 'make distclean' removes the links, the bad links at 
include/arch/board and include/arch/chip are not removed because the link 
target is include/arch/chip and  include/arch/board.  Hence, those two symbolic 
links are stranded and the CI build fails.
   


----------------------------------------------------------------
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:
[email protected]


Reply via email to