Forum Xamarin.iOS

Why does Objective Sharpie output a huge ApiDefinition.cs?

Erar2rErar2r USMember ✭✭


I've recently started using Objective Sharpie to bind iOS libraries and I'm following the walkthrough on the developer site. I am able to bind the files successfully but the output ApiDefinition.cs file and Structs.cs file is huge, about 60 000 lines long. I am using Xcode 10.1, iOS 12.1 and Sharpie 3.4

Can anyone tell me how to fix this issue please?


  • LucasZhangLucasZhang Member, Xamarin Team Xamurai

    Could you provide the ApiDefinition.cs file and Structs.cs file?

  • starl1nstarl1n DOUniversity ✭✭

    If you put a variable -scope {PATH WHERE THE HEADER OF THE LIBRARY IS} in the command you won't have a file that big

  • Erar2rErar2r USMember ✭✭

    When I put the path of the headers, it continues to generate files huge. What worked for me was the following:

        sharpie bind \
          -o FolderBinding \
          -sdk iphoneos12.0 \
          -scope . \
          InfColorPicker/InfColorPicker.h \
          -c \
Sign In or Register to comment.