centricular / gstcefsrc

A simple gstreamer wrapper around Chromium Embedded Framework
87 stars 45 forks source link

implement make install #30

Closed ghostnumber7 closed 3 years ago

ghostnumber7 commented 3 years ago

Related to talks on #28 I ended up implementing make install functionality instead of some custom variable. For example to install in /usr/lib/x86_64-linux-gnu/gstreamer-1.0/gstcef/ you could run as follows

cmake \
      -DCMAKE_INSTALL_PREFIX=/usr/lib/x86_64-linux-gnu/gstreamer-1.0/gstcef/ \
      -DCMAKE_BUILD_TYPE=Release \
      -G"Unix Makefiles" .. && make && sudo make install

If that is GStreamer plugin path (can be a subdirectory as gstreamer recurses by default) then there is no need to set GST_PLUGIN_PATH variable, if not, you can simply set the variable to the install path as in GST_PLUGIN_PATH=/usr/lib/x86_64-linux-gnu/gstreamer-1.0/gstcef/:$GST_PLUGIN_PATH instead of using the build/Release path.

If CMAKE_INSTALL_PREFIX is not defined when building it will behave just like now (can't be installed and won't work if moved)

Tested on Debian (bullseye) and Ubuntu (focal) only.

ghostnumber7 commented 3 years ago

I guess there must be a way to either 1) know the location of libgstcef.so and infer from there or 2) install libcef.so in a proper lib path. Both approaches should work. I'll add the entry in troubleshooting tomorrow