CatxFish / obs-v4l2sink

obs studio output plugin for Video4Linux2 device
GNU General Public License v2.0
930 stars 99 forks source link

Add Fedora 32 instructions and use the dev packages to avoid compilin… #43

Closed DaveWK closed 3 years ago

DaveWK commented 4 years ago

note: I know this one is up: https://github.com/CatxFish/obs-v4l2sink/pull/33 but I think i was able to trim down the build time considerably by reworking the cmake a bit..

…g obs-studio

There's a lot of deps I seemed to be mising to compile obs-studio

Interstingly the "dev" package for Fedora does contain the ObsPluginHelpers.cmake however the Ubuntu one does not

I noticed the config cmake for libObs seemed to have any values or things you'd need out of it so the "include dir" statement isn't needed

You can still pass in a var to get the old behaviour and leverage any possibly shared libs like ffmped with the LIBOBS_CMAKE_MODULES var

I was able to successfuly get this working with Fedora 32

raylu commented 4 years ago

on my Debian system, I get

-- Detecting CXX compile features - done
-- Found Libobs: /usr/lib/x86_64-linux-gnu/libobs.so  
CMake Error at external/FindLibObs.cmake:76 (include):
  include could not find load file:

    /LibObsConfig.cmake
Call Stack (most recent call first):
  CMakeLists.txt:5 (include)

-- Configuring incomplete, errors occurred!

https://github.com/veecue/obs-v4l2sink/commit/e6102b594402cff01d8c23a70cf77ec79b4839ad gets me past this error

scottlinux commented 4 years ago

@lukester1975 gave steps to build on Fedora 32 without the need of a PR:

https://github.com/CatxFish/obs-v4l2sink/issues/42#issuecomment-632560679

DaveWK commented 4 years ago

(Reposted/deleted from other thread) I think those instrructions are using dependencies off the system without specifying them for obs-studio, which additionally was why I wanted to not compile obs-studio to build the plugin, as it adds extra packages and steps to make it. if I install the bin for obs-studio from a package manager I dont need to install as many deps or wait for obs-studio to compile just to get the static libs.

DaveWK commented 4 years ago

@raylu -- are you sure you installed libobs-dev? I think this is the right place for debian and ubuntu? https://packages.ubuntu.com/bionic/amd64/libobs-dev/filelist

DaveWK commented 4 years ago

Added some dockerfiles to prove that it's working on both debian and fedora now; there is an odd bug in obs-studio's packaging where the ubuntu/debian version doesn't contain obs-frontend-api.h (but the Fedora package does) -- a fix was merged a few days ago: https://github.com/obsproject/obs-studio/pull/2635

DaveWK commented 4 years ago

I am not super familiar with if there's some trickery that I can do to make cmake use relative paths for the install makefile, but it's almost at the point where it seems like using CPack and making an rpm/deb might be a simpler solution to package it all in a docker container..