rails console is not working

I got this error in my terminal when i type rails c:

I also use rvm pkg install readline but it did not help me

I see you use linux, most distributions provide a valid build and
headers for readline, please use quick fix instruction from top of
this page: https://rvm.beginrescueend.com/packages/readline/