Cygwin GNU make link broken, ld: unrecognized option '-z'
- Dominant language
- C
- Stars
- 4k
- Forks
- 1.7k
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 237
Description
$ tools/configure.sh sim:nsh
$ make V=1
...
echo "LD: nuttx.exe"
LD: nuttx.exe
ld -r -z noexecstack -L"/cygdrive/d/Spuda/Documents/projects/nuttx/master/nuttx/staging" -L board \
-o nuttx.rel sim_head.o sim_doirq.o --start-group -lsched -ldrivers -lboards -lc -lmm -larch -lapps -lfs -lbinfmt -lboard --end-group
ld: unrecognized option '-z'
ld: use the --help option for usage information
make[1]: *** [Makefile:362: nuttx.exe] Error 1
make[1]: Leaving directory '/cygdrive/d/Spuda/Documents/projects/nuttx/master/nuttx/arch/sim/src'
make: *** [tools/Unix.mk:527: nuttx.exe] Error 2
$ ld --version
GNU ld (GNU Binutils) 2.40
Per https://stackoverflow.com/questions/55418931/ld-exe-unrecognized-option-z
> The -z options are just not supported for Windows versions of ld. Check with ld --help. For Cygwin, it should not list -z options that are present when running the same command on a Linux system. I believe this is because options here are really only meaningful on Linux.
Contributor guide
Assessment
This issue has not been assessed yet.