From: "Steven Rostedt (VMware)" <rostedt@xxxxxxxxxxx> As libtraceevent and libtracefs are now packaged separately and are built from their own corresponding repos, the local copy that trace-cmd uses is only in the case that the libraries are not present on the local system. In this case, trace-cmd should build its wont static library and link to that. This will be deprecated in the future and trace-cmd will eventually depend on the external libraries for libtracefs and libtraceevent. Signed-off-by: Steven Rostedt (VMware) <rostedt@xxxxxxxxxxx> --- Makefile | 13 +------------ lib/traceevent/Makefile | 5 +---- lib/tracefs/Makefile | 5 +---- 3 files changed, 3 insertions(+), 20 deletions(-) diff --git a/Makefile b/Makefile index 737e54d82697..1f7cab57cd7d 100644 --- a/Makefile +++ b/Makefile @@ -234,12 +234,10 @@ export LIBTRACECMD_SHARED_VERSION LIBTRACECMD_SHARED_SO LIBTRACEEVENT=libtraceevent LIBTRACEEVENT_DIR = $(obj)/lib/traceevent LIBTRACEEVENT_STATIC = $(LIBTRACEEVENT_DIR)/libtraceevent.a -LIBTRACEEVENT_SHARED = $(LIBTRACEEVENT_DIR)/libtraceevent.so LIBTRACEFS=libtracefs LIBTRACEFS_DIR = $(obj)/lib/tracefs LIBTRACEFS_STATIC = $(LIBTRACEFS_DIR)/libtracefs.a -LIBTRACEFS_SHARED = $(LIBTRACEFS_DIR)/libtracefs.so ifeq ($(shell sh -c "$(PKG_CONFIG) --cflags $(LIBTRACEEVENT) > /dev/null 2>&1 && echo y"), y) LIBTRACEEVENT_CFLAGS = $(shell sh -c "$(PKG_CONFIG) --cflags $(LIBTRACEEVENT)") @@ -369,10 +367,6 @@ trace-cmd: force $(LIBTRACEEVENT_STATIC_BUILD) $(LIBTRACECMD_STATIC) $(LIBTRACEF force $(obj)/lib/trace-cmd/plugins/tracecmd_plugin_dir $(Q)$(MAKE) -C $(src)/tracecmd $(obj)/tracecmd/$@ -$(LIBTRACEEVENT_SHARED): force $(obj)/lib/traceevent/plugins/trace_python_dir \ - $(obj)/lib/traceevent/plugins/traceevent_plugin_dir - $(Q)$(MAKE) -C $(src)/lib/traceevent $@ - $(LIBTRACEEVENT_STATIC): force $(obj)/lib/traceevent/plugins/trace_python_dir \ $(obj)/lib/traceevent/plugins/traceevent_plugin_dir $(Q)$(MAKE) -C $(src)/lib/traceevent $@ @@ -386,17 +380,12 @@ $(LIBTRACECMD_SHARED): force $(LIBTRACEEVENT_SHARED_BUILD) $(LIBTRACEFS_STATIC): force $(Q)$(MAKE) -C $(src)/lib/tracefs $@ -$(LIBTRACEFS_SHARED): force - $(Q)$(MAKE) -C $(src)/lib/tracefs $@ - -libtraceevent.so: $(LIBTRACEEVENT_SHARED) libtraceevent.a: $(LIBTRACEEVENT_STATIC) libtracecmd.a: $(LIBTRACECMD_STATIC) libtracecmd.so: $(LIBTRACECMD_SHARED) libtracefs.a: $(LIBTRACEFS_STATIC) -libtracefs.so: $(LIBTRACEFS_SHARED) -libs: $(LIBTRACECMD_SHARED) $(LIBTRACEEVENT_SHARED_BUILD) $(LIBTRACEFS_SHARED_BUILD) +libs: $(LIBTRACECMD_SHARED) $(LIBTRACEEVENT_STATIC_BUILD) $(LIBTRACEFS_STATIC_BUILD) test: force $(LIBTRACEEVENT_STATIC_BUILD) $(LIBTRACEFS_STATIC_BUILD) $(LIBTRACECMD_STATIC) ifneq ($(CUNIT_INSTALLED),1) diff --git a/lib/traceevent/Makefile b/lib/traceevent/Makefile index 0f9e5db8f7df..edb2fccfff07 100644 --- a/lib/traceevent/Makefile +++ b/lib/traceevent/Makefile @@ -32,9 +32,6 @@ $(DEPS): | $(bdir) $(bdir)/libtraceevent.a: $(OBJS) $(Q)$(call do_build_static_lib) -$(bdir)/libtraceevent.so: $(OBJS) - $(Q)$(call do_compile_shared_library) - $(bdir)/%.o: %.c $(Q)$(call do_fpic_compile) @@ -50,6 +47,6 @@ ifneq ($(dep_includes),) endif clean: - $(RM) -f $(bdir)/*.a $(bdir)/*.so $(bdir)/*.o $(bdir)/.*.d + $(RM) -f $(bdir)/*.a $(bdir)/*.o $(bdir)/.*.d .PHONY: clean diff --git a/lib/tracefs/Makefile b/lib/tracefs/Makefile index 590a0ffed91a..33112690914d 100644 --- a/lib/tracefs/Makefile +++ b/lib/tracefs/Makefile @@ -29,9 +29,6 @@ LIBS = -L$(obj)/lib/traceevent -ltraceevent $(bdir)/libtracefs.a: $(OBJS) $(Q)$(call do_build_static_lib) -$(bdir)/libtracefs.so: $(OBJS) - $(Q)$(call do_compile_shared_library) - $(bdir)/%.o: %.c $(Q)$(call do_fpic_compile) @@ -47,6 +44,6 @@ ifneq ($(dep_includes),) endif clean: - $(RM) $(bdir)/*.a $(bdir)/*.so $(bdir)/*.o $(bdir)/.*.d + $(RM) $(bdir)/*.a $(bdir)/*.o $(bdir)/.*.d .PHONY: clean -- 2.29.2