Yes, libraries in the sense of a precompiled libsomething.a
file. Not meant for a source file.
They must be in src/
folder or in a library for PlatformIO to trigger its compilation. You can create a folder in which you create a library folder in which you put the common C/C++ files. Two projects can reference this extra library folder via lib_extra_dirs
without duplication. This has been asked before, e.g. at Sharing source files between 2 pio projects.