Temporarily use a separate var for including shared resources

Change-Id: I56636a1d7dfdaa070706f1991f80e03fe2f71069
diff --git a/core/base_rules.mk b/core/base_rules.mk
index 32e6b73..0b6e46b 100644
--- a/core/base_rules.mk
+++ b/core/base_rules.mk
@@ -427,10 +427,10 @@
 
 # This is set by packages that are linking to other packages that export
 # shared libraries, allowing them to make use of the code in the linked apk.
-LOCAL_APK_LIBRARIES := $(strip $(LOCAL_APK_LIBRARIES))
-ifdef LOCAL_APK_LIBRARIES
+apk_libraries := $(sort $(LOCAL_APK_LIBRARIES) $(LOCAL_RES_LIBRARIES))
+ifneq ($(apk_libraries),)
   link_apk_libraries := \
-      $(foreach lib,$(LOCAL_APK_LIBRARIES), \
+      $(foreach lib,$(apk_libraries), \
         $(call intermediates-dir-for, \
               APPS,$(lib),,COMMON)/classes.jar)