[Git][ghc/ghc][wip/andreask/linker_fix] webbles: Always output debugBelch linker errors
Andreas Klebinger pushed to branch wip/andreask/linker_fix at Glasgow Haskell Compiler / GHC Commits: 7030f509 by Andreas Klebinger at 2026-01-30T11:31:42+01:00 webbles: Always output debugBelch linker errors - - - - - 3 changed files: - rts/Linker.c - rts/LinkerInternals.h - rts/linker/LoadArchive.c Changes: ===================================== rts/Linker.c ===================================== @@ -1444,6 +1444,7 @@ preloadObjectFile (pathchar *path) oc = mkOc(STATIC_OBJECT, path, image, fileSize, true, NULL, misalignment); if (!verifyAndInitOc(oc)) { + freePreloadObjectFile(oc); freeObjectCode(oc); debugBelch("loadObj: Failed to verify oc.\n"); return NULL; ===================================== rts/LinkerInternals.h ===================================== @@ -385,7 +385,7 @@ extern Elf_Word shndx_table_uninit_label; ) #define ocDebugBelch(oc, s, ...) \ - debugBelch("%s(%" PATH_FMT ": " s, \ + errorBelch("%s(%" PATH_FMT ": " s, \ __func__, \ OC_INFORMATIVE_FILENAME(oc), \ ##__VA_ARGS__) ===================================== rts/linker/LoadArchive.c ===================================== @@ -627,8 +627,9 @@ HsInt loadArchive_ (pathchar *path) if(!verifyAndInitOc( oc )) { - freeObjectCode( oc ); IF_DEBUG(linker, ocDebugBelch(oc, "Faild to verify ... skipping.")); + errorBelch("Faild to verify ... skipping."); + freeObjectCode( oc ); continue; } View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7030f5099b18eb299471e21142f1ebf4... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7030f5099b18eb299471e21142f1ebf4... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Andreas Klebinger (@AndreasK)