When both_libraries() reuses object files from the shared library
for the static library via ExtractedObjects, the object filenames
must match those produced for the shared library. For non-built vala
source files in subdirectories, object_filename_from_source() was
using os.path.basename() which dropped the subdirectory component,
while the actual compilation preserved it.
Use os.path.relpath() against the target's source directory instead,
matching the logic in generate_vala_compile().
Fixes: #6960
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>