I don't feel like filing another patch at this point, but since iOS is a cross-compilation target, the 3 lines for iOS should just be removed from Makefile.detect before it is merged.
On Mon, Dec 30, 2019 at 2:25 PM John Cowan <co...@ccil.org> wrote: > This patch supersedes all other patches and correctly distinguishes > between mingw, mingw-msys, and cygwin. It is also more efficient (only > runs uname twice) and doesn't have a zillion trailing endifs. > > > On Sat, Dec 28, 2019 at 11:24 AM Peter Bex <pe...@more-magic.net> wrote: > >> On Thu, Dec 19, 2019 at 11:19:16AM -0500, John Cowan wrote: >> > Here's the second patch I mentioned on #chicken. >> >> Hi John, >> >> I've tried these two patches, but found several problems with them: >> >> - The endif in the second patch is misplaced, so on UNIX, platform >> detection was skipped completely. Easily fixed by moving one endif >> to the very end. >> - The quotes in mingw-msys and mingw would be taken literally and this >> would result in an error about not being able to find a file named >> Makefile."mingw-msys". Also easily fixed. >> - The ComSpec environment variable is not defined in Mingw32-msys. >> There, it is called COMSPEC (in all caps). Therefore, it didn't >> work properly. I was able to fix this by changing the check from >> ifdef ComSpec to ifneq ($(COMSPEC)$(ComSpec),) so that both variables >> concatenated aren't empty. >> - Finally, I ran into a problem that I couldn't fix: SHELL is defined >> as sh.exe on Mingw32 (without msys). I don't know how to make the >> distinction between mingw and mingw-msys. >> >> I'm not super happy with the unreadable mess of endifs (like you see in >> my first bullet point, this results in real problems), but I think the >> change itself brings a convenience that I think is worthwhile enough to >> pursue it anyway. >> >> So, could you try to fix the final issue with mingw/mingw-msys detection? >> >> I've attached a new version of the patch where I fixed the issues I was >> able to fix. Obviously, this should *not* be pushed yet until the mingw >> issue is fixed. >> >> Cheers, >> Peter >> >