🔒 Repository is read-only – file editing is disabled.

recipes/gui/otto/PAGBUILD.yaml main

96 linii Raw ← Powrót
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
pkgname: otto
pkgver: '1.3.0'
pkgrel: '1'
pkgdesc: 'Visually-focused Wayland desktop: compositor, bar, launcher, files and settings'
url: 'https://github.com/nongio/otto'
arch: x86_64
license:
- MIT
depends:
- xorg-libdrm
- systemd
- mesa
- libxkbcommon
- wayland
- libinput
- dbus
- seatd
- pipewire
- freetype
- xorg-fontconfig
- xorg-pixman
- noto-fonts
- gstreamer
- gstreamer-plugins-base
makedepends:
- git
- rustc
- llvm
- libdisplay-info
source:
- 'https://github.com/nongio/otto/archive/refs/tags/v${pkgver}.tar.gz'
sha256sums:
- SKIP
build: |
  cd otto-${pkgver}
  # Upstream nie uzywa -locked; Cargo.lock jest w wydaniu, ale nie wymuszamy go,
  # zeby nie przerywac builda przy rozjechanym locku.
  unset CFLAGS CXXFLAGS LDFLAGS CPPFLAGS
  cargo build --release
  for _p in otto-bar otto-islands otto-lock otto-greeter xdg-desktop-portal-otto \
            otto-rdp otto-settings otto-files otto-launcher otto-emoji \
            otto-quickview otto-media-kit otto-msg; do
    cargo build --release -p "${_p}"
  done
package: |
  cd otto-${pkgver}

  _bin() {
    if [ -f "$1" ]; then
      install -Dm755 "$1" "${PKGDIR}/usr/bin/$(basename "$1")"
    else
      echo "uwaga: brak binarki $1" >&2
    fi
  }

  for _b in otto otto-bar otto-islands otto-lock otto-greeter otto-rdp \
            otto-settings otto-files otto-launcher otto-emoji otto-quickview \
            otto-msg otto-media-worker; do
    _bin "target/release/${_b}"
  done

  if [ ! -f "${PKGDIR}/usr/bin/otto" ]; then
    echo "brak glownej binarki otto - przerywam" >&2
    exit 1
  fi

  install -Dm755 target/release/xdg-desktop-portal-otto \
    "${PKGDIR}/usr/libexec/xdg-desktop-portal-otto"

  install -Dm644 README.md "${PKGDIR}/usr/share/doc/${pkgname}/README.md"
  install -Dm644 LICENSE "${PKGDIR}/usr/share/licenses/${pkgname}/LICENSE"
  install -Dm644 components/xdg-desktop-portal-otto/portals.conf.example \
    "${PKGDIR}/usr/share/doc/${pkgname}/portals.conf.example"

  install -Dm644 otto_config.example.toml "${PKGDIR}/etc/otto/config.toml"
  install -Dm644 otto_config.example.toml "${PKGDIR}/etc/otto/config.example.toml"
  install -Dm644 components/otto-lock/otto-lock.pam "${PKGDIR}/etc/pam.d/otto-lock"

  install -Dm644 resources/otto.desktop "${PKGDIR}/usr/share/wayland-sessions/otto.desktop"
  install -Dm644 resources/otto-files.desktop "${PKGDIR}/usr/share/applications/otto-files.desktop"
  install -Dm644 resources/otto-trash.desktop "${PKGDIR}/usr/share/applications/otto-trash.desktop"
  install -Dm644 resources/otto-settings.desktop "${PKGDIR}/usr/share/applications/otto-settings.desktop"

  for _px in 16 24 32 48 64 128 256 512; do
    install -Dm644 "components/otto-files/resources/icons/hicolor/${_px}x${_px}/apps/otto-files.png" \
      "${PKGDIR}/usr/share/icons/hicolor/${_px}x${_px}/apps/otto-files.png"
  done
  install -Dm644 components/otto-files/resources/icons/hicolor/scalable/apps/otto-files.svg \
    "${PKGDIR}/usr/share/icons/hicolor/scalable/apps/otto-files.svg"

  install -Dm644 components/xdg-desktop-portal-otto/otto.portal \
    "${PKGDIR}/usr/share/xdg-desktop-portal/portals/otto.portal"
  install -Dm644 components/xdg-desktop-portal-otto/org.freedesktop.impl.portal.desktop.otto.service \
    "${PKGDIR}/usr/share/dbus-1/services/org.freedesktop.impl.portal.desktop.otto.service"
  install -Dm644 components/xdg-desktop-portal-otto/xdg-desktop-portal-otto.service \
    "${PKGDIR}/usr/lib/systemd/user/xdg-desktop-portal-otto.service"