Skip to content

Commit

Permalink
try to fix mac build
Browse files Browse the repository at this point in the history
  • Loading branch information
pachadotdev committed Jan 6, 2025
1 parent 69750e2 commit e91d692
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
- name: Install system dependencies (MacOS)
if: matrix.config.os == 'macos-13' || matrix.config.os == 'macos-14'
run: |
brew install tesseract poppler
brew install tesseract poppler leptonica
- name: Setup R dependencies
uses: r-lib/actions/setup-r-dependencies@v2
Expand Down
6 changes: 3 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ URL: https://pacha.dev/cpp11tesseract/
BugReports: https://github.com/pachadotdev/cpp11tesseract/issues
SystemRequirements:
Tesseract OCR (
deb: tesseract-ocr libtesseract-dev libleptonica-dev,
rpm: tesseract-devel leptonica-devel,
brew: tesseract leptonica
deb: libtesseract-dev libleptonica-dev libpoppler-cpp-dev,
rpm: tesseract-devel leptonica-devel poppler-devel,
brew: tesseract leptonica poppler
)
Imports:
curl,
Expand Down
10 changes: 7 additions & 3 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@

# Library settings
PKG_CONFIG_NAME="tesseract"
PKG_DEB_NAME="tesseract-ocr libtesseract-dev libleptonica-dev"
PKG_RPM_NAME="tesseract-devel leptonica-devel"
PKG_BREW_NAME="tesseract leptonica"
PKG_DEB_NAME="libtesseract-dev libleptonica-dev libpoppler-cpp-dev"
PKG_RPM_NAME="tesseract-devel leptonica-devel poppler-devel"
PKG_BREW_NAME="tesseract leptonica poppler"
PKG_CFLAGS="-I/usr/include/leptonica"
PKG_LIBS="-ltesseract"

Expand Down Expand Up @@ -44,6 +44,10 @@ else
exit 1
fi

# Print debug information
echo "PKG_CFLAGS: $PKG_CFLAGS"
echo "PKG_LIBS: $PKG_LIBS"

# Check if the compiler is clang
if [ "$CC" = "clang" ] || [ "$CXX" = "clang++" ]; then
PKG_LIBS="$PKG_LIBS -stdlib=libc++"
Expand Down

0 comments on commit e91d692

Please sign in to comment.