-
Notifications
You must be signed in to change notification settings - Fork 39
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
[request] Dynamic Source File Lists #78
Comments
Hi @Suudy, thanks for your suggestion! I can see the use of constructing the source file list through commands. However, I think letting Bender execute an arbitrary command provided in a manifest file would be catastrophic from a security perspective, as it essentially forms a Shellcode threat. Could your use case instead be implemented by adding an include command to the |
I’m not seeing a concern for shell code exploit. This is all executed within the context of a project which are under the control of developer. Unless you are concerned with remote repositories owned/maintained by third parties? in that case, perhaps a global enable that has to be turned on to support execution of code? This feature is desirable within bender because it automatically determines which components need dynamic file lists without a manual step. I’m not sure how a large project might navigate the generation of these include lists. |
An include list could work if we allow a command to be called as a separate step. And that could be limited by a global flag. Something like:
|
Yes. You would have to trust the developers of any dependency (and of its dependencies, etc.) to run any command on your machine.
What makes the file list dynamic? Is RTL code generated from higher-level code? Can the RTL code files not be enumerated a priori and/or can they not be checked into a repository that forms a Bender package? |
The example I can give is in Vivado. What I typically do is write some TCL to generate a core and then use a TCL command to export the list of files. That list of files can change depending on the version of the core, whether it is configured for simulation or synthesis, etc. Normally I do a single TCL file for the whole project, then call individual TCL files for each generated core. I then gather all the sources files, calling While they could be enumerated in advance, the list can change depending on the context or even on the version of the core. |
One other example. We have two entities depending upon whether it is a debug component or not. For example:
And the architecture:
This component, which may be multiple layers down in the hierarchy needs to be pre-processed. If I have to rely upon the top level to run commands to pre-process (or generate different file lists), then I've tightly coupled my top level with the components in my hierarchy. |
Hi @Suudy, |
* banshee: Fix return value checking * banshee: Add write to `eoc` to all binaries
It appears the file lists in the Bender.yml are static. Perhaps some support to call a hook (Python? Shell Script? Command?) that returns a list of source files.
The specific use case is for the Xilinx IP generators where one might invoke Vivado, create a core, then export the list of files.
Perhaps syntax such as:
Not being a Rust developer myself, I'm unsure how to add the behavior myself and generate a pull request.
The text was updated successfully, but these errors were encountered: