Skip to content
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

feature: Include environment variable in search path during redhawk-codegen #55

Open
nimartet opened this issue Mar 17, 2023 · 0 comments

Comments

@nimartet
Copy link

I am using Redhawk 2.10 and was trying to generate a component that uses ports defined in JTRS idl. When I tried to generate the component, I received "No such file or directory" errors when parsing IDL. I since learned that it was because the code generation does not look at any environment variables or provide search path options for codegen. After submitting a question to stackoverflow, I used the information gained to update idllib.py to parse an environment variable to add to the search path:

bash# diff idllib.py idllib.py.bak
75,80d74
<         idl_path = os.environ.get('IDL_PATH')
< 
<         if idl_path:
<             for path in idl_path.split(os.pathsep):
<                 self.addSearchPath(path)
< 

This solved my problem. Would be nice to make if official.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant