Compilation error: windres: shotcut_resource.rc:6: error: syntax error

I just downloaded the latest Windows SDK( [Shotcut SDK (1.3 GB current version 21.12.24)] ) and followed the steps provided in Shotcut - How To Use the Windows SDK. When I build it I am getting a compilation error with these two errors compiling with Qt 5.15.2 MinGW 64-bit:

windres: shotcut_resource.rc:6: error: syntax error
:-1: error: [Makefile.Release:835: release/shotcut_resource_res.o] Error 1

This is the shotcut_resource.rc file:

#include <windows.h>

IDI_ICON1	ICON	DISCARDABLE	"C:\\Projects\\Shotcut\\src\\shotcut\\packaging\\windows\\shotcut-logo-64.ico"

VS_VERSION_INFO VERSIONINFO
	FILEVERSION an,22,0,0
	PRODUCTVERSION an,22,0,0
	FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
	FILEFLAGS VS_FF_DEBUG
#else
	FILEFLAGS 0x0L
#endif
	FILEOS VOS__WINDOWS32
	FILETYPE VFT_DLL
	FILESUBTYPE 0x0L
	BEGIN
		BLOCK "StringFileInfo"
		BEGIN
			BLOCK "040904b0"
			BEGIN
				VALUE "CompanyName", "Meltytech, LLC\0"
				VALUE "FileDescription", "Non-linear video editor\0"
				VALUE "FileVersion", "an.22.0.0\0"
				VALUE "LegalCopyright", "Copyright @ 2011-2021 Meltytech, LLC. All rights reserved.\0"
				VALUE "OriginalFilename", "shotcut.exe\0"
				VALUE "ProductName", "Shotcut\0"
				VALUE "ProductVersion", "an.22.0.0\0"
			END
		END
		BLOCK "VarFileInfo"
		BEGIN
			VALUE "Translation", 0x0409, 1200
		END
	END
/* End of Version info */

The line 6 refers to

	FILEVERSION an,22,0,0

Environment Info:

image

image

image

Take a look in src.pro, around line 377 where it computes a version using the date function in Windows CMD. In your locale it is including β€œan”, which is not a number and only numbers are accepted. You can simply hardcode the SHOTCUT_VERSION for now if you want to. I do not know if there is a locale-insensitive version of this date command it is using.

@shotcut thanks, that seemed to solve the problem in OP. However now I getting new compile errors.
Is it ok to make this topic a topic that would help me get shotcut to build on windows as new errors might come up?
New/current errors:

C:\Projects\Shotcut\src\shotcut\src\spatialmedia\container.cpp:-1: error: undefined reference to `__imp__wassert'
C:\Projects\Shotcut\src\shotcut\src\spatialmedia\container.cpp:-1: error: undefined reference to `__imp__wassert'

I guess you are using an incompatible build toolchain. I am using gcc from msys2 in automated build. I used to use that as well locally on my old Windows workstation. On my new Windows 11 system, I am using what is provided by Qt installer

I just switched to gcc from msys2 and it is working now. Thanks/

This topic was automatically closed after 90 days. New replies are no longer allowed.