{"record":{"id":"e4ff7b1e13566209","repo":"Morganamilo/paru","slug":"packages-failed-to-build","errorCode":null,"errorMessage":"packages failed to build: {}","messagePattern":"packages failed to build: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/install.rs","lineNumber":451,"sourceCode":"                        .unwrap()\n                        .path\n                        .clone(),\n                };\n\n                if let Err(err) = clean_untracked(config, &path) {\n                    print_error(config.color.error, err);\n                    ret = 1;\n                }\n            }\n        }\n\n        if !self.failed.is_empty() {\n            let failed = self\n                .failed\n                .iter()\n                .map(|f| f.to_string())\n                .collect::<Vec<_>>();\n            bail!(tr!(\"packages failed to build: {}\", failed.join(\"  \")));\n        }\n\n        if ret != 0 {\n            Status::err(ret)\n        } else {\n            Ok(())\n        }\n    }\n\n    fn debug_paths(\n        &mut self,\n        config: &Config,\n        base: &mut Base,\n        pkgdest: &HashMap<String, String>,\n    ) -> Result<HashMap<String, String>> {\n        let mut debug_paths = HashMap::new();\n\n        if config.install_debug {","sourceCodeStart":433,"sourceCodeEnd":469,"githubUrl":"https://github.com/Morganamilo/paru/blob/9ac3578807a87858651e81a02586ceb947686e7c/src/install.rs#L433-L469","documentation":"After the build phase, build_cleanup checks the installer's failed list; if any packages failed to build, it aggregates their names and bails with \"packages failed to build: <names>\". This is the summary error reported when one or more AUR builds did not produce packages.","triggerScenarios":"resolve_targets → build_cleanup with self.failed non-empty: any package whose makepkg build raised an error (compile failure, missing dependency, checksum mismatch) is collected into the failed list.","commonSituations":"Upstream source changed so checksums no longer match; compiler errors on current toolchain; missing makedepends; out-of-date PKGBUILD after an Arch update; building many packages where one fails and aborts the batch.","solutions":["Read each failed package's earlier build log to find the concrete makepkg error","Rebuild the failing package individually with --rebuild to see full output","Update the AUR package (or wait for the maintainer) if the PKGBUILD is outdated","Remove stale build directories in the cache and retry the failed subset"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"// build packages one at a time so one failure doesn't abort the batch\nfor pkg in targets {\n    if let Err(e) = build_single(&pkg) { eprintln!(\"skipping {pkg}: {e}\"); }\n}","typeGuard":null,"tryCatchPattern":"match resolve_targets() {\n    Err(e) if e.to_string().starts_with(\"packages failed to build:\") => {\n        let failed: Vec<&str> = e.to_string().rsplit(\": \").next().unwrap().split(\"  \").collect();\n        eprintln!(\"retry individually: {failed:?}\");\n    }\n    other => other?,\n}","preventionTips":["Use --rebuild on individual failures to capture full build logs","Keep makedepends installed and the base toolchain updated","Watch for checksum mismatches after upstream releases and update PKGBUILDs","Clean stale build directories in the cache before retrying"],"tags":["build","makepkg","aur","batch"],"backgroundTag":"missing-dependency","analyzedSha":"9ac3578807a87858651e81a02586ceb947686e7c","analyzedAt":"2026-09-12T04:57:59.861Z","contentChangedAt":"2026-09-12T04:57:59.861Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}