Configuration for Stripping Debugging Symbols in Visual Studio for mac

K_RamyaK_Ramya Member

I need to remove the debugging symbols from the IPA file.
I enabled the Strip native debugging symbols under Project Options -> iOS Build.

I used the nm command to check and still I am getting symbol information from the iPA file.
Also tried adding --dsym=false in the Additional mtouch Arguments but I am unable to archive the file and getting the following error

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/iOS/Xamarin.iOS.Common.targets(1005,3): error MSB3375: The file "bin/iPhone/Release/AppName.iOS.app.dSYM/Contents/Info.plist" does not exist.

I tried the same by creating a native project in XCode and stripped the debug symbols using the following configuration

Deployment Post processing -> YES
Strip Linked Product -> YES
Strip Debug Symbols During Copy -> YES
Generate Debug Symbols -> NO
Debug Information Format -> DWARF

After archiving the XCode project, I used the nm command and I am not getting any symbol information.

Is there any other configuration in visual studio for mac to perform this?

Answers

  • LandLuLandLu Member, Xamarin Team Xamurai

    Have you selected the Strip native debugging symbols in the iOS Build?
    It will try to remove the dSYM folder in your project's bin folder. But the --dsym=false has rejected to generate the dSYM folder, therefore, this error occurs.
    And I have checked this command, it will remove the dSYM folder.
    Moreover, I haven't used the nm command before. Can you make sure the sdym can be found in the ipa file? I've extracted the ipa file, but can't find the dSYM. dSYM only exists in the project's bin folder when we build the project without setting the argument or checking the Strip native debugging symbols.

  • K_RamyaK_Ramya Member

    I have selected Strip native debugging symbols as well as --dsym=false. I got the error /Library/Frameworks/Mono.framework/External/xbuild/Xamarin/iOS/Xamarin.iOS.Common.targets(1005,3): error MSB3375: The file "bin/iPhone/Release/AppName.iOS.app.dSYM/Contents/Info.plist" does not exist.

    Also tried setting the Strip native debugging symbols unchecked and having --dsym=false, I am getting symbol information from the iPA file.

  • LandLuLandLu Member, Xamarin Team Xamurai

    What's nm command? I haven't used it before so I don't know how to use it to scan the ipa files.
    I just changed the ipa file's suffix to zip, then we could extract this file to see what it contains. But I can't find the debugging symbols files there. AppName.iOS.app.dSYM is aligned in the same parent folder as the ipa but not included by ipa. When we set the --dsym=false, this file will be removed.
    Could you please share some steps to show the debugging symbol file in your ipa using nm command. Some screenshots to show the file's location will be better.

  • ArvindHindyarArvindHindyar USMember ✭✭

    I have the same issue.
    Steps to reproduce:

    1. Rename the .ipa file to .zip file.

    2. Extract the content of zip to get the binary file.

    3. On a terminal, navigate to the binary executable with the following command:

    nm YourFileName.iOS

    1. Notice that some of the methods are prefixed with the associated memory address which can facilitate reverse engineering.
Sign In or Register to comment.