So, I have a custom AOSP image that I'm building, and it allows me to provide my own kernel and debugging features that I want (this is just for the record, because you can't do some things that are needed with a regular AVD). I need to change the contents of /vendor, and I thought that I could do this by providing my .img file to the emulator with:
emulator -vendor /path/to/my/vendor.img
But, as I checked, the md5sum does not match for some files between my vendor.img and in the /vendor/path/to/file when I run the emulator and connect with adb shell. This is perplexing to me, because when I run with -verbose, I can see the arguments given to qemu for the drive and I expect that img to be mounted under /vendor. Looking at the original vendor-qemu.img with 7z, I can check the md5sum of ome files and see that despite the -vendor argument, the sums did not change to the values in my img, but match the old intead. I even went to the length of renaming the original vendor-qemu.img and putting my img in it's place with the name vendor-qemu.img. Same result with the md5sums though.
Perhaps I could be wrong, and the -vendor emulator argument shouldn't change the contents of /vendor in the running emulator instance. What do I do to get the /vendor directory contents of a running emulator instance to match with the vendor.img?