diff --git a/libraries.module b/libraries.module
index 751ecea..fd5589b 100644
--- a/libraries.module
+++ b/libraries.module
@@ -372,9 +372,7 @@ function &libraries_info($name = NULL) {
         // Collect a list of viable themes for re-use when calling the alter
         // hook.
         $themes[] = $theme_name;
-
-        include_once drupal_get_path('theme', $theme_name) . '/template.php';
-
+        _libraries_load_theme($theme_name);
         $function = $theme_name . '_libraries_info';
         if (function_exists($function)) {
           foreach ($function() as $machine_name => $properties) {
@@ -434,6 +432,28 @@ function &libraries_info($name = NULL) {
 }
 
 /**
+ * Load a theme and its ancestors.
+ *
+ * @param string $theme_name
+ *   The theme machine name.
+ */
+function _libraries_load_theme($theme_name) {
+  // Collect ancestor themes.
+  $ancestry = array($theme_name);
+  $ancestor = $theme_name;
+  $themes = list_themes();
+  while ($ancestor && isset($themes[$ancestor]->base_theme)) {
+    $ancestor = $themes[$ancestor]->base_theme;
+    array_unshift($ancestry, $ancestor);
+  }
+
+  // Load theme template files.
+  foreach ($ancestry as $theme_name) {
+    include_once drupal_get_path('theme', $theme_name) . '/template.php';
+  }
+}
+
+/**
  * Applies default properties to a library definition.
  *
  * @param array $library
