Praise be to Allah, the Lord of the Worlds; and may His blessings and peace be upon our Prophet Muhammad and upon all his Family and Companions.
Allah Says (interpretation of meaning): {Alms are for the poor and the needy, and those employed to administer the (funds); for those whose hearts have been (recently) reconciled (to the Truth); for those in bondage and in debt; in the cause of Allah; and for the wayfarer: (thus is it) ordained by Allah, and Allah is full of knowledge and wisdom. }[9:60]. These are the recipients of Zakah. The Muslim scholars state that anyone who gives Zakah for any other recipient, he commits a sin and Zakah is still due upon him.
Some scholars, however, have put what you mentioned under the category of "in the Cause of Allah" but the truth is that this category is limited to Jihad in the way of Allah and what is related to it such as the expenditure of the Mujahid, his weapons, …etc. So, if this can be paid in this way, it should not be paid in any other way. Now, if it cannot be paid in this way, then scholars have different opinions of how to dispose of it. The first opinion is that this share is returned to the other recipients and distributed among them. The second opinion is that it can be used in what you asked about. We believe that if there is dire necessity for this Islamic library and there is no other way to get it done, then part of the Zakah can be used for this purpose otherwise no.
Allah knows best.