Skip to content

Conversation

@erykoff
Copy link
Contributor

@erykoff erykoff commented Feb 25, 2022

This fixes #117.

Further investigation shows that with the newest version of cctools-port + sigtool for signing then whenever the outputIsMappableFile=true which triggers wholeBuffer = (uint8_t *)mmap(NULL, _fileSize, PROT_WRITE|PROT_READ, MAP_SHARED, fd, 0); then the output binary will not work on M1 macs. This can be triggered when either (a) the file already exists, or (b) the path is explicitly specified (relative or absolute). I'm not sure why the mmap option is necessary, and everything appears to run fine turning it off (and it is off in regular usage when you target a new file without a path specified!).

@tpoechtrager
Copy link
Owner

Is this patch still needed with https://github.com/tpoechtrager/cctools-port/tree/986-ld64-711?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Using compilers with -o absolute-path/to/target is broken for recent cctools

2 participants