-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buildbarn creates output directories based on the root directory #18
Comments
I agree that this is an issue indeed.
This is the part that confuses me: under what circumstances would the input root not be the top level build directory? If this were allowed, what would the name of the input_root be? It wouldn't be provided as part of the build action, meaning the action would not be able to make any assumptions whatsoever to be able to find its input root. |
I don't think that's possible. The problematic structure is the following, as far as I can tell:
According to the spec, the output directory should be specified as |
That said, one change we should consider making to Buildbarn at some point is that we do move the input root into some kind of subdirectory, reserving the top-level directory for other storage purposes. For example, stdout and stderr of build actions are currently stored as files inside the input root. So like this:
Though most build actions generally don't care about that, it's a bit sloppy. If a build action would try to
|
Ah yes, @juergbi is correct there.
Was intended to be
To address this issue, I propose that it is necessary to
|
Whilst looking to fix this I ran into several issues due to restrictions in bb-storage around valid file path components. Due to being unable to specify As to changing the relative pathing of output directories, I was hacking around with Qinusty@381923e#diff-48b3c6a7d58dce08bdf7f742b515e206R453 as a potential solution of concatting the paths of the working directory with output directories to avoid having to handle |
(The above issue but as a comment here) I've encountered this bug when using Buildbarn as a RE service for recc. For example, when using CMake, or any build system doing out-of-tree builds, it is typical to have a directory structure such as
The build is started by running Make in However, due to the described bug, Buildbarn will attempt to create the output object files in |
Buildbarn sets output directories relative to root directory as opposed to the working directory.
This can be seen here.
The RE protos (v2) specify that the working directory as:
This becomes an issue when the working directory is not specified as the input root and the output is specified as a subdirectory of the input directory outside of the working directory.
bb browser
Looking at an example action from a buildstream execution through the eyes of bb-browser shows the following buildbarn-buildstream.pdf
Buildstream specifies the working directory as
/buildstream/autotools/hello.bst/doc/amhello
whilst expecting buildbarn to provide../../../../../
relative to the working directory as an output directory (which would be/
).Buildbarn seems to interpret this as
../../../../../
relative to/
.Required change
Specified paths:
Current paths:
The text was updated successfully, but these errors were encountered: