+static
+gint compare_ds_file_groups_by_first_path(gconstpointer a, gconstpointer b)
+{
+ struct ctf_fs_ds_file_group * const *ds_file_group_a = a;
+ struct ctf_fs_ds_file_group * const *ds_file_group_b = b;
+ const struct ctf_fs_ds_file_info *first_ds_file_info_a;
+ const struct ctf_fs_ds_file_info *first_ds_file_info_b;
+
+ BT_ASSERT((*ds_file_group_a)->ds_file_infos->len > 0);
+ BT_ASSERT((*ds_file_group_b)->ds_file_infos->len > 0);
+ first_ds_file_info_a = (*ds_file_group_a)->ds_file_infos->pdata[0];
+ first_ds_file_info_b = (*ds_file_group_b)->ds_file_infos->pdata[0];
+ return strcmp(first_ds_file_info_a->path->str,
+ first_ds_file_info_b->path->str);
+}
+