Skip to content

Msys2 3.6.7 rework the exist patches to be more minimal#335

Closed
lygstate wants to merge 9 commits intomsys2:msys2-3.6.7from
lygstate:msys2-3.6.7-rework-donot-set-msys=noglob
Closed

Msys2 3.6.7 rework the exist patches to be more minimal#335
lygstate wants to merge 9 commits intomsys2:msys2-3.6.7from
lygstate:msys2-3.6.7-rework-donot-set-msys=noglob

Conversation

@lygstate
Copy link
Copy Markdown

@lygstate lygstate commented Apr 8, 2026

Redo the following commits into new patches, so the changes are grouped properly and can be upstreamed when possible:

  • "Add functionality for changing OS name via MSYSTEM environment variables."

  • "uname: allow setting the system name to CYGWIN"

  • "Rename dll from cygwin to msys"

  • "strace.cc: Don't set MSYS=noglob"

In response to #334 (comment)

Currently these four commits are changes things scattered.

  • "Add functionality for changing OS name via MSYSTEM environment variables."
    contains work changing OS name via MSYSTEM environment and Add support for MSYS environment variable instead of CYGWIN
  • "uname: allow setting the system name to CYGWIN"
    can be squash into "Add functionality for changing OS name via MSYSTEM environment variables."
  • "Rename dll from cygwin to msys"
    contains work "Add support for MSYS environment variable instead of CYGWIN", "strace.cc: Don't set MSYS=noglob"
    "Rename dll from cygwin to msys", "Convert to use msys'style named pipe".
  • "strace.cc: Don't set MSYS=noglob"
    The changes is scattered into "Rename dll from cygwin to msys", redo it so that it's not depends on "Rename dll from cygwin to msys"

So split them properly so the changes be more clear and minimal

lygstate and others added 5 commits April 7, 2026 16:35
…les.

allow setting the system name to CYGWIN

We are currently trying to move our cygwin build environment closer
to cygwin and some autotools/bash based build systems call "uname -s"
to figure out the OS and in many cases only handle the cygwin case, so
we have to patch them.

With this instead of patching we can set MSYSTEM=CYGWIN and change
uname output that way.

The next step would be to always output CYGWIN in an msys env by default,
but for now this allows us to get rid of all the patches without
affecting users.
@lygstate lygstate force-pushed the msys2-3.6.7-rework-donot-set-msys=noglob branch 4 times, most recently from 07a48fc to 4c3ab53 Compare April 8, 2026 10:56
Alexpux and others added 4 commits April 8, 2026 19:19
Changes of winsup/cygwin/environ.cc is split from "Add functionality for changing OS name via MSYSTEM environment variables."
Changes of winsup/cygwin/exceptions.cc, winsup/utils/mingw/cygcheck.cc is split from "Rename dll from cygwin to msys"

known_env_vars is sorted, update it
Commit message for this code was:

* strace.cc (create_child): Set CYGWIN=noglob when starting new process so that

  Cygwin will leave already-parsed the command line alonw."

I can see no reason for it and it badly breaks the ability to use
strace.exe to investigate calling a Cygwin program from a Windows
program, for example:
strace mingw32-make.exe
.. where mingw32-make.exe finds sh.exe and uses it as the shell.
The reason it badly breaks this use-case is because dcrt0.cc depends
on globbing to happen to parse commandlines from Windows programs;
irrespective of whether they contain any glob patterns or not.

See quoted () comment:
"This must have been run from a Windows shell, so preserve
 quotes for globify to play with later."
This is split from "Rename dll from cygwin to msys"
@lygstate lygstate force-pushed the msys2-3.6.7-rework-donot-set-msys=noglob branch from 4c3ab53 to 9482d18 Compare April 8, 2026 11:20
@lygstate lygstate closed this Apr 27, 2026
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.

2 participants