1. New caching deployment mechanism: Now use per-app cache directory.

2. New cache naming.

Change-Id: I2d11b4e587cf76471792abf2d292a0075dea74d1
diff --git a/lib/bcc/Compiler.h b/lib/bcc/Compiler.h
index 0d5f7bf..444d136 100644
--- a/lib/bcc/Compiler.h
+++ b/lib/bcc/Compiler.h
@@ -148,7 +148,10 @@
       return hasError();
     }
 
-    int readBC(const char *bitcode, size_t bitcodeSize,const BCCchar *resName);
+    int readBC(const char *bitcode,
+               size_t bitcodeSize,
+               const BCCchar *resName,
+               const BCCchar *cacheDir);
 
     int linkBC(const char *bitcode, size_t bitcodeSize);
 
@@ -211,9 +214,13 @@
     //              cache file's file descriptor
     //              Note: openCacheFile() will check the cache file's validity,
     //              such as Magic number, sourceWhen... dependencies.
-    int openCacheFile(const BCCchar *resName, bool createIfMissing);
+    int openCacheFile(const BCCchar *resName,
+                      const BCCchar *cacheDir,
+                      bool createIfMissing);
 
-    char *genCacheFileName(const char *fileName, const char *subFileName);
+    char *genCacheFileName(const char *cacheDir,
+                           const char *fileName,
+                           const char *subFileName);
 
     /*
      * Read the oBCC header, verify it, then read the dependent section