microsoft / microsoft/CLRInstrumentationEngine
Add support for macOS
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 102
- Forks
- 52
- Avg merge
- 13h 11m
- Merged PRs (30d)
- 6
Description
To support dynamic code coverage on macOS we need nuget with CLR IE macOS binaries.
I was trying to build CLR IE on macOS but it looks like it's not so easy. I was trying to build it with clang 11. I saw some issues with stringstream but after commenting out some stringstream usages I was able to reach linking. Linking is failing with such issues:
ld: warning: ignoring file ../unix/src/liblinux_pal.a, building for macOS-x86_64 but attempting to link with file built for macOS-x86_64
ld: warning: ignoring file ../unix/src/atl/libatl.a, building for macOS-x86_64 but attempting to link with file built for macOS-x86_64
ld: warning: ignoring file ../InstrumentationEngine.Api/libInstrumentationEngine.Api.a, building for macOS-x86_64 but attempting to link with file built for unknown-unsupported file format ( 0x21 0x3C 0x61 0x72 0x63 0x68 0x3E 0x0A 0x2F 0x20 0x20 0x20 0x20 0x20 0x20 0x20 )
ld: warning: ignoring file ../InstrumentationEngine.Lib/libInstrumentationEngine.Lib.a, building for macOS-x86_64 but attempting to link with file built for unknown-unsupported file format ( 0x21 0x3C 0x61 0x72 0x63 0x68 0x3E 0x0A 0x2F 0x20 0x20 0x20 0x20 0x20 0x20 0x20 )
There are also issues with objcopy in macOS. I've tried 2 versions llvm-objcopy from llvm 11, and gobjcopy from binutils package. In both cases during linking there were issues and redefined library was ignored.
All my changes you can find on branch: https://github.com/jakubch1/CLRInstrumentationEngine/tree/dev/jachocho/macos
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the dev/jachocho/macos branch linked in the issue and reproduce the clang/linker and objcopy failures described there. Trace how the existing CLR Instrumentation Engine libraries are built and packaged, then determine the macOS-compatible build path. Done means dynamic code coverage works on macOS and the required macOS binaries are included in NuGet.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, macos
- Domain
- build-system, operating-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100