archrelease: copy trunk to extra-x86_64
[arch-packages.git] / gvfs / repos / extra-x86_64 / PKGBUILD
blobe9a29c19a82bdf718ffbf663906007e1846d558b
1 # Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
2 # Contributor: Jan de Groot <jgc@archlinux.org>
4 pkgbase=gvfs
5 pkgname=(gvfs gvfs-{smb,afc,gphoto2,goa,mtp,nfs,google})
6 pkgver=1.48.1
7 pkgrel=1
8 pkgdesc="Virtual filesystem implementation for GIO"
9 url="https://wiki.gnome.org/Projects/gvfs"
10 arch=(x86_64)
11 license=(LGPL)
12 depends=(avahi dconf fuse3 libarchive libcdio-paranoia libsoup udisks2 libsecret
13          libbluray libgudev gcr psmisc 'gsettings-desktop-schemas>=3.34.0')
14 makedepends=(dbus libgphoto2 libimobiledevice smbclient docbook-xsl gtk3 libmtp
15              gnome-online-accounts libnfs libgdata git gtk-doc python meson
16              openssh)
17 groups=(gnome)
18 _commit=a971ec4b5c1ff016e7273f2d390248f8c2d65106  # tags/1.48.1^0
19 source=("git+https://gitlab.gnome.org/GNOME/gvfs.git#commit=$_commit"
20         gvfsd.hook)
21 sha256sums=('SKIP'
22             'd3b714db35b2ce75d7f6d528044554decbb9149a98425aff119a071ca0a25282')
24 prepare() {
25   cd $pkgbase
28 pkgver() {
29   cd $pkgbase
30   git describe --tags | sed 's/-/+/g'
33 build() {
34   arch-meson $pkgbase build -D man=true
35   meson compile -C build
38 check() {
39   meson test -C build --print-errorlogs
42 _split() {
43   local name="$1" src dest; shift
44   for src; do
45     echo "$name: /usr/$src"
46     dest="$srcdir/$name/$src"
47     mkdir -p "${dest%/*}"
48     mv -T "$src" "$dest"
49     rmdir -p --ignore-fail-on-non-empty "${src%/*}"
50   done
53 package_gvfs() {
54   replaces=(gvfs-{obexftp,afp})
55   optdepends=('gvfs-afc: AFC (mobile devices) support'
56               'gvfs-smb: SMB/CIFS (Windows client) support'
57               'gvfs-gphoto2: gphoto2 (PTP camera/MTP media player) support'
58               'gvfs-mtp: MTP device support'
59               'gvfs-goa: gnome-online-accounts (e.g. OwnCloud) support'
60               'gvfs-nfs: NFS support'
61               'gvfs-google: Google Drive support'
62               'gtk3: Recent files support')
63   options=(!emptydirs)
65   DESTDIR="$pkgdir" meson install -C build
67   install -Dt "$pkgdir/usr/share/libalpm/hooks" -m644 *.hook
68   install -d -o root -g 102 -m 750 "$pkgdir/usr/share/polkit-1/rules.d"
70   cd "$pkgdir/usr"
72   _split smb \
73     lib/gvfsd-smb{,-browse} \
74     share/GConf/gsettings/gvfs-smb.convert \
75     share/glib-2.0/schemas/org.gnome.system.smb.gschema.xml \
76     share/gvfs/mounts/smb{,-browse}.mount
78   _split afc \
79     lib/gvfs{-afc-volume-monitor,d-afc} \
80     lib/systemd/user/gvfs-afc-volume-monitor.service \
81     share/dbus-1/services/org.gtk.vfs.AfcVolumeMonitor.service \
82     share/gvfs/mounts/afc.mount \
83     share/gvfs/remote-volume-monitors/afc.monitor
85   _split gphoto2 \
86     lib/gvfs{-gphoto2-volume-monitor,d-gphoto2} \
87     lib/systemd/user/gvfs-gphoto2-volume-monitor.service \
88     share/dbus-1/services/org.gtk.vfs.GPhoto2VolumeMonitor.service \
89     share/gvfs/mounts/gphoto2.mount \
90     share/gvfs/remote-volume-monitors/gphoto2.monitor
92   _split mtp \
93     lib/gvfs{-mtp-volume-monitor,d-mtp} \
94     lib/systemd/user/gvfs-mtp-volume-monitor.service \
95     share/dbus-1/services/org.gtk.vfs.MTPVolumeMonitor.service \
96     share/gvfs/mounts/mtp.mount \
97     share/gvfs/remote-volume-monitors/mtp.monitor
99   _split goa \
100     lib/gvfs-goa-volume-monitor \
101     lib/systemd/user/gvfs-goa-volume-monitor.service \
102     share/dbus-1/services/org.gtk.vfs.GoaVolumeMonitor.service \
103     share/gvfs/remote-volume-monitors/goa.monitor
105   _split nfs \
106     lib/gvfsd-nfs \
107     share/gvfs/mounts/nfs.mount
109   _split google \
110     lib/gvfsd-google \
111     share/gvfs/mounts/google.mount
114 package_gvfs-smb() {
115   pkgdesc+=" (SMB/CIFS backend; Windows client)"
116   depends=("gvfs=$pkgver" 'smbclient>=4.12.0')
118   mv "$srcdir/smb" "$pkgdir/usr"
121 package_gvfs-afc() {
122   pkgdesc+=" (AFC backend; Apple mobile devices)"
123   depends=("gvfs=$pkgver" libimobiledevice usbmuxd)
125   mv "$srcdir/afc" "$pkgdir/usr"
128 package_gvfs-gphoto2() {
129   pkgdesc+=" (gphoto2 backend; PTP camera, MTP media player)"
130   depends=("gvfs=$pkgver" libgphoto2)
132   mv "$srcdir/gphoto2" "$pkgdir/usr"
135 package_gvfs-mtp() {
136   pkgdesc+=" (MTP backend; Android, media player)"
137   depends=("gvfs=$pkgver" libmtp)
139   mv "$srcdir/mtp" "$pkgdir/usr"
142 package_gvfs-goa() {
143   pkgdesc+=" (Gnome Online Accounts backend; cloud storage)"
144   depends=("gvfs=$pkgver" gnome-online-accounts)
146   mv "$srcdir/goa" "$pkgdir/usr"
149 package_gvfs-nfs() {
150   pkgdesc+=" (NFS backend)"
151   depends=("gvfs=$pkgver" libnfs)
152   install=gvfs-nfs.install
154   mv "$srcdir/nfs" "$pkgdir/usr"
157 package_gvfs-google() {
158   pkgdesc+=" (Google Drive backend)"
159   depends=("gvfs-goa=$pkgver" libgdata)
161   mv "$srcdir/google" "$pkgdir/usr"
164 # vim:set sw=2 et: