[m-rev.] diff: Don't link to libmer_eventspec redundantly.

Peter Wang novalazy at gmail.com
Tue Jan 28 17:20:16 AEDT 2020


This avoid a link error when using clang's ThinLTO mode:
    error: Failed to link module
    ../trace/libmer_eventspec.a.llvm.18688.mercury_event_parser.c:
    Expected at most one ThinLTO module per bitcode file

compiler/Mmakefile:
    Remove libmer_eventspec.a from MLOBJS.
    Mmake.workspace already causes the library to be linked in.

diff --git a/compiler/Mmakefile b/compiler/Mmakefile
index fda76ef5a..b8990ec77 100644
--- a/compiler/Mmakefile
+++ b/compiler/Mmakefile
@@ -46,8 +46,6 @@ VPATH = \
 MCFLAGS	     += --flags COMP_FLAGS $(CONFIG_OVERRIDE)
 
 ifeq ("$(filter csharp% java% erlang%,$(GRADE))","")
-MLOBJS       := ../trace/lib$(EVENTSPEC_LIB_NAME).$A \
-		$(MLOBJS)
 MLLIBS       += $(THREAD_LIBS)
 else
 MLOBJS =
-- 
2.25.0



More information about the reviews mailing list