ART: Fix old warnings

Fix Wundefined-var-template warnings.

Partially reverts commit df53be273509dd43725870fb20a2c7d71f7fbfd3.

Bug: 28149048
Bug: 29823425
Test: m
Test: m test-art-host
Change-Id: Ib077312558f9e2f784859861c000fbac8375b3f5
diff --git a/runtime/mirror/array.h b/runtime/mirror/array.h
index 7287a92..99565c6 100644
--- a/runtime/mirror/array.h
+++ b/runtime/mirror/array.h
@@ -188,6 +188,16 @@
   DISALLOW_IMPLICIT_CONSTRUCTORS(PrimitiveArray);
 };
 
+// Declare the different primitive arrays. Instantiations will be in array.cc.
+extern template class PrimitiveArray<uint8_t>;   // BooleanArray
+extern template class PrimitiveArray<int8_t>;    // ByteArray
+extern template class PrimitiveArray<uint16_t>;  // CharArray
+extern template class PrimitiveArray<double>;    // DoubleArray
+extern template class PrimitiveArray<float>;     // FloatArray
+extern template class PrimitiveArray<int32_t>;   // IntArray
+extern template class PrimitiveArray<int64_t>;   // LongArray
+extern template class PrimitiveArray<int16_t>;   // ShortArray
+
 // Either an IntArray or a LongArray.
 class PointerArray : public Array {
  public: