(1) Most professors do not write a book. I would not say universities pay professors to write books.
(2) I understand your second point is about affordability. This is a tricky issue. Ideally, one would hope that his/her household income increases at a speed higher than inflation so that his/her purchasing power is increasing over time. Our problem today is that over the past 2-3 decades, a typical household’s income does not increase faster than inflation. As a result, the burden for paying stable-productivity services and products becomes an obvious drag. One then may feel the need to adjust spending pattern for consumption on education, healthcare, restaurant foods, concert going, etc. It can be easier done for restaurant foods and concert going, if you wish, because they can be substituted by eating at home or just watching Youtube. But it is much harder to find meaningful substitutes for education and healthcare. This is one of the reasons why these two are the hot-button issues today. If you ask me, I would say this is more of an income and income equality problem, and less of a cost problem (current inflation is near historically low). But this is just my view.
Since I just lumped education and healthcare together, let me get back to your question: “…then faculty compensation is too large to ignore.” My counter question is then “…then medical doctor’s compensation is too large to ignore.” Note that this is just a counter question for the sake of sharing our views. I believe that most medical doctors are compensated fairly.
Affordability issue is tricky. If you ask 100 economists, you may get 101 solutions.