Problem install PDFNetRuby in Mac M1

Product: PDFNetRuby MAc M1 PDF sdk library integration

Product Version: PDFNetWrappers Ruby

Please give a brief summary of your issue: make install failing
(Think of this as an email subject)

Please describe your issue and provide steps to reproduce it:
I have problem to install PDFNetRuby in macOS

Ruby 2.7.3
operating system: macOS M1 13.1 (22C65)

[krshnavi@krshnavis-MacBook-Air Build (master=)]$ make
[ 50%] Building CXX object PDFNetRuby/CMakeFiles/PDFNetRuby.dir/PDFNetRuby.cpp.o
clang: warning: no such sysroot directory: ‘/Applications/’ [-Wmissing-sysroot]

In file included from /Users/krshnavi/Downloads/wrappers_build/PDFNetWrappers/Build/PDFNetRuby/PDFNetRuby.cpp:446:

/Library/Developer/CommandLineTools/usr/bin/…/include/c++/v1/string.h:60:15: fatal error: ‘string.h’ file not found

#include_next <string.h>


1 error generated.

make[2]: *** [PDFNetRuby/CMakeFiles/PDFNetRuby.dir/PDFNetRuby.cpp.o] Error 1

make[1]: *** [PDFNetRuby/CMakeFiles/PDFNetRuby.dir/all] Error 2

make: *** [all] Error 2

Please provide a link to a minimal sample where the issue is reproducible:

Hi Pradeep,

Please make sure you are using the correct versions:
(As found here: GitHub - PDFTron/PDFNetWrappers: Code repository for building different language bindings for PDFNetC.)

  • SWIG 2.0.4 - 2.0.12 or SWIG 3.0.12 or SWIG 4.0.2 and above
  • CMake version 2.8+
  • macOS: XCode 5.0 and above

If you using the correct versions, please provide the following.

  1. Generated PDFNet Ruby files.
  2. swig.log
  3. swig.err.log
  4. The printed terminal output when you run “cmake -D BUILD_PDFNetRuby=ON …”
    (Run: “cmake -D BUILD_PDFNetRuby=ON … >> output.log”)
    Note: It would be best to clear all the binaries, so the log files generated above include the entire process.

Also please note, we have a prebuilt version for Ruby 2.6+ that you can use found here: