5 For David thought, “My son Shlomo is an untried youth, and the House to be built for Hashem is to be made exceedingly great to win fame and glory throughout all the lands; let me then lay aside material for him.” So David laid aside much material before he died.
va-YO-mer da-VEED sh’-lo-MOH v’-NEE NA-ar va-RAKH v’-ha-BA-yit liv-NOT la-do-NAI l’-hag-DEEL l’-MA-lah l’-SHAYM ul-tif-E-ret l’-khol HA-a-ra-TZOT a-KHEE-nah NA LO va-YA-khen da-VEED la-ROV lif-NAY mo-TO
22:5 Let me then lay aside material for him
Even though he has not been instructed to do so, King David begins preparations for the construction of the Temple. He feels that if he would leave all of the preparation to Shlomo, who was still young at the time, the building project would be delayed significantly. In addition, it is likely that David feels an overpowering urge to do whatever he can for God’s glory. While he has been told that he will not be able to build the Beit Hamikdash, there is nothing stopping him from preparing for its construction. He simply cannot ignore his concern that God’s honor is impugned by the lack of a permanent home.