2023-01-19 06:37:07 -06:00
|
|
|
# Maintainer: Rudra Saraswat <rs2009@ubuntu.com>
|
|
|
|
|
2023-03-27 17:24:18 -05:00
|
|
|
pkgbase=blend-git
|
|
|
|
pkgname=('blend-git' 'blend-settings-git')
|
2023-05-14 09:04:02 -05:00
|
|
|
pkgver=r50.2e0016f
|
2023-04-20 05:33:48 -05:00
|
|
|
pkgrel=1
|
2023-03-27 17:24:18 -05:00
|
|
|
pkgdesc="A package manager for blendOS"
|
|
|
|
arch=('x86_64' 'i686')
|
|
|
|
url="https://github.com/blend-os/blend"
|
|
|
|
license=('GPL3')
|
2023-06-24 07:47:23 -05:00
|
|
|
makedepends=("electron" 'git' 'npm' 'base-devel')
|
2023-11-16 02:08:18 -06:00
|
|
|
source=('git+https://github.com/blend-os/blend'
|
2023-03-27 17:24:18 -05:00
|
|
|
'blend-settings.desktop'
|
2023-06-25 01:45:19 -05:00
|
|
|
'blend-package-installer.desktop'
|
2023-04-20 05:33:48 -05:00
|
|
|
'blend-settings'
|
|
|
|
'blend.sh')
|
2023-02-11 09:06:47 -06:00
|
|
|
sha256sums=('SKIP'
|
2024-02-09 10:17:55 -06:00
|
|
|
'ba11ef22fe92a78239855c1bbc07d8c5be7cd94728bb3baf6184d2f42a80a4c2'
|
2023-02-11 09:06:47 -06:00
|
|
|
'a605d24d2fa7384b45a94105143db216db1ffc0bdfc7f6eec758ef2026e61e54'
|
2023-06-25 01:45:19 -05:00
|
|
|
'23decd858ab49e860999bba783da78f43adc7b678065057cadfc2eeaefb2e870'
|
2024-02-09 10:17:55 -06:00
|
|
|
'73cb7c39190d36f233b8dfbc3e3e6737d56e61e90881ad95f09e5ae1f9b405a8'
|
|
|
|
'7dab67fb5c0239b6645659a7838de85b1420683a5bf52d8a8a3d324b69210a40')
|
2023-01-19 06:37:07 -06:00
|
|
|
|
2023-03-27 17:24:18 -05:00
|
|
|
pkgver() {
|
|
|
|
cd "${srcdir}/${pkgbase%-git}"
|
|
|
|
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
|
|
|
|
}
|
|
|
|
|
|
|
|
prepare() {
|
|
|
|
cd "${srcdir}/${pkgbase%-git}/${pkgbase%-git}-settings"
|
|
|
|
npm config set cache "${srcdir}/npm-cache"
|
2023-02-11 09:06:47 -06:00
|
|
|
npm install
|
2023-03-27 17:24:18 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
cd "${srcdir}/${pkgbase%-git}/${pkgbase%-git}-settings"
|
|
|
|
npm config set cache "${srcdir}/npm-cache"
|
2023-02-11 09:06:47 -06:00
|
|
|
export NODE_ENV=production
|
2023-06-24 07:47:23 -05:00
|
|
|
electronDist="/usr/lib/electron"
|
|
|
|
electronVer="$(sed s/^v// /usr/lib/electron/version)"
|
2023-02-11 09:06:47 -06:00
|
|
|
npm run icons
|
2023-03-27 17:24:18 -05:00
|
|
|
npm run pack -- -c.electronDist=${electronDist} \
|
|
|
|
-c.electronVersion=${electronVer} --publish never
|
2023-04-25 10:41:01 -05:00
|
|
|
cd ../overlayfs-tools; make
|
2023-02-11 09:06:47 -06:00
|
|
|
}
|
|
|
|
|
2023-03-27 17:24:18 -05:00
|
|
|
package_blend-git() {
|
2023-04-20 01:04:27 -05:00
|
|
|
depends=('bash' 'blend-settings-git' 'podman' 'python' 'python-pexpect')
|
2023-03-27 17:24:18 -05:00
|
|
|
provides=("${pkgname%-git}")
|
|
|
|
conflicts=("${pkgname%-git}")
|
|
|
|
|
|
|
|
cd "${srcdir}/${pkgbase%-git}"
|
|
|
|
install -Dm755 \
|
|
|
|
"${pkgname%-git}" \
|
|
|
|
"init-${pkgname%-git}" \
|
|
|
|
"host-${pkgname%-git}" \
|
|
|
|
"${pkgname%-git}-files" \
|
|
|
|
-t "${pkgdir}"/usr/bin/
|
2023-04-25 10:41:01 -05:00
|
|
|
install -Dm755 "overlayfs-tools/overlayfs-tools" -t \
|
|
|
|
"${pkgdir}/usr/bin/"
|
2023-04-20 05:33:48 -05:00
|
|
|
install -Dm644 ../"${pkgname%-git}.sh" -t \
|
|
|
|
"${pkgdir}"/etc/profile.d/
|
2023-03-27 17:24:18 -05:00
|
|
|
install -Dm644 "${pkgname%-git}-files.service" -t \
|
|
|
|
"${pkgdir}"/usr/lib/systemd/user/
|
|
|
|
install -Dm644 "${pkgname%-git}.hook" \
|
|
|
|
"${pkgdir}/usr/lib/initcpio/hooks/${pkgname%-git}"
|
|
|
|
install -Dm644 "${pkgname%-git}.install" \
|
|
|
|
"${pkgdir}/usr/lib/initcpio/install/${pkgname%-git}"
|
2023-02-11 09:06:47 -06:00
|
|
|
}
|
|
|
|
|
2023-03-27 17:24:18 -05:00
|
|
|
package_blend-settings-git() {
|
|
|
|
pkgdesc="blendOS Settings"
|
|
|
|
depends=("electron${_electronversion}")
|
2023-04-20 01:04:27 -05:00
|
|
|
provides=(blend-settings)
|
|
|
|
conflicts=(blend-settings)
|
2023-03-27 17:24:18 -05:00
|
|
|
|
|
|
|
cd "${srcdir}/${pkgbase%-git}/${pkgbase%-git}-settings"
|
2023-01-19 06:37:07 -06:00
|
|
|
|
2023-02-11 09:06:47 -06:00
|
|
|
local _arch
|
2023-03-27 17:24:18 -05:00
|
|
|
case ${CARCH} in
|
2023-02-11 09:06:47 -06:00
|
|
|
i686)
|
|
|
|
_arch=linux-ia32-unpacked
|
|
|
|
;;
|
|
|
|
x86_64)
|
|
|
|
_arch=linux-unpacked
|
|
|
|
;;
|
|
|
|
*)
|
2023-03-27 17:24:18 -05:00
|
|
|
_arch=linux-${CARCH}-unpacked
|
2023-02-11 09:06:47 -06:00
|
|
|
;;
|
|
|
|
esac
|
2023-03-27 17:24:18 -05:00
|
|
|
|
|
|
|
install -Dm644 "dist/${_arch}/resources/app.asar" \
|
|
|
|
"$pkgdir/usr/lib/${pkgname%-git}/${pkgname%-git}.asar"
|
|
|
|
|
2023-02-11 09:06:47 -06:00
|
|
|
for icon_size in 16 24 32 48 64 128 256 512; do
|
2023-03-27 17:24:18 -05:00
|
|
|
install -Dm644 "build/icons/png/${icon_size}x${icon_size}.png" \
|
|
|
|
"${pkgdir}/usr/share/icons/hicolor/${icon_size}x${icon_size}/apps/${pkgname%-git}.png"
|
2023-02-11 09:06:47 -06:00
|
|
|
done
|
2023-03-27 17:24:18 -05:00
|
|
|
|
|
|
|
install -Dm644 "${srcdir}/${pkgname%-git}.desktop" -t \
|
|
|
|
"${pkgdir}"/usr/share/applications/
|
2023-04-20 05:33:48 -05:00
|
|
|
|
2023-06-25 01:45:19 -05:00
|
|
|
install -Dm644 "${srcdir}/blend-package-installer.desktop" -t \
|
|
|
|
"${pkgdir}"/usr/share/applications/
|
|
|
|
|
2023-03-27 17:24:18 -05:00
|
|
|
install -Dm755 "${srcdir}/${pkgname%-git}" -t "${pkgdir}"/usr/bin/
|
2023-01-19 06:37:07 -06:00
|
|
|
}
|