Make cppreopts.sh deal with new layout

.odex and .vdex files on system_other are being moved to a subdir
with the name of their source partition. Update cppreopts to
recognize this and pass the right source path to preopt2cachename.

Bug: 141707536
Test: manually verify name of dalvik-cache files post boot
Test: dumpsys package [system-package]; verify reason=prebuilt
Change-Id: Icb5b5307ad42b7c899e11212843ce4b96b015958
diff --git a/cppreopts/cppreopts.sh b/cppreopts/cppreopts.sh
index 3416e67..d409db8 100755
--- a/cppreopts/cppreopts.sh
+++ b/cppreopts/cppreopts.sh
@@ -53,7 +53,7 @@
   # NOTE: this implementation will break in any path with spaces to favor
   # background copy tasks
   for file in $(find ${mountpoint} -type f -name "*.odex" -o -type f -name "*.vdex" -o -type f -name "*.art"); do
-    real_name=${file/${mountpoint}/\/system}
+    real_name=${file/${mountpoint}/}
     dest_name=$(preopt2cachename ${real_name})
     if ! test $? -eq 0 ; then
       log -p i -t cppreopts "Unable to figure out destination for ${file}"