Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 347188

Summary: Internal builder may fail if the tool has inputs from the project options
Product: [Tools] CDT Reporter: Alex Freidin <freidin.alex>
Component: cdt-build-managedAssignee: Project Inbox <cdt-build-managed-inbox>
Status: NEW --- QA Contact: Jonah Graham <jonah>
Severity: normal    
Priority: P3 CC: cdtdoug, mario.pierro, yevshif
Version: 8.0   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Attachments:
Description Flags
Patch none

Description Alex Freidin CLA 2011-05-25 12:13:18 EDT
Build Identifier: M20100909-0800

If a tool is defined to receive an input from the value of a project option, the build may fail with internal builder.
The project option contains one or more input files. The problem is that the user may define them with a build directory relative syntax, e.g. ../src/file.in. This case is not handled. Specifically, when BuildDescription.calculateInputs() calls BuildDescription.addInput(String,BuildIOType), the latter calls addInput(IPath, BuildIOType) whose JavaDoc says "path IPath relative to the project, or absolute filesystem location". Passing an IPath with "../" syntax then causes an exception. In other words, an input with "../" syntax should be translated into a valid IPath before the call.



Reproducible: Always
Comment 1 Alex Freidin CLA 2011-05-25 12:15:26 EDT
Created attachment 196571 [details]
Patch

Translate a path with a relative syntax into a valid IPath.