I'm checking out hydra branch and wanted to help, but encountered some
changes in the architecture that wanted to ask about.
Seems there are two places FFI::Generators::Structure is been used:
one to generate platform.conf (rakelib/platform.rake) and the other
through FFI::FileProcessor::Task (invoked in rakelib/vm.rake)
The first one, it uses .rb.ffi to extract @@@ constants and structure
definitions and generate the proper .rb file, the second one, is is
coded directly in platform.rake.
Now, on Windows, pwd.h and grp.h do not exist, and etc is a complete
different thing, sames goes for syslog.
On platform.rake is easy to conditionally select header files, since
we have access to BUILD_CONFIG, but in the case of .rb.ffi, is not
clear what can be considered a good code to be evaluated and
conditions inside the @@@ blocks.
Any ideas to approach this? I believe etc and syslog are just two
examples, but will be great have an overall approach to these cases.
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry