tesseract

Open-source OCR engine for extracting text from images

brewmacoslinux
Try with needOr install directly
Source

About

OCR (Optical Character Recognition) engine

Commands

tesseract

Examples

Extract text from an image file$ tesseract image.png output
Extract text from image with specific language$ tesseract image.png output -l fra
Extract text and output as PDF$ tesseract image.png output pdf