diff --git a/Makefile b/Makefile index a6549a8474c215..13671e4db17888 100644 --- a/Makefile +++ b/Makefile @@ -1096,7 +1096,7 @@ endif $(MACOSOUTDIR)/dist/npm/usr/local/lib/node_modules unlink $(MACOSOUTDIR)/dist/node/usr/local/bin/npm unlink $(MACOSOUTDIR)/dist/node/usr/local/bin/npx - $(NODE) tools/license2rtf.js < LICENSE > \ + $(NODE) tools/license2rtf.mjs < LICENSE > \ $(MACOSOUTDIR)/installer/productbuild/Resources/license.rtf cp doc/osx_installer_logo.png $(MACOSOUTDIR)/installer/productbuild/Resources pkgbuild --version $(FULLVERSION) \ diff --git a/tools/license2rtf.js b/tools/license2rtf.mjs similarity index 98% rename from tools/license2rtf.js rename to tools/license2rtf.mjs index 817da81d7a6ada..49b923415768a0 100644 --- a/tools/license2rtf.js +++ b/tools/license2rtf.mjs @@ -1,7 +1,6 @@ -'use strict'; - -const assert = require('assert'); -const Stream = require('stream'); +import assert from 'node:assert'; +import Stream from 'node:stream'; +import process from 'node:process'; /* diff --git a/vcbuild.bat b/vcbuild.bat index 96306e407e1a19..d5299c3739a82d 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -420,9 +420,9 @@ if "%use_x64_node_exe%"=="true" ( set exit_code=1 goto exit ) - %x64_node_exe% tools\license2rtf.js < LICENSE > %config%\license.rtf + %x64_node_exe% tools\license2rtf.mjs < LICENSE > %config%\license.rtf ) else ( - %node_exe% tools\license2rtf.js < LICENSE > %config%\license.rtf + %node_exe% tools\license2rtf.mjs < LICENSE > %config%\license.rtf ) if errorlevel 1 echo Failed to generate license.rtf&goto exit