AnsweredAssumed Answered

Build Selected file fails in various ways

Question asked by JohnC-vid on Jun 8, 2016
Latest reply on Jun 23, 2016 by Kader.M

(CCES 2.2.0,  building for BF706 , testing on Ez kit mini)

 

If a single file is built using the "Build selected File(s)" - via a right click on the file in project explorer, the results can be significantly different to those obtained using Project Build All (Hammer icon).   The problem appears to be in the path string supplied to the compiler "-path-output" switch, when the file is a reference, and using -save-temps

 

Examples:

 

1. File #1.  Resource "my_driver" is a link to a file, added to a folder "Drivers70x" in the project (i.e. at same level as src ). This folder contains only file links and contains no real files - it is empty as viewed in Windows Explorer.

    The actual  file "my_driver.c" is located in a shared folder (also called  Drivers70x) at the same level as the projects within the workspace. The link in this case contains the complete absolute path to the file.

  The command line for this file has "-save-temps -path-output ./../Drivers70x" .... "-o Drivers70x/my_driver.doj"

  The build works OK - the output file is placed in to the correct place in the Debug build output. But the intermediate files get placed into the (empty) folder that contains only file links for my drivers.  It appears that the compiler has taken the relative path of the file to the project, and applied it to the \debug output directory - which in this case just happens to address my empty link resources folder.

Eclipse now sees the intermediate file "my_driver.s" within the source structure  as well as "my_driver.c", resulting in numerous errors. Depending on the sequence of  Build file /Build all/ Clean operations, it can produce faults at the make file level,  or just really confusing behaviour due to using an outdated intermediate as the source.

 

Build All  correctly sets the temp paths "-path-output ./Drivers70x" placing the intermediate files in the same directory as the .doj output i.e. "Debug\Drivers70x"

 

2. File#2. Resource "ser_flash_prog" is a link to a file, added to a folder "Utils" in the project (i.e. at same level as src ).

This folder contains only file links and contains no real files - it is empty as viewed in Windows Explorer.

The physical file "ser_flash_prog.c"  location is completely outside the workspace in a shared folder at C:\xxx\Blackfin\Utils

The file link is created using variable UTILS_DIR  defined via Workspace/linked resources as absolute location

"C:\xxx\Blackfin\Utils"

The file link reference is UTILS_DIR\ser_flash_proc.c , (generated using New File - Link to file- Variables-extend),

- this resolves correctly to the file.

A Build All works correctly with both the .doj and intermediate files output to Debug\Utils.

 

Build Selected file completely fails. The symbolic link is completely misinterpreted for the -path output

" -path-output ./C:Blackfin/Utils"  and the malformed path gives a compiler error

 

Other problems

3.  Build selected files does not update the problems output window. Compile errors only appear in the console window

4.  It is not possible to double click on a compiler error in the console window to navigate to the fault. (The help system implies that you can)

5. If a build error occurs on the rebuild when starting a debug session, the error messages in the console window are completely lost,   as the window is cleared on starting to run the code.

VDSP had separate console tabs to differentiate build and console output

 

John C

Outcomes