Re: [PATCH 4/5] kernel-shark: Split the installation in two components

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Steven,

On 5.01.21 г. 23:29 ч., Steven Rostedt wrote:
On Tue,  5 Jan 2021 17:54:52 +0200
"Yordan Karadzhov (VMware)" <y.karadz@xxxxxxxxx> wrote:

The user can choose to install only the KernelShark GUI via
"install_gui.sh". It is also possible to install the library headers
and this can be done via "install_libkshark-devel.sh".

The changes implemented in this patch are inspired by the talk
"Deep CMake For Library Authors" presented at CppCon 2019 by Craig Scott.
https://crascit.com/2019/10/16/cppcon-2019-deep-cmake-for-library-authors/


I applied the series. But is there a way to install in a specific directory
and not in the system directories? (I didn't watch the talk).

For example, I can do:

  $ mkdir /tmp/install
  $ make DESTDIR=/tmp/install/ install

for libtraceveent, libtracefs and trace-cmd / libtracecmd and it will
install into /tmp/install/... just like it would have installed in /. The
big difference is, I don't need to be root to run that command.


Yes, we have a similar functionality since the very beginning of KS 1.0 and it is not been changed here. You can specify the install destination using a cmake command line argument like this:

cmake -D_INSTALL_PREFIX=/tmp/install/ ..

All this is documented in the README file. The only difference is that in your case you provide the destination at the very end when you do "make install", while here it has to be done at the very beginning when you call cmake.

Note that the two new helper scripts (install_gui.sh and install_libkshark-devel.sh) can be used instead of "sudo make install" but this is needed only if you want to split the installation. A normal "make install" will just install everything.

However, you are right that it is probably better if we remove the sudo from the two helper scripts.

Thanks!
Yordan


Then what I can do is:

  $ cd /tmp/install
  $ tar -cvjf ../package.tar.bz2 .
  $ scp ../package.tar.bz2 root@somebox:/tmp
  $ ssh root@somebox
  # cd /
  # tar -xvjf /tmp/package.tar.bz2

And that would have installed the package on to the machine "somebox".

-- Steve




[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux