There's soooooo much out there. In terms of libraries, I think you're going to find what limited information there is as part of a thorough "history of the book." While we know libraries existed, it's hard to really talk about them institutionally. Problematically, we don't have a huge number of bibliographic inventories of collections until much later periods, and those that we do are likely incomplete.
That said, scholars of the Middle Ages have really gone after the history of books and manuscripts more generally. Because much of the bibliography of classical texts were transmitted by monastic (and other) institutions, the huge increase in surviving source material in physical form, the formative transition from scroll/papyrus to parchment/codex, which was technological revolution, even if it was an expensive one, and, I think, the bibliohpilic nature of medieval studies has made this a significant historiography.
Then, of course, the birth of print and the study of that revolution has made the study of the early modern book immense. I think The Book in the Renaissance is honestly one of my favorite works of history. I think the way he uses print runs of particular editions and other big picture data is really creative. His introduction will clue you into some of these earlier periods as well. He also, unsurprisingly, provides an excellent bibliography.
Edit: The author of the volume is Andrew Pettegree.