fix readline build error bugsnet #66576
fix bugsnet #66594, thanks ondrej@php.net
fix bugsnet #66591 and github #60