Closed georgemorgan closed 7 years ago
By "language-specific code" do you mean extra C code enabling a specific language binding (we don't have any of that right now and IMO should keep it that way if possible) or code in the target language itself?
Many languages' build tools have the notion of a "package" or some other distributable unit, and typically such a unit exists under a single directory. In some cases there are specific restrictions how the source must be split into multiple files or folders (Java and Haskell both have such requirements, there may be more) It might not be easy to get these build systems to cope with source spread out through the driver folders.
Alternatively, we could enforce a common structure and naming scheme on all language binding source trees, but even this might not be possible (or desirable) in general, as different structural idioms will be necessary (or expected, or simply popular) in each case.
Swift certainly does.
Since we will be writing language bindings for all of the built-in Flipper drivers, perhaps we should come up with some way to organize the language-specific code necessary for each language binding alongside the C implementation for each FMR target.