I have installed 64-bit cygwin in the folder C:\cygwin
Running
"C:\cygwin\bin\sh.exe" /bin/ls
results in
/bin/ls: /bin/ls: cannot execute binary file
Why?
Runnin sh and ls separately works.
C:\test>"C:\cygwin\bin\sh.exe"
sh-4.4$ /bin/ls
foreign_keys functions procedures props.sql schemas.sql tables
Using the file command, I can see that the binaries are 64-bit.
C:\test>"C:\cygwin\bin\sh.exe"
sh-4.4$ file /bin/sh
/bin/sh: PE32+ executable (console) x86-64 (stripped to external PDB), for MS Windows
sh-4.4$ file /bin/ls
/bin/ls: PE32+ executable (console) x86-64, for MS Windows
sh-4.4$