binutils Newspaper
OCTOBER 6, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
ld

Use forward slash for directory separators on Windows

Linker now uses forward slashes for directory separators on Windows.

The linker has been unified to use forward slashes (’/’) as directory separators on Windows, aligning with the system’s capability to handle them. This change simplifies path handling by removing the need for specific backslash (”) processing, which was previously used in some contexts.

In Details

This commit modifies the ld linker to consistently use forward slashes ('/') for directory separators on Windows. Previously, the code conditionally used backslashes ('\') for Windows but forward slashes elsewhere. This change removes the conditional logic in ldfile.c and updates test cases, recognizing that Windows systems effectively support forward slashes for path navigation, thereby simplifying the implementation.

For Context
ld
The GNU linker, a standard component of Binutils. It takes object files and archives and combines them into an executable file, library, or another object file.
directory separator
A character used in file system paths to separate directory or folder names. Windows traditionally uses backslash ('\'), while Unix-like systems use forward slash ('/').
Filed Under: binutilsldwindowspaths