./configure : /bin/sh^M : bad interpreter [duplicate]

파일포맷이 문제였습니다.

CRLF 를 LF로 변경해주세요.

참조

https://stackoverflow.com/questions/2920416/configure-bin-shm-bad-interpreter