linux-trace-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: "Vladislav Valtchev (VMware)" <vladislav.valtchev@gmail.com>
Cc: linux-trace-devel@vger.kernel.org, y.karadz@gmail.com
Subject: Re: [PATCH v2 13/24] trace-cmd: Move python-related files in python/
Date: Wed, 7 Feb 2018 15:11:14 -0500	[thread overview]
Message-ID: <20180207151114.29e76c2e@gandalf.local.home> (raw)
In-Reply-To: <20180207142238.74d12ec3@gandalf.local.home>

On Wed, 7 Feb 2018 14:22:38 -0500
Steven Rostedt <rostedt@goodmis.org> wrote:

> > @@ -248,10 +248,6 @@ $(obj)/%.o: $(src)/%.c
> >  %.o: $(src)/%.c
> >  	$(Q)$(call do_compile)
> >  
> > -TRACE_VIEW_OBJS =
> > -TRACE_VIEW_OBJS += $(obj)/kernel-shark/trace-view.o
> > -TRACE_VIEW_OBJS += $(obj)/kernel-shark/trace-view-store.o  
> 
> Why is this being moved into python code?

I now understand why you did it this way.



> > +++ b/python/Makefile
> > @@ -0,0 +1,40 @@
> > +include $(src)/scripts/utils.mk
> > +
> > +TRACE_VIEW_OBJS =
> > +TRACE_VIEW_OBJS += $(obj)/kernel-shark/trace-view.o
> > +TRACE_VIEW_OBJS += $(obj)/kernel-shark/trace-view-store.o
> > +
> > +ifdef BUILD_PYTHON_WORKS
> > +PYTHON_SO_INSTALL := ctracecmd.install
> > +PYTHON_PY_PROGS := event-viewer.install
> > +PYTHON_PY_LIBS := tracecmd.install tracecmdgui.install
> > +endif
> > +
> > +ctracecmd.so: ctracecmd.i $(LIBTRACECMD_STATIC)
> > +	swig -Wall -python -noproxy -I$(src)/include/traceevent -I$(src)/include/trace-cmd ctracecmd.i
> > +	$(CC) -fpic -c $(CPPFLAGS) $(CFLAGS) $(PYTHON_INCLUDES)  ctracecmd_wrap.c
> > +	$(CC) --shared $(LIBTRACECMD_STATIC) $(LDFLAGS) ctracecmd_wrap.o -o ctracecmd.so
> > +
> > +ctracecmdgui.so: ctracecmdgui.i $(LIBTRACECMD_STATIC) $(TRACE_VIEW_OBJS)

For this above.

I'd rather have that depend on a single file in kernel-shark directory,
or something that makes it a little cleaner.

-- Steve


> > +	swig -Wall -python -noproxy -I$(src)/kernel-shark/include ctracecmdgui.i
> > +	$(CC) -fpic -c  $(CPPFLAGS) $(CFLAGS) $(INCLUDES) $(PYTHON_INCLUDES) $(PYGTK_CFLAGS) ctracecmdgui_wrap.c
> > +	$(CC) --shared $(TRACE_VIEW_OBJS) $(LIBTRACECMD_STATIC) $(LDFLAGS) $(LIBS) $(CONFIG_LIBS) ctracecmdgui_wrap.o -o ctracecmdgui.so
> > +
> > +
> > +$(PYTHON_SO_INSTALL): %.install : %.so force
> > +	$(Q)$(call do_install_data,$<,$(python_dir_SQ))
> > +
> > +$(PYTHON_PY_PROGS): %.install : %.py force
> > +	$(Q)$(call do_install,$<,$(python_dir_SQ))
> > +
> > +$(PYTHON_PY_LIBS): %.install : %.py force
> > +	$(Q)$(call do_install_data,$<,$(python_dir_SQ))
> > +
> > +install_python: $(PYTHON_SO_INSTALL) $(PYTHON_PY_PROGS) $(PYTHON_PY_LIBS)
> > +
> > +
> > +clean:
> > +	$(RM) *.a *.so *.o .*.d ctracecmd_wrap.* ctracecmdgui_wrap.*
> > +
> > +force:
> > +.PHONY: clean force
> > diff --git a/ctracecmd.i b/python/ctracecmd.i
> > similarity index 100%
> > rename from ctracecmd.i
> > rename to python/ctracecmd.i
> > diff --git a/ctracecmdgui.i b/python/ctracecmdgui.i
> > similarity index 100%
> > rename from ctracecmdgui.i
> > rename to python/ctracecmdgui.i
> > diff --git a/event-viewer.py b/python/event-viewer.py
> > similarity index 100%
> > rename from event-viewer.py
> > rename to python/event-viewer.py
> > diff --git a/tracecmd.py b/python/tracecmd.py
> > similarity index 100%
> > rename from tracecmd.py
> > rename to python/tracecmd.py
> > diff --git a/tracecmdgui.py b/python/tracecmdgui.py
> > similarity index 100%
> > rename from tracecmdgui.py
> > rename to python/tracecmdgui.py  
> 

  parent reply	other threads:[~2018-02-07 20:11 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-06  8:48 [PATCH v2 00/24] trace-cmd: restructure the project's source tree Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 01/24] trace-cmd: Rename libparsevent to libtraceevent Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 02/24] trace-cmd: Move libtraceevent headers in include/traceevent Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 03/24] trace-cmd: Move trace-cmd headers in include/trace-cmd Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 04/24] trace-cmd: Move event-utils.h in lib/traceevent/include Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 05/24] trace-cmd: Extract part of Makefile in scripts/utils.mk Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 06/24] trace-cmd: Move libtraceevent *.c files in lib/traceevent Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 07/24] trace-cmd: Move trace-hash-local.h in lib/trace-cmd/include Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 08/24] trace-cmd: Move libtracecmd *.c files in lib/trace-cmd Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 09/24] trace-cmd: Move GUI headers in kernel-shark/include Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 10/24] trace-cmd: Move GUI *.c files in kernel-shark/ Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 11/24] trace-cmd: Move plugin_* files in plugins/ Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 12/24] trace-cmd: Fix the broken target ctracecmdgui.so Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 13/24] trace-cmd: Move python-related files in python/ Vladislav Valtchev (VMware)
2018-02-07 19:22   ` Steven Rostedt
2018-02-07 19:36     ` Steven Rostedt
2018-02-08  7:17       ` Vladislav K. Valtchev
2018-02-07 20:11     ` Steven Rostedt [this message]
2018-02-08  7:29       ` Vladislav K. Valtchev
2018-02-06  8:48 ` [PATCH v2 14/24] trace-cmd: Move tracecmd headers in tracecmd/include Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 15/24] trace-cmd: Move version.h in include/ Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 16/24] trace-cmd: Move trace-cmd app files in tracecmd/ Vladislav Valtchev (VMware)
2018-02-06  8:48 ` [PATCH v2 17/24] trace-cmd: Fix the logic behind SWIG_DEFINED in the Makefile Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 18/24] trace-cmd: Make the build to tell when python-dev is missing Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 19/24] trace-cmd: Make libtraceevent builable out-of-tree Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 20/24] trace-cmd: Make the plugins buildable out-of-tree Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 21/24] trace-cmd: Make libtracecmd " Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 22/24] trace-cmd: Make the trace-cmd target " Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 23/24] trace-cmd: Make the python targets " Vladislav Valtchev (VMware)
2018-02-06  8:49 ` [PATCH v2 24/24] trace-cmd: Make the GUI " Vladislav Valtchev (VMware)
2018-02-07  0:27 ` [PATCH v2 00/24] trace-cmd: restructure the project's source tree Steven Rostedt
2018-02-07 13:15   ` Vladislav Valtchev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180207151114.29e76c2e@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=linux-trace-devel@vger.kernel.org \
    --cc=vladislav.valtchev@gmail.com \
    --cc=y.karadz@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).