The Rambam (Hilchos Melochim 6:9) rules: “It’s permissible to cut down barren trees, even if there is no need for the trees.” The source for this halachah is the Gemara in Bava Kamma (91b). This halachah is seemingly very difficult as the Gemara in Kesubos (112b) says: “In the future all barren trees will produce fruit”. Surely we should say, מהרה יבנה בהמ״ ק – “may the Beis HaMikdosh be speedily rebuilt in our days” and the barren trees will grow fruit, and there should be an issur to cut them down?
The Rema (Hilchos Kilayim, Yoreh De’ah 295:6) rules, that it is permissible to graft a barren fruit tree of one type, with a barren fruit tree of another type, and there is no prohibition of kilayim [breeding]. The Pischei Teshuvah (s.k. 3) quotes the Shu”t Chasam Sofer (Yoreh De’ah 287) who quotes a Yerushalmi (according to one girsa) in Kilayim (1:7) which says: כל אילני סרק חדא מינא נינהו – “All barren trees are considered one species”
The Tiferes Ya’akov (on Mishnayos, at the end of Kesubos) asks: In the future all barren trees will produce fruit, so how can we call them all one species? He concludes that what we have to say is: לא משגחינן במה שיהיה לעתיד לבא – “We don’t reckon with what is going to be in the future”. However, this itself needs explaining.
The Shu”t Chadvas Ya’akov (119) answers the question we asked above based on the yesod of the Taz (Orach Chaim 588 s.k. 5, and Yoreh De’ah 117, s.k. 1) that on something the Torah explicitly allows, Chazal can’t come along and say it’s forbidden. The heter to cut down barren trees is learnt from the pasuk which only prohibits fruit producing trees. Therefore, even if in the future barren trees will produce fruit, it’s not enough of a reason for Chazal to forbid cutting them down, as the Torah says clearly that one is allowed to.
The Piskei Tosfos in Pesochim (132) writes: “If one cuts down even a barren tree, he won’t see any sign of blessing”. The Shu”t Kinyan Torah (1:39) in the name of the Pischa Zuta explains, that this is based on the Gemara at the end of Kesubos which says that in the future they will produce fruit. However, this would presumably only apply in Eretz Yisroel and not worldwide (see Shu”t Imrei Dovid 168, who says this clearly).
The Shu”t Afraktsa De’anya (1:35) also explains the Piskei Tosfos based on the Gemara at the end of Kesubos, however, he adds: If there is a great need one may be lenient. He cites proof from the Shu”t Shevus Ya’akov (1:159) who is lenient even with fruit producing trees, if they block out light.