diff options
Diffstat (limited to 'Src/external_dependencies/openmpt-trunk/installer')
10 files changed, 1214 insertions, 0 deletions
diff --git a/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch-per-arch.iss b/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch-per-arch.iss new file mode 100644 index 00000000..071e7bfe --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch-per-arch.iss @@ -0,0 +1,93 @@ + + + +[Registry] + + + +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}"; Flags: deletekey uninsdeletekey; Components: {#Component} + +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}"; ValueType: string; ValueName: ""; ValueData: "{#OpenMPTarchFriendly} Module"; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}"; ValueType: string; ValueName: "PerceivedType"; ValueData: "audio"; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\OpenMPT File Icon.ico,0"; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}\shell\Open"; ValueType: string; ValueName: "MultiSelectModel"; ValueData: "Player"; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Classes\{#OpenMPTFile}\shell\Open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\bin\{#OpenMPTarchPath}\OpenMPT.exe"" /shared ""%1"""; Components: {#Component} + + + +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}"; Flags: deletekey uninsdeletekey; Components: {#Component} + +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities"; ValueType: string; ValueName: "ApplicationDescription"; ValueData: "{#OpenMPTarchFriendly} is an application for editing and playing tracked music in various formats."; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities"; ValueType: string; ValueName: "ApplicationName"; ValueData: "{#OpenMPTarchFriendly}"; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities"; ValueType: string; ValueName: "ApplicationIcon"; ValueData: "{app}\OpenMPT App Icon.ico,0"; Components: {#Component} + +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/it"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/xm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/s3m"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-s3m"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-zipped-mod"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-zipped-it"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-tracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-screamtracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-protracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-startracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-fasttracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-oktalyzer-tracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\MIMEAssociations"; ValueType: string; ValueName: "audio/x-taketracker-module"; ValueData: {#OpenMPTFile}; Components: {#Component} + +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mod"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".s3m"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".xm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".it"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mptm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mdr"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mdz"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".s3z"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".xmz"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".itz"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mptmz"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".669"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".amf"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".ams"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".c67"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".dbm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".digi"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".dmf"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".dsm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".dsym"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".dtm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".far"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".fmt"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".gdm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".imf"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".ice"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".itp"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".j2b"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".m15"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mdl"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".med"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mms"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mo3"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mt2"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mtm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".mus"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".okt"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".oxm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".plm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".psm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".pt36"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".ptm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".sfx"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".sfx2"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".st26"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".stm"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".stp"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".stx"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".symmod"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".ult"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".umx"; ValueData: {#OpenMPTFile}; Components: {#Component} +Root: HKA; Subkey: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities\FileAssociations"; ValueType: string; ValueName: ".wow"; ValueData: {#OpenMPTFile}; Components: {#Component} + +Root: HKA; Subkey: "SOFTWARE\RegisteredApplications"; ValueType: string; ValueName: {#OpenMPTarchFriendly}; ValueData: "SOFTWARE\Clients\Media\{#OpenMPTarch}\Capabilities"; Flags: uninsdeletevalue; Components: {#Component} + + diff --git a/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch.iss b/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch.iss new file mode 100644 index 00000000..cb9a9a0b --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/filetypes-multi-arch.iss @@ -0,0 +1,125 @@ +; OpenMPT Install script - File associations +; https://openmpt.org/ + + + +[Registry] + + + +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe"; Flags: deletekey uninsdeletekey + +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mod"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mod"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".s3m"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".xm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".it"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mptm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mdr"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mdz"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".s3z"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".xmz"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".itz"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mptmz"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".669"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".amf"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".ams"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".c67"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".dbm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".digi"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".dmf"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".dsm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".dsym"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".dtm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".far"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".fmt"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".gdm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".imf"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".ice"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".itp"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".j2b"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".m15"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mdl"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".med"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mms"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mo3"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mt2"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mtm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".mus"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".okt"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".oxm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".plm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".psm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".pt36"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".ptm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".sfx"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".sfx2"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".st26"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".stm"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".stp"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".stx"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".symmod"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".ult"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".umx"; ValueData: "" +Root: HKA; Subkey: "SOFTWARE\Classes\Applications\OpenMPT.exe\SupportedTypes"; ValueType: string; ValueName: ".wow"; ValueData: "" + +Root: HKA; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\OpenMPT.exe"; ValueType: string; ValueName: ""; ValueData: "{app}\bin\{code:CodeGetDefaultArch|}\OpenMPT.exe"; Flags: deletekey uninsdeletekey + + + +#define Component "archx86 or archamd64 or archarm or archarm64" +#define OpenMPTFile "OpenMPTFile" +#define OpenMPTarch "OpenMPT" +#define OpenMPTarchPath "{code:CodeGetDefaultArch|}" +#define OpenMPTarchFriendly "OpenMPT" +#include "filetypes-multi-arch-per-arch.iss" +#undef OpenMPTarchFriendly +#undef OpenMPTarchPath +#undef OpenMPTarch +#undef OpenMPTFile + +#define Component "archx86" +#define OpenMPTFile "OpenMPTFilex86" +#define OpenMPTarch "OpenMPTx86" +#define OpenMPTarchPath "x86" +#define OpenMPTarchFriendly "OpenMPT (x86)" +#include "filetypes-multi-arch-per-arch.iss" +#undef OpenMPTarchFriendly +#undef OpenMPTarchPath +#undef OpenMPTarch +#undef OpenMPTFile + +#define Component "archamd64" +#define OpenMPTFile "OpenMPTFileamd64" +#define OpenMPTarch "OpenMPTamd64" +#define OpenMPTarchPath "amd64" +#define OpenMPTarchFriendly "OpenMPT (amd64)" +#include "filetypes-multi-arch-per-arch.iss" +#undef OpenMPTarchFriendly +#undef OpenMPTarchPath +#undef OpenMPTarch +#undef OpenMPTFile + +#define Component "archarm" +#define OpenMPTFile "OpenMPTFilearm" +#define OpenMPTarch "OpenMPTarm" +#define OpenMPTarchPath "arm" +#define OpenMPTarchFriendly "OpenMPT (arm)" +#include "filetypes-multi-arch-per-arch.iss" +#undef OpenMPTarchFriendly +#undef OpenMPTarchPath +#undef OpenMPTarch +#undef OpenMPTFile + +#define Component "archarm64" +#define OpenMPTFile "OpenMPTFilearm64" +#define OpenMPTarch "OpenMPTarm64" +#define OpenMPTarchPath "arm64" +#define OpenMPTarchFriendly "OpenMPT (arm64)" +#include "filetypes-multi-arch-per-arch.iss" +#undef OpenMPTarchFriendly +#undef OpenMPTarchPath +#undef OpenMPTarch +#undef OpenMPTFile + + diff --git a/Src/external_dependencies/openmpt-trunk/installer/generate_update_json.py b/Src/external_dependencies/openmpt-trunk/installer/generate_update_json.py new file mode 100644 index 00000000..12491437 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/generate_update_json.py @@ -0,0 +1,275 @@ +#!/usr/bin/env python3 + +import datetime +import hashlib +import json +import os + +from subprocess import Popen + +OPENMPT_VERSION_MAJORMAJOR = os.environ['OPENMPT_VERSION_MAJORMAJOR'] +OPENMPT_VERSION_MAJOR = os.environ['OPENMPT_VERSION_MAJOR'] +OPENMPT_VERSION_MINOR = os.environ['OPENMPT_VERSION_MINOR'] +OPENMPT_VERSION_MINORMINOR = os.environ['OPENMPT_VERSION_MINORMINOR'] +SVNVERSION = os.environ['SVNVERSION'] +IS_RELEASE = True if OPENMPT_VERSION_MINORMINOR == "00" else False + +if IS_RELEASE: + download_base_url = "https://download.openmpt.org/archive/openmpt/" + announcement_url = "https://openmpt.org/openmpt-" + OPENMPT_VERSION_MAJORMAJOR + "-" + OPENMPT_VERSION_MAJOR + "-" + OPENMPT_VERSION_MINOR + "-" + OPENMPT_VERSION_MINORMINOR + "-released" + changelog_url = "https://openmpt.org/release_notes/History.txt" +else: + download_base_url = "https://builds.openmpt.org/builds/auto/openmpt/pkg.win/" + announcement_url = "https://builds.openmpt.org/builds/auto/openmpt/pkg.win/" + changelog_url = "https://source.openmpt.org/browse/openmpt/?op=revision&rev=" + SVNVERSION + +os.chdir(os.path.dirname(os.path.abspath(__file__))) +os.chdir("..") + +plainversion = OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR +version = OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR if IS_RELEASE else OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-" + SVNVERSION + +def hash_file_sha512(filename): + sha512 = hashlib.sha512() + with open(filename, "rb") as f: + sha512.update(f.read()) + return sha512.hexdigest() +def hash_file_sha3_512(filename): + sha3_512 = hashlib.sha3_512() + with open(filename, "rb") as f: + sha3_512.update(f.read()) + return sha3_512.hexdigest() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-Setup.exe", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-Setup.exe"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-Setup.exe"), + }, + "filename": "OpenMPT-" + version + "-Setup.exe", + "autoupdate_installer": { + "arguments": [ "/SP-", "/SILENT", "/NOCANCEL", "/AUTOUPDATE=yes" ] + }, + "autoupdate_archive": None +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-Setup.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-x86.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-x86.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-x86.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-x86.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86-legacy.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-x86-legacy.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-x86-legacy.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-x86-legacy.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-x86-legacy.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-amd64.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-amd64.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-amd64.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-amd64.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64-legacy.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-amd64-legacy.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-amd64-legacy.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-amd64-legacy.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-amd64-legacy.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-arm.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-arm.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-arm.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-arm.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +update = { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm64.zip", + "checksums": { + "SHA-512": hash_file_sha512("installer/OpenMPT-" + plainversion + "-portable-arm64.zip"), + "SHA3-512": hash_file_sha3_512("installer/OpenMPT-" + plainversion + "-portable-arm64.zip"), + }, + "filename": "OpenMPT-" + version + "-portable-arm64.zip", + "autoupdate_installer": None, + "autoupdate_archive": { + "subfolder": "", + "restartbinary": "OpenMPT.exe" + } +} +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-arm64.update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + + + +update = { + "OpenMPT " + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR: { + "version": version, + "date": datetime.datetime.utcnow().isoformat(), + "announcement_url": announcement_url, + "changelog_url": changelog_url, + "downloads": { + "installer": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-Setup.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-Setup.exe", + "type": "installer", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":6, "version_minor":1, "servicepack_major":1, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": { "x86":True }, + "supported_architectures": { "x86":True,"amd64":True,"arm":True,"arm64":True }, + "required_processor_features": { "x86":{"sse2":True}, "amd64":{"sse2":True} } + }, + "portable-x86": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":10, "version_minor":0, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "x86":True }, + "required_processor_features": { "x86":{"sse2":True} } + }, + "portable-x86-legacy": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86-legacy.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-x86-legacy.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":6, "version_minor":1, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "x86":True }, + "required_processor_features": { "x86":{"sse2":True} } + }, + "portable-amd64": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":10, "version_minor":0, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "amd64":True }, + "required_processor_features": { "amd64":{"sse2":True} } + }, + "portable-amd64-legacy": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64-legacy.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-amd64-legacy.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":6, "version_minor":1, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "amd64":True }, + "required_processor_features": { "amd64":{"sse2":True} } + }, + "portable-arm": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":10, "version_minor":0, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "arm":True }, + "required_processor_features": { "arm":{} } + }, + "portable-arm64": { + "url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm64.update.json", + "download_url": download_base_url + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "/OpenMPT-" + version + "-portable-arm64.zip", + "type": "archive", + "can_autoupdate": True, + "autoupdate_minversion": "1.30.00.08", + "os": "windows", + "required_windows_version": { "version_major":10, "version_minor":0, "servicepack_major":0, "servicepack_minor":0, "build":0, "wine_major":1, "wine_minor":8, "wine_update":0 }, + "required_architectures": {}, + "supported_architectures": { "arm64":True }, + "required_processor_features": { "arm64":{} } + } + } + } +} + +with open("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-update.json", "wb") as f: + f.write((json.dumps(update, ensure_ascii=False, indent=1)).encode('utf-8')) + f.close() + +def sign_file(filename): + p = Popen(["bin/release/vs2019-win7-static/amd64/updatesigntool.exe", "sign", "jws", "auto", filename, filename + ".jws.json"]) + p.communicate() + +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-Setup.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-x86.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-x86-legacy.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-amd64.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-amd64-legacy.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-arm.update.json") +sign_file("installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-portable-arm64.update.json") + +pdumpkey = Popen(["bin/release/vs2019-win7-static/amd64/updatesigntool.exe", "dumpkey", "auto", "installer/" + "OpenMPT-" + OPENMPT_VERSION_MAJORMAJOR + "." + OPENMPT_VERSION_MAJOR + "." + OPENMPT_VERSION_MINOR + "." + OPENMPT_VERSION_MINORMINOR + "-update-publickey.jwk.json"]) +pdumpkey.communicate() diff --git a/Src/external_dependencies/openmpt-trunk/installer/install-big.bmp b/Src/external_dependencies/openmpt-trunk/installer/install-big.bmp Binary files differnew file mode 100644 index 00000000..d0d739f1 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/install-big.bmp diff --git a/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch-signed.iss b/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch-signed.iss new file mode 100644 index 00000000..3bf629c2 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch-signed.iss @@ -0,0 +1,5 @@ +[Setup] +SignTool=signtool +SignedUninstaller=yes + +#include "install-multi-arch.iss"
\ No newline at end of file diff --git a/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch.iss b/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch.iss new file mode 100644 index 00000000..1870f263 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/install-multi-arch.iss @@ -0,0 +1,357 @@ +; OpenMPT Install script +; https://openmpt.org/ + + + +#define BuildFolder "release\vs2019-win10-static" +#define BuildFolderLegacyx86 "release\vs2019-win7-static" +#define BuildFolderLegacyamd64 "release\vs2019-win7-static" + +#define DefaultArchName "x86" + +#define GetAppVersion GetFileProductVersion("..\bin\" + BuildFolder + "\" + DefaultArchName + "\OpenMPT.exe") +#define GetAppVersionMedium Copy(GetAppVersion, 1, 7) +#define GetAppVersionShort Copy(GetAppVersion, 1, 4) + + + +[Setup] + +AlwaysShowComponentsList=no +AppId={{40c97d3e-7763-4b88-8c6a-0901befee4af} +AppVerName=OpenMPT {#GetAppVersion} +AppVersion={#GetAppVersion} +AppName=OpenMPT +AppPublisher=OpenMPT +AppPublisherURL=https://openmpt.org/ +AppSupportURL=https://forum.openmpt.org/ +AppUpdatesURL=https://openmpt.org/ +ArchitecturesInstallIn64BitMode=x64 arm64 ia64 +ChangesAssociations=yes +Compression=lzma2/ultra64 +;DefaultDirName={autopf}\OpenMPT +DefaultDirName={code:CodeGetDefaultDirName|} +DefaultGroupName=OpenMPT +DirExistsWarning=auto +DisableDirPage=auto +AlwaysShowDirOnReadyPage=yes +DisableProgramGroupPage=yes +DisableReadyMemo=no +DisableWelcomePage=no +MinVersion=6.1sp1 +OutputDir=.\ +OutputBaseFilename=OpenMPT-{#GetAppVersion}-Setup +PrivilegesRequired=admin +PrivilegesRequiredOverridesAllowed=commandline dialog +SetupIconFile=..\mptrack\res\MPTRACK.ICO +SolidCompression=yes +TimeStampsInUTC=yes +UninstallDisplayIcon={app}\OpenMPT App Icon.ico +VersionInfoCopyright=Copyright © 2004-2022 OpenMPT Project Developers and Contributors, Copyright © 1997-2003 Olivier Lapicque +VersionInfoProductTextVersion={#GetAppVersion} +VersionInfoProductVersion={#GetAppVersion} +VersionInfoTextVersion={#GetAppVersion} +VersionInfoVersion={#GetAppVersion} +WizardImageFile=install-big.bmp +WizardSmallImageFile=install-small.bmp +WizardStyle=modern + + + +[Types] + +Name: "default"; Description: "Default installation"; Flags: iscustom + + + +[Components] + +Name: "archx86"; Description: "OpenMPT x86"; Types: default; Flags: fixed disablenouninstallwarning +Name: "archamd64"; Description: "OpenMPT amd64"; Types: default; Flags: fixed disablenouninstallwarning +Name: "archarm"; Description: "OpenMPT arm"; Types: default; Flags: fixed disablenouninstallwarning +Name: "archarm64"; Description: "OpenMPT arm64"; Types: default; Flags: fixed disablenouninstallwarning + + + +[Languages] + +Name: en; MessagesFile: compiler:Default.isl + + + +[Files] + +; note: packageTemplate\ contains files specific for the "install package". +; for files that are common with the "zip package", use ..\packageTemplate\ + +Source: ..\bin\{#BuildFolder}\x86\OpenMPT.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\x86\PluginBridge-x86.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\x86\PluginBridgeLegacy-x86.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\x86\openmpt-lame.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\x86\openmpt-mpg123.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\x86\openmpt-soundtouch.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; MinVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\OpenMPT.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\PluginBridge-x86.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\PluginBridgeLegacy-x86.exe; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\openmpt-lame.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\openmpt-mpg123.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyx86}\x86\openmpt-soundtouch.dll; DestDir: {app}\bin\x86; Flags: ignoreversion; Components: archx86; OnlyBelowVersion: 10.0 + +Source: ..\bin\{#BuildFolder}\amd64\OpenMPT.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\amd64\PluginBridge-amd64.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\amd64\PluginBridgeLegacy-amd64.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\amd64\openmpt-lame.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\amd64\openmpt-mpg123.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolder}\amd64\openmpt-soundtouch.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; MinVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\OpenMPT.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\PluginBridge-amd64.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\PluginBridgeLegacy-amd64.exe; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\openmpt-lame.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\openmpt-mpg123.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 +Source: ..\bin\{#BuildFolderLegacyamd64}\amd64\openmpt-soundtouch.dll; DestDir: {app}\bin\amd64; Flags: ignoreversion; Components: archamd64; OnlyBelowVersion: 10.0 + +Source: ..\bin\{#BuildFolder}\arm\OpenMPT.exe; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm +Source: ..\bin\{#BuildFolder}\arm\PluginBridge-arm.exe; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm +Source: ..\bin\{#BuildFolder}\arm\PluginBridgeLegacy-arm.exe; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm +Source: ..\bin\{#BuildFolder}\arm\openmpt-lame.dll; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm +Source: ..\bin\{#BuildFolder}\arm\openmpt-mpg123.dll; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm +Source: ..\bin\{#BuildFolder}\arm\openmpt-soundtouch.dll; DestDir: {app}\bin\arm; Flags: ignoreversion; Components: archarm + +Source: ..\bin\{#BuildFolder}\arm64\OpenMPT.exe; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 +Source: ..\bin\{#BuildFolder}\arm64\PluginBridge-arm64.exe; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 +Source: ..\bin\{#BuildFolder}\arm64\PluginBridgeLegacy-arm64.exe; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 +Source: ..\bin\{#BuildFolder}\arm64\openmpt-lame.dll; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 +Source: ..\bin\{#BuildFolder}\arm64\openmpt-mpg123.dll; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 +Source: ..\bin\{#BuildFolder}\arm64\openmpt-soundtouch.dll; DestDir: {app}\bin\arm64; Flags: ignoreversion; Components: archarm64 + +Source: "..\mptrack\res\MPTRACK.ICO"; DestName: "OpenMPT App Icon.ico"; DestDir: "{app}"; Flags: ignoreversion +Source: "..\packageTemplate\OpenMPT File Icon.ico"; DestName: "OpenMPT File Icon.ico"; DestDir: "{app}"; Flags: ignoreversion + +Source: ..\bin\{#BuildFolder}\{#DefaultArchName}\openmpt-wine-support.zip; DestDir: {app}; Flags: ignoreversion + +; todo: use proper folder +Source: ..\packageTemplate\ExampleSongs\*.*; DestDir: {app}\ExampleSongs\; Flags: ignoreversion recursesubdirs + +Source: packageTemplate\readme.txt; DestDir: {app}; Flags: ignoreversion +Source: ..\packageTemplate\History.txt; DestDir: {app}; Flags: ignoreversion +Source: ..\packageTemplate\OpenMPT Manual.chm; DestDir: {app}; Flags: ignoreversion + +Source: ..\packageTemplate\ReleaseNotesImages\*.*; DestDir: {app}\ReleaseNotesImages\; Flags: ignoreversion +Source: ..\packageTemplate\Release Notes.html; DestDir: {app}; Flags: ignoreversion + +Source: ..\packageTemplate\OpenMPT Support and Community Forum.url; DestDir: {app}; Flags: ignoreversion +Source: ..\packageTemplate\OpenMPT Issue Tracker.url; DestDir: {app}; Flags: ignoreversion + +Source: ..\packageTemplate\License.txt; DestDir: {app}; Flags: ignoreversion +Source: ..\packageTemplate\Licenses\*.*; DestDir: {app}\Licenses; Flags: ignoreversion + +Source: ..\packageTemplate\ExtraKeymaps\*.*; DestDir: {app}\ExtraKeymaps; Flags: ignoreversion + + + +[Icons] + +Name: {autodesktop}\OpenMPT; Filename: {app}\bin\x86\OpenMPT.exe; Check: CheckDefaultArch('x86') +Name: {autodesktop}\OpenMPT; Filename: {app}\bin\amd64\OpenMPT.exe; Check: CheckDefaultArch('amd64') +Name: {autodesktop}\OpenMPT; Filename: {app}\bin\arm\OpenMPT.exe; Check: CheckDefaultArch('arm') +Name: {autodesktop}\OpenMPT; Filename: {app}\bin\arm64\OpenMPT.exe; Check: CheckDefaultArch('arm64') + +Name: {group}\OpenMPT; Filename: {app}\bin\x86\OpenMPT.exe; Check: CheckDefaultArch('x86') +Name: {group}\OpenMPT; Filename: {app}\bin\amd64\OpenMPT.exe; Check: CheckDefaultArch('amd64') +Name: {group}\OpenMPT; Filename: {app}\bin\arm\OpenMPT.exe; Check: CheckDefaultArch('arm') +Name: {group}\OpenMPT; Filename: {app}\bin\arm64\OpenMPT.exe; Check: CheckDefaultArch('arm64') + +Name: {group}\OpenMPT (x86); Filename: {app}\bin\x86\OpenMPT.exe; Components: archx86 +Name: {group}\OpenMPT (amd64); Filename: {app}\bin\amd64\OpenMPT.exe; Components: archamd64 +Name: {group}\OpenMPT (arm); Filename: {app}\bin\arm\OpenMPT.exe; Components: archarm +Name: {group}\OpenMPT (arm64); Filename: {app}\bin\arm64\OpenMPT.exe; Components: archarm64 + +Name: {group}\Manual; Filename: {app}\OpenMPT Manual.chm +Name: {group}\Support and Community Forum; Filename: {app}\OpenMPT Support and Community Forum.url + + + +[Registry] + +#include "filetypes-multi-arch.iss" + + + +[Run] + +Filename: "{app}\Release Notes.html"; Description: "View Release Notes"; Flags: runasoriginaluser shellexec nowait postinstall skipifsilent + +Filename: {app}\bin\x86\OpenMPT.exe; Parameters: """{code:RandomExampleFile}"""; Description: {cm:LaunchProgram,OpenMPT}; Flags: runasoriginaluser nowait postinstall skipifsilent; Check: CheckDefaultArch('x86') +Filename: {app}\bin\amd64\OpenMPT.exe; Parameters: """{code:RandomExampleFile}"""; Description: {cm:LaunchProgram,OpenMPT}; Flags: runasoriginaluser nowait postinstall skipifsilent; Check: CheckDefaultArch('amd64') +Filename: {app}\bin\arm\OpenMPT.exe; Parameters: """{code:RandomExampleFile}"""; Description: {cm:LaunchProgram,OpenMPT}; Flags: runasoriginaluser nowait postinstall skipifsilent; Check: CheckDefaultArch('arm') +Filename: {app}\bin\arm64\OpenMPT.exe; Parameters: """{code:RandomExampleFile}"""; Description: {cm:LaunchProgram,OpenMPT}; Flags: runasoriginaluser nowait postinstall skipifsilent; Check: CheckDefaultArch('arm64') + + + +[InstallDelete] + +; as recommended by Inno Setup manual on [Components] + +Type: files; Name: {app}\bin\x86\OpenMPT.exe +Type: files; Name: {app}\bin\x86\PluginBridge-x86.exe +Type: files; Name: {app}\bin\x86\PluginBridgeLegacy-x86.exe +Type: files; Name: {app}\bin\x86\openmpt-lame.dll +Type: files; Name: {app}\bin\x86\openmpt-mpg123.dll +Type: files; Name: {app}\bin\x86\openmpt-soundtouch.dll + +Type: files; Name: {app}\bin\amd64\OpenMPT.exe +Type: files; Name: {app}\bin\amd64\PluginBridge-amd64.exe +Type: files; Name: {app}\bin\amd64\PluginBridgeLegacy-amd64.exe +Type: files; Name: {app}\bin\amd64\openmpt-lame.dll +Type: files; Name: {app}\bin\amd64\openmpt-mpg123.dll +Type: files; Name: {app}\bin\amd64\openmpt-soundtouch.dll + +Type: files; Name: {app}\bin\arm\OpenMPT.exe +Type: files; Name: {app}\bin\arm\PluginBridge-arm.exe +Type: files; Name: {app}\bin\arm\PluginBridgeLegacy-arm.exe +Type: files; Name: {app}\bin\arm\openmpt-lame.dll +Type: files; Name: {app}\bin\arm\openmpt-mpg123.dll +Type: files; Name: {app}\bin\arm\openmpt-soundtouch.dll + +Type: files; Name: {app}\bin\arm64\OpenMPT.exe +Type: files; Name: {app}\bin\arm64\PluginBridge-arm64.exe +Type: files; Name: {app}\bin\arm64\PluginBridgeLegacy-arm64.exe +Type: files; Name: {app}\bin\arm64\openmpt-lame.dll +Type: files; Name: {app}\bin\arm64\openmpt-mpg123.dll +Type: files; Name: {app}\bin\arm64\openmpt-soundtouch.dll + + + +#include "uninstall-single-arch.iss" + + + +[Code] + +procedure InitializeWizard(); +begin + WizardSelectComponents('archx86,!archamd64,!archarm,!archarm64'); + case ProcessorArchitecture() of + paUnknown: + begin + WizardSelectComponents('archx86,!archamd64,!archarm,!archarm64'); + end; + paX86: + begin + WizardSelectComponents('archx86,!archamd64,!archarm,!archarm64'); + end; + paX64: + begin + WizardSelectComponents('archx86,archamd64,!archarm,!archarm64'); + end; + paIA64: + begin + WizardSelectComponents('archx86,!archamd64,!archarm,!archarm64'); + end; + paARM64: + begin + WizardSelectComponents('archx86,archamd64,archarm,archarm64'); + end; + end; +end; + +function GetDefaultArch(): String; +begin + Result := 'x86'; + case ProcessorArchitecture() of + paUnknown: + begin + Result := 'x86'; + end; + paX86: + begin + Result := 'x86'; + end; + paX64: + begin + Result := 'amd64'; + end; + paIA64: + begin + Result := 'x86'; + end; + paARM64: + begin + Result := 'arm64'; + end; + end; +end; + +function CodeGetDefaultArch(Param: String): String; +begin + Result := GetDefaultArch(); +end; + +function CheckDefaultArch(Arch: String): Boolean; +begin + Result := Arch = GetDefaultArch(); +end; + +function ShouldSkipPage(PageID: Integer): Boolean; +begin + Result := False; + case PageID of + wpSelectDir: + begin + Result := IsAdmin() and HasPreviousSingleArchInstallPath(); + end; + end; + case PageID of + wpSelectComponents: + begin + Result := True; + end; + end; +end; + +procedure CurStepChanged(CurStep: TSetupStep); +begin + case CurStep of + ssInstall: + begin + if not UninstallSingleArch() then + begin + RaiseException('Uninstallation of previous OpenMPT installation failed. Please uninstall manually.'); + end; + end; + end; +end; + +// Picks a random example song file to play +Function RandomExampleFile(Dummy: String): String; +var + Files: TstringList; + FindRec: TFindRec; +begin + Result := ''; + if FindFirst(ExpandConstant('{app}\ExampleSongs\*'), FindRec) then + try + Files := TstringList.Create; + repeat + if FindRec.Attributes and FILE_ATTRIBUTE_DIRECTORY = 0 then + Files.Add(FindRec.Name); + until not FindNext(FindRec); + Result := ExpandConstant('{app}\ExampleSongs\') + Files[Random(Files.Count)]; + finally + FindClose(FindRec); + end; +end; + +function CodeGetDefaultDirName(Param: String): String; +begin + if IsAdmin() and HasPreviousSingleArchInstallPath() then + begin + Result := GetPreviousSingleArchInstallPath(); + end + else + begin + Result := ExpandConstant('{autopf}\OpenMPT'); + end; +end; + + diff --git a/Src/external_dependencies/openmpt-trunk/installer/install-small.bmp b/Src/external_dependencies/openmpt-trunk/installer/install-small.bmp Binary files differnew file mode 100644 index 00000000..2b7b59dc --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/install-small.bmp diff --git a/Src/external_dependencies/openmpt-trunk/installer/packageTemplate/readme.txt b/Src/external_dependencies/openmpt-trunk/installer/packageTemplate/readme.txt new file mode 100644 index 00000000..1c0811b3 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/packageTemplate/readme.txt @@ -0,0 +1,38 @@ +
+OpenMPT / Open ModPlug Tracker
+==============================
+
+
+Uninstallation
+--------------
+
+An uninstaller is provided. It will not delete your personal settings or files
+you created.
+
+
+What's New in this Version?
+---------------------------
+
+Major changes in the current version are listed in [Release Notes.html] and a
+detailed list of changes for all versions can be found in [History.txt].
+
+
+More Information
+----------------
+
+The user manual can be found in [OpenMPT Manual.chm]. Further questions can be
+asked in the [OpenMPT Support and Community Forum](https://forum.openmpt.org/).
+Please report any bugs or request new features in the
+[OpenMPT Issue Tracker](https://bugs.openmpt.org/).
+
+
+License
+-------
+
+OpenMPT is released under the 3-clause BSD license. See [License.txt] for
+details. OpenMPT uses various other open source projects. Their respective
+license information can be found in the [Licenses] folder.
+
+ASIO is a trademark and software of Steinberg Media Technologies GmbH.
+
+VST is a trademark of Steinberg Media Technologies GmbH.
diff --git a/Src/external_dependencies/openmpt-trunk/installer/uninstall-single-arch.iss b/Src/external_dependencies/openmpt-trunk/installer/uninstall-single-arch.iss new file mode 100644 index 00000000..86208da9 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/uninstall-single-arch.iss @@ -0,0 +1,115 @@ + + + +[Code] + +function GetAppPath(AppId: String; IsWow64: Boolean): String; +var + AppPath: String; +begin + Result := ''; + AppPath := ''; + if IsWow64 then + begin + RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\' + AppId + '_is1', 'Inno Setup: App Path', AppPath) + end + else + begin + RegQueryStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + AppId + '_is1', 'Inno Setup: App Path', AppPath) + end; + Result := AppPath; +end; + +function GetUninstallCommand(AppId: String; IsWow64: Boolean): String; +var + UninstallCommand: String; +begin + Result := ''; + UninstallCommand := ''; + if IsWow64 then + begin + RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\' + AppId + '_is1', 'UninstallString', UninstallCommand) + end + else + begin + RegQueryStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + AppId + '_is1', 'UninstallString', UninstallCommand) + end; + Result := UninstallCommand; +end; + +function Uninstall(AppId: String; IsWow64: Boolean): Boolean; +var + UninstallCommand: String; + ResultCode: Integer; +begin + Result := False; + UninstallCommand := GetUninstallCommand(AppId, IsWow64); + if UninstallCommand <> '' then + begin + ResultCode := 0; + if Exec(RemoveQuotes(UninstallCommand), '/SILENT /NORESTART /SUPPRESSMSGBOXES', '', SW_SHOW, ewWaitUntilTerminated, ResultCode) then + begin + Result := True; + end + else + begin + SuppressibleMsgBox('There was a problem removing the previous OpenMPT installation.', mbInformation, MB_OK, IDOK); + Result := False; + end; + end + else + begin + Result := True; + end; +end; + +function UninstallSingleArch: Boolean; +var + AppId_x86: String; + AppId_amd64: String; + Success: Boolean; +begin + Success := True; + AppId_x86 := '{67903736-E9BB-4664-B148-F62BCAB4FA42}'; + AppId_amd64 := '{9814C59D-8CBE-4C38-8A5F-7BF9B4FFDA6D}'; + if IsWin64() then + begin + Success := Uninstall(AppId_amd64, False) and Success; + Success := Uninstall(AppId_x86, True) and Success; + end + else + begin + Success := Uninstall(AppId_x86, False) and Success; + end; + Result := Success; +end; + +function GetPreviousSingleArchInstallPath: String; +var + AppId_x86: String; + AppId_amd64: String; + AppPath: String; +begin + AppPath := ''; + AppId_x86 := '{67903736-E9BB-4664-B148-F62BCAB4FA42}'; + AppId_amd64 := '{9814C59D-8CBE-4C38-8A5F-7BF9B4FFDA6D}'; + if IsWin64() then + begin + if AppPath = '' then AppPath := GetAppPath(AppId_amd64, False); + if AppPath = '' then AppPath := GetAppPath(AppId_x86, True); + end + else + begin + if AppPath = '' then AppPath := GetAppPath(AppId_x86, False); + end; + Result := AppPath; +end; + +function HasPreviousSingleArchInstallPath: Boolean; +begin + Result := GetPreviousSingleArchInstallPath() <> ''; +end; + + + + diff --git a/Src/external_dependencies/openmpt-trunk/installer/updatesigntool/updatesigntool.cpp b/Src/external_dependencies/openmpt-trunk/installer/updatesigntool/updatesigntool.cpp new file mode 100644 index 00000000..038e94d2 --- /dev/null +++ b/Src/external_dependencies/openmpt-trunk/installer/updatesigntool/updatesigntool.cpp @@ -0,0 +1,206 @@ + +#include "openmpt/all/BuildSettings.hpp" + +#include "mpt/base/span.hpp" +#include "mpt/crypto/hash.hpp" +#include "mpt/crypto/jwk.hpp" +#include "mpt/environment/environment.hpp" +#include "mpt/exception_text/exception_text.hpp" +#include "mpt/io/base.hpp" +#include "mpt/io/io.hpp" +#include "mpt/io/io_stdstream.hpp" +#include "mpt/out_of_memory/out_of_memory.hpp" +#include "mpt/string/types.hpp" +#include "mpt/string_transcode/transcode.hpp" +#include "mpt/uuid/uuid.hpp" +#include "mpt/uuid_namespace/uuid_namespace.hpp" + +#include "../common/mptBaseMacros.h" +#include "../common/mptBaseTypes.h" +#include "../common/mptBaseUtils.h" +#include "../common/mptStringFormat.h" +#include "../common/mptPathString.h" +#include "../common/mptFileIO.h" +#include "../common/Logging.h" +#include "../common/misc_util.h" + +#include <exception> +#include <iostream> +#include <locale> +#include <optional> +#include <stdexcept> +#include <vector> + + +#if defined(MPT_BUILD_MSVC) +#if MPT_COMPILER_MSVC || MPT_COMPILER_CLANG + +#pragma comment(lib, "bcrypt.lib") +#pragma comment(lib, "ncrypt.lib") +#pragma comment(lib, "rpcrt4.lib") +#pragma comment(lib, "shlwapi.lib") +#pragma comment(lib, "winmm.lib") + +#endif // MPT_COMPILER_MSVC || MPT_COMPILER_CLANG +#endif // MPT_BUILD_MSVC + + +OPENMPT_NAMESPACE_BEGIN + + +using namespace mpt::uuid_literals; + + +#if defined(MPT_ASSERT_HANDLER_NEEDED) && defined(MPT_BUILD_UPDATESIGNTOOL) +MPT_NOINLINE void AssertHandler(const mpt::source_location &loc, const char *expr, const char *msg) +{ + if(msg) + { + mpt::log::GlobalLogger().SendLogMessage(loc, LogError, "ASSERT", + MPT_USTRING("ASSERTION FAILED: ") + mpt::transcode<mpt::ustring>(mpt::common_encoding::ascii, msg) + MPT_USTRING(" (") + mpt::transcode<mpt::ustring>(mpt::common_encoding::ascii, expr) + MPT_USTRING(")") + ); + } else + { + mpt::log::GlobalLogger().SendLogMessage(loc, LogError, "ASSERT", + MPT_USTRING("ASSERTION FAILED: ") + mpt::transcode<mpt::ustring>(mpt::common_encoding::ascii, expr) + ); + } +} +#endif + + +namespace updatesigntool { + + +static mpt::ustring get_keyname(mpt::ustring keyname) +{ + if(keyname == MPT_USTRING("auto")) + { + constexpr mpt::UUID ns = "9a88e12a-a132-4215-8bd0-3a002da65373"_uuid; + mpt::ustring computername = mpt::getenv(MPT_USTRING("COMPUTERNAME")).value_or(MPT_USTRING("")); + mpt::ustring username = mpt::getenv(MPT_USTRING("USERNAME")).value_or(MPT_USTRING("")); + mpt::ustring name = MPT_UFORMAT("host={} user={}")(computername, username); + mpt::UUID uuid = mpt::UUIDRFC4122NamespaceV5(ns, name); + keyname = MPT_UFORMAT("OpenMPT Update Signing Key {}")(uuid); + } + return keyname; +} + +static void main(const std::vector<mpt::ustring> &args) +{ + try + { + if(args.size() < 2) + { + throw std::invalid_argument("Usage: updatesigntool [dumpkey|sign] ..."); + } + if(args[1] == MPT_USTRING("")) + { + throw std::invalid_argument("Usage: updatesigntool [dumpkey|sign] ..."); + } else if(args[1] == MPT_USTRING("dumpkey")) + { + if(args.size() != 4) + { + throw std::invalid_argument("Usage: updatesigntool dumpkey KEYNAME FILENAME"); + } + mpt::ustring keyname = get_keyname(args[2]); + mpt::ustring filename = args[3]; + mpt::crypto::keystore keystore(mpt::crypto::keystore::domain::user); + mpt::crypto::asymmetric::rsassa_pss<>::managed_private_key key(keystore, keyname); + mpt::SafeOutputFile sfo(mpt::PathString::FromUnicode(filename)); + mpt::ofstream & fo = sfo.stream(); + mpt::IO::WriteText(fo, mpt::transcode<std::string>(mpt::common_encoding::utf8, key.get_public_key_data().as_jwk())); + fo.flush(); + } else if(args[1] == MPT_USTRING("sign")) + { + if(args.size() != 6) + { + throw std::invalid_argument("Usage: updatesigntool sign [raw|jws_compact|jws] KEYNAME INPUTFILENAME OUTPUTFILENAME"); + } + mpt::ustring mode = args[2]; + mpt::ustring keyname = get_keyname(args[3]); + mpt::ustring inputfilename = args[4]; + mpt::ustring outputfilename = args[5]; + mpt::crypto::keystore keystore(mpt::crypto::keystore::domain::user); + mpt::crypto::asymmetric::rsassa_pss<>::managed_private_key key(keystore, keyname); + std::vector<std::byte> data; + { + mpt::ifstream fi(mpt::PathString::FromUnicode(inputfilename), std::ios::binary); + fi.imbue(std::locale::classic()); + fi.exceptions(std::ios::badbit); + while(!mpt::IO::IsEof(fi)) + { + std::array<std::byte, mpt::IO::BUFFERSIZE_TINY> buf; + mpt::append(data, mpt::IO::ReadRaw(fi, mpt::as_span(buf))); + } + } + if(mode == MPT_USTRING("")) + { + throw std::invalid_argument("Usage: updatesigntool sign [raw|jws_compact|jws] KEYNAME INPUTFILENAME OUTPUTFILENAME"); + } else if(mode == MPT_USTRING("raw")) + { + std::vector<std::byte> signature = key.sign(mpt::as_span(data)); + mpt::SafeOutputFile sfo(mpt::PathString::FromUnicode(outputfilename)); + mpt::ofstream & fo = sfo.stream(); + mpt::IO::WriteRaw(fo, mpt::as_span(signature)); + fo.flush(); + } else if(mode == MPT_USTRING("jws_compact")) + { + mpt::ustring signature = key.jws_compact_sign(mpt::as_span(data)); + mpt::SafeOutputFile sfo(mpt::PathString::FromUnicode(outputfilename)); + mpt::ofstream & fo = sfo.stream(); + mpt::IO::WriteText(fo, mpt::transcode<std::string>(mpt::common_encoding::utf8, signature)); + fo.flush(); + } else if(mode == MPT_USTRING("jws")) + { + mpt::ustring signature = key.jws_sign(mpt::as_span(data)); + mpt::SafeOutputFile sfo(mpt::PathString::FromUnicode(outputfilename)); + mpt::ofstream & fo = sfo.stream(); + mpt::IO::WriteText(fo, mpt::transcode<std::string>(mpt::common_encoding::utf8, signature)); + fo.flush(); + } else + { + throw std::invalid_argument("Usage: updatesigntool sign [raw|jws_compact|jws] KEYNAME INPUTFILENAME OUTPUTFILENAME"); + } + } else + { + throw std::invalid_argument("Usage: updatesigntool [dumpkey|sign] ..."); + } + } catch(const std::exception &e) + { + std::cerr << mpt::get_exception_text<std::string>(e) << std::endl; + throw; + } +} + +} // namespace updatesigntool + + +OPENMPT_NAMESPACE_END + + +#if defined(WIN32) && defined(UNICODE) +int wmain(int argc, wchar_t *argv[]) +#else +int main(int argc, char *argv[]) +#endif +{ + std::locale::global(std::locale("")); + std::vector<mpt::ustring> args; + for(int arg = 0; arg < argc; ++arg) + { + #if defined(WIN32) && defined(UNICODE) + args.push_back(mpt::transcode<mpt::ustring>(argv[arg])); + #else + args.push_back(mpt::transcode<mpt::ustring>(mpt::logical_encoding::locale, argv[arg])); + #endif + } + try + { + OPENMPT_NAMESPACE::updatesigntool::main(args); + } catch(...) + { + return 1; + } + return 0; +} |