Compilation error with invalid type and undefined variables

In reply to cgales:

In reply to Joker0208:
Your code compiles ok for me, so there is likely something in your actual code that is different then what you posted.
If you can post a complete example that others can run which exhibits the exact error you are seeing, perhaps more assistance can be provided.
Also, you mention ‘compile the sv header file’, which doesn’t make sense. If you are compiling the package, you don’t need to compile the individual header files.

The code is exactly the same with the GitHub code, the link is Your text to link here….
Now I move the enum type definition to another package and import it to the header file, then it get compiled. So I am suspecting the header file cannot see the definition of ‘operation_t’ to get it compiled.