magiruuvelvet / LightweightQtDRMStreamViewer

A lightweight as possible DRM stream viewer based on the Qt Web Engine
MIT License
17 stars 4 forks source link

issue with packaging #9

Closed omni6 closed 6 years ago

omni6 commented 6 years ago

i wrote a pkgbuild for my own purposes:

pkgname=LightweightQtDRMStreamViewer-git
_gitname=LightweightQtDRMStreamViewer
pkgver=r48.e36e644
pkgrel=1
pkgdesc='A lightweight as possible DRM stream viewer based on the Qt Web Engine'
arch=('i686' 'x86_64')
url='https://github.com/magiruuvelvet/LightweightQtDRMStreamViewer'
license=('GPL3')
depends=('qt5-webengine-widevine')
optdepends=('pepper-flash: Needed for some streaming services')
makedepends=('git')
source=("git+${url}.git"
        "${_gitname}.desktop")
sha256sums=('SKIP'
            '555b0be1557d89c424e274dc5a67435f642c10c972f3015b0b569562b18a5da6')

pkgver() {
   cd ${srcdir}/${_gitname}

   printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"

}

build() {
   cd ${srcdir}/${_gitname}

   qmake -config release
   make

}

package() {

   mkdir -p ${pkgdir}/usr/share/${_gitname}/providers
   cp -r ${srcdir}/${_gitname}/sample-config/providers/ ${pkgdir}/usr/share/${_gitname}/
   install -Dm755 ${srcdir}/${_gitname}/${_gitname} ${pkgdir}/usr/bin/${_gitname}
   install -Dm755 ${srcdir}/${_gitname}.desktop ${pkgdir}/usr/share/applications/${_gitname}.desktop
   install -Dm644 ${srcdir}/${_gitname}/Resources/app-icon.svgz ${pkgdir}/usr/share/pixmaps/Streamviewer-icon.svgz

}

so far so good, it is mostly usable for me but there are a few problems. i copy the content from /providers to usr/share i think this should be the right place. but on first load it has to be copied to ~/.config where it belongs for the user instance.

do you plan to update your makefile and add install rules?

magiruuvelvet commented 6 years ago

I currently don't read anything from the system, just the users configuration directory. That's the idea here, so this won't work, no matter what you try. I would first need to write some code to make this work as you excepted it.

I have an idea on how to implement this, as I also need to handle conflicting files (same name) and give the local configs more priority.

magiruuvelvet commented 6 years ago

@omni6 i implemented this just now in cec1e2a6c26ed0ea6aa1b7b2007bdebc2cf6cb5a, could you test the changes and report back? thanks

it should now see files in /usr/share/LightweightQtDRMStreamViewer/providers and load them from there

please note local config files have more priority and will override the system installed ones

omni6 commented 6 years ago

works!

magiruuvelvet commented 6 years ago

good thanks for testing

magiruuvelvet commented 6 years ago

sorry for hijacking an old issue, i just want to inform you that the build system has changed to cmake now, qmake was removed