https://sourceware.org/bugzilla/show_bug.cgi?id=34359

            Bug ID: 34359
           Summary: The byte order mark doesn't skipped by windmc when
                    reading message text file (MC)
           Product: binutils
           Version: 2.46
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: binutils
          Assignee: unassigned at sourceware dot org
          Reporter: dan.kondratenko2013 at ya dot ru
  Target Milestone: ---

Created attachment 16822
  --> https://sourceware.org/bugzilla/attachment.cgi?id=16822&action=edit
The message text file which I try to compile with windmc

When I save the message file in UTF-8 with BOM and try 
compile the message text file with windmc message compiler, 
I receive the following error:

    C:/Users/danko/source/repos/PostInstallWizard $ cmake --build build
    [0/1] Re-running CMake...-- Configuring done (0.1s)
    -- Generating done (0.0s)
    -- Build files have been written to:
C:/Users/danko/source/repos/PostInstallWizard/build

    [1/18] Generating message resources
    FAILED: [code=1] PostInstallWizard/MSG00409.bin
PostInstallWizard/MSG00419.bin PostInstallWizard/Messages.rc
C:/Users/danko/source/repos/PostInstallWizard/PostInstallWizard/Messages.h
C:/Users/danko/source/repos/PostInstallWizard/build/PostInstallWizard/MSG00409.bin
C:/Users/danko/source/repos/PostInstallWizard/build/PostInstallWizard/MSG00419.bin
C:/Users/danko/source/repos/PostInstallWizard/build/PostInstallWizard/Messages.rc
    C:\WINDOWS\system32\cmd.exe /C "cd /D
C:\Users\danko\source\repos\PostInstallWizard\build\PostInstallWizard &&
D:\w64devkit\bin\windmc.exe -h
C:/Users/danko/source/repos/PostInstallWizard/PostInstallWizard -r
C:/Users/danko/source/repos/PostInstallWizard/build/PostInstallWizard -c
-C65001
C:/Users/danko/source/repos/PostInstallWizard/PostInstallWizard/Messages.mc"
    In Messages.mc at line 1: parser: syntax error.
    In Messages.mc at line 1: fatal: syntax error.
    ninja: build stopped: subcommand failed.

When I try to save Messages.mc in UTF-16LE without BOM, I have troubles with
editing it with most of text editors such as Microsoft Visual Studio one,
since some of them doesn't understand where is UTF-16LE without BOM.

Microsoft Visual Studio's MC (message compiler) does compile the Messages.mc
file saved in UTF-8 with BOM and recognizes Unicode properly.

I compile my application with w64devkit, my binutils version is 2.46.0:

    C:/Users/danko/source/repos/PostInstallWizard $ windmc --version
    GNU windmc (GNU Binutils) 2.46.0.20260210
    Copyright (C) 2026 Free Software Foundation, Inc.
    This program is free software; you may redistribute it under the terms of
    the GNU General Public License version 3 or (at your option) any later
version.
    This program has absolutely no warranty.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Reply via email to