misterdownloadmanager: The ultimate open-source, clean-room download manager written from scratch in pure Rust for Windows, Mac, and Linux
Rust bittorrent-clientdebriddownload-acceleratordownload-managerdownloadmanagereguifile-downloadergallery-dlidmidm-alternativeinternet-download-managerm3u8-downloadermagnetplaylist-downloaderreal-debridrusttorrent-clientvideo-downloaderyoutube-downloaderyt-dlp
Windows: the C runtime is inside MDM's programs, so a missing or 32-bit VCRUNTIME140.dll can't stop them (#785) (#786)
Ahmed Nefzaouiff0560fd399d
diff --git a/.cargo/config.toml b/.cargo/config.tomlnew file mode 100644index 00000000..c5a7363c--- /dev/null+++ b/.cargo/config.toml@@ -0,0 +1,10 @@+# Windows: the C runtime is built into MDM's own programs instead of being loaded from Windows+# (VCRUNTIME140.dll). A PC without Microsoft's Visual C++ runtime, or with a 32-bit copy where+# the 64-bit one should be, then can't stop MDM from starting (#785: setup's browser helper+# failed with 0xc000007b). tools/installer/build.ps1 passes the same flag, as its own flags+# replace these.+[target.x86_64-pc-windows-msvc]+rustflags = ["-C", "target-feature=+crt-static"]++[target.aarch64-pc-windows-msvc]+rustflags = ["-C", "target-feature=+crt-static"]diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 770f92cc..7cdada44 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -25,6 +25,7 @@ Each release's notes on GitHub come from its section here (`## [X.Y.Z]`, see### Fixed+- Windows: MDM's programs carry Microsoft's C runtime inside them instead of loading it from Windows (`VCRUNTIME140.dll`), so a PC without that runtime, or with a 32-bit copy where the 64-bit one should be, no longer stops them: setup's last step failed there with "The application was unable to start correctly (0xc000007b)" ([#785](https://github.com/anefzaoui/misterdownloadmanager/issues/785)).- Wikimedia Commons videos download again: their quality list carries a negative size estimate, which MDM took for a page with no video at all ("it gave no video information").- Sites behind Akamai that let only browsers through (a 403 "Access Denied" page for MDM, the file for a browser, such as HPE's documentation PDFs) now download: MDM takes Akamai's refusal for the bot check it is and tries again the way a browser connects, as it does for Cloudflare's ([#771](https://github.com/anefzaoui/misterdownloadmanager/issues/771)).- Crash and freeze reports keep the log lines that explain them: 25 of the file-type icons carried no-op styles (`marker:none`, `mask:none` and the like) that MDM's SVG reader warned about each time they were drawn, 1,385 lines for one look at them all, and those warnings filled the end of the log a report includes ([#767](https://github.com/anefzaoui/misterdownloadmanager/issues/767)). The icons look the same.diff --git a/ROADMAP.md b/ROADMAP.mdindex d1032918..16866829 100644--- a/ROADMAP.md+++ b/ROADMAP.md@@ -503,6 +503,9 @@ Bug fixes from the first days of 0.5.0, a Safari extension, and more file types.These ship in the next version.+- ✅ Windows: MDM starts on a PC without Microsoft's Visual C++ runtime, or with the wrong copy of it+ (0xc000007b at setup's end): the runtime is inside MDM's programs+ ([#785](https://github.com/anefzaoui/misterdownloadmanager/issues/785))- ✅ Videos in one file (YouTube's qualities and their sound, most sites' MP4s) come down throughMDM's own downloader: yt-dlp finds them, then every connection Options → Connection gives, thespeed limits (a change applies at once), pause and resume like a file, after a restart too,diff --git a/tools/installer/build.ps1 b/tools/installer/build.ps1index 44d686e6..52bb5568 100644--- a/tools/installer/build.ps1+++ b/tools/installer/build.ps1@@ -22,9 +22,10 @@ if (-not $version) { throw "no version in Cargo.toml" }if (-not $NoBuild) {# The build machine's paths out of the programs (#25): panic locations and debug info say# "cargo\..." for cargo's folder and "mdm\..." for this checkout (shorter, and no user name).- # Encoded flags, as those paths may hold spaces.+ # Encoded flags, as those paths may hold spaces. They replace .cargo/config.toml's, so its+ # C runtime built into the programs (#785: no VCRUNTIME140.dll from Windows) is repeated here.$cargoHome = if ($env:CARGO_HOME) { $env:CARGO_HOME } else { Join-Path $env:USERPROFILE ".cargo" }- $env:CARGO_ENCODED_RUSTFLAGS = "--remap-path-prefix=$cargoHome=cargo" + [char]0x1f + "--remap-path-prefix=$root=mdm"+ $env:CARGO_ENCODED_RUSTFLAGS = "--remap-path-prefix=$cargoHome=cargo" + [char]0x1f + "--remap-path-prefix=$root=mdm" + [char]0x1f + "-Ctarget-feature=+crt-static"try {& cargo build --release -p mdm-app -p mdm-nmhost -p mdm-cli -p mdm-mcpif ($LASTEXITCODE) { throw "cargo build failed" }