makedeb


webext-localcdn-firefox 2.6.80-0


Emulates remote frameworks and delivers them as local resource, extension for Firefox.

Viewing /PKGBUILD.

View raw.

Click here to go back to the Git tree for webext-localcdn-firefox.

# Maintainer: exponential <echo ZXhwb25lbnRpYWxtYXRyaXhAcHJvdG9ubWFpbC5jb20K | base64 -d>
# If your Firefox version doesn't support extracted webextentions
#_UNCOMPRESS=0
pkgname=webext-localcdn-firefox
_download_name="localcdn_fork_of_decentraleyes"
pkgver="2.6.80"
_fileid=('4518039')
pkgrel=0
pkgdesc='Emulates remote frameworks and delivers them as local resource, extension for Firefox.'
arch=('all')
url='https://addons.mozilla.org/en-US/firefox/addon/localcdn-fork-of-decentraleyes/'
license=('MPL2')
optdepends=('firefox' 'firefox-esr')
source=("https://addons.mozilla.org/firefox/downloads/file/$_fileid/${_download_name}-${pkgver}.xpi")
noextract=("${_download_name}-${pkgver}.xpi")
extensions=()
b2sums=('3041d1a52941c8e5976788b780cbf81df61161a1e2cf88d339aab99d6b46bd9cc940ce6bf10cc48d561c4a78181c22774dad688adfc1ea8df6de48c583861dcd')

prepare() {
  if [ -z "$_UNCOMPRESS" ];
  then
    # clean
    rm -Rf "${pkgname}-${pkgver}"
    # extract
    install -dm755 "${srcdir}/$pkgname-${pkgver}"
    bsdtar -xf "$_download_name-${pkgver}.xpi" -C "${srcdir}/$pkgname-${pkgver}"
  fi
}

package() {
  _mozilla_id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"
  _ext_id="{b86e4813-687a-43e6-ab65-0bde4ab75758}"
  _license_path="/usr/share/common-licenses/MPL-2.0"

  install -dm755 "${pkgdir}/usr/share/mozilla/extensions/$_mozilla_id"
  if [ -z "$_UNCOMPRESS" ];
  then
    mv "${srcdir}/$pkgname-${pkgver}" "${pkgdir}/usr/share/mozilla/extensions/$_mozilla_id/$_ext_id"
  else
    install -Dm644 "$_download_name-${pkgver}.xpi" "${pkgdir}/usr/share/mozilla/extensions/$_mozilla_id/$_ext_id.xpi"
  fi
  # Doc
  install -dm755 "${pkgdir}/usr/share/doc/$pkgname"
  ln -s "$_license_path" "${pkgdir}/usr/share/doc/$pkgname/"
}