[PATCH] ld: testsuite: Fix a few backslash-related issues on MinGW.

Jan Dubiec jdx@o2.pl
Sat Jul 18 23:50:05 GMT 2026


On 18.07.2026 19:53, Maciej W. Rozycki wrote:
[...]

>   I think a reasonable course of action would be accepting your change in
> the interim for the upcoming release with the commit description amended
> as requested, and then cleaning up the mess with slashes targetting 2.48.
> 
>    Maciej

It's not a big deal — we can wait until 2.48. It also looks like the 
current patch won't be necessary. Given that "slash" is a static 
variable (or rather a constant) and is only used when constructing full 
file names, I simply changed:

-static char *slash = "\\";
+static char *slash = "/";

The results look promising: so far, there have been no regressions. I'll 
post the new patch later.

That said, we should also review the other binutils tools from this 
perspective. Fortunately, a quick search through the sources didn't 
reveal any potentially problematic code (IMO). I also don't recall any 
other tool exhibiting a similar "/" vs. "\\" issue, although I could be 
wrong.

/J.D.



More information about the Binutils mailing list