Patents are a different issue altogether. I'm not suggesting someone can protect information. If you want a library, buy the book, and reprint the copies yourself. It's the fact that the state steal from everyone, uses the stolen proceeds to buy a few copies of a book, then charges people for borrowing the books they stole money to get.
Publishers print books at a loss for the future sales to eventually make money. If you publish a book, you will want to recoup some of the cost, libraries work against that.
Patents are bad but so are libraries.