Swift packages: Sharing code between libraries (while exposing some APIs from the shared code)

Welp, my preferred option 2 throws a build error:

target 'Library Human' has sources overlapping sources:
lists all the source files that are shared between Library Human and Dog

So my current setup is 3 libraries: Animal, Human and Core exposing public and internal API details, which is not good, since library users will be able to access them.

I've also posted this on Stack Overflow. Feel free to answer on Stack Overflow as well (to get reputation :sweat_smile:), otherwise I will update it.