desktop/dconf/dconf.sh

Fri, 15 Nov 2019 20:11:00 +0100

author
David Demelier <markand@malikania.fr>
date
Fri, 15 Nov 2019 20:11:00 +0100
changeset 1210
422313c3fcbd
parent 1115
297b5eef115e
child 1216
6710613b88b9
permissions
-rw-r--r--

text/rarian: initial import, closes #2311

1115
297b5eef115e vanilla: change shebangs to /bin/sh
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
1 #!/bin/sh
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 #
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
3 # Copyright (c) 2019 David Demelier <markand@malikania.fr>
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
4 #
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
5 # Permission to use, copy, modify, and/or distribute this software for any
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 # purpose with or without fee is hereby granted, provided that the above
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 # copyright notice and this permission notice appear in all copies.
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
8 #
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
16 #
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
17
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
18 PKGNAME=dconf
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
19 PKGVERSION=0.32.0
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
20 PKGREVISION=1
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
21 PKGLICENSE="LGPLv21"
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
22 PKGSUMMARY="configuration database system"
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
23 PKGDOWNLOAD="https://download.gnome.org/sources/$PKGNAME/0.32/$PKGNAME-$PKGVERSION.tar.xz"
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 766
diff changeset
24 PKGDEPENDS="bash-completion:build meson:build glib"
718
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
25 PKGOPTIONS="VALA"
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
26
496
089b46d20c00 desktop: convert packages to clang
David Demelier <markand@malikania.fr>
parents: 374
diff changeset
27 : ${CC:=clang}
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
28 : ${CFLAGS:=-O2}
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
29 : ${LDFLAGS:=}
718
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
30 : ${VALA:=yes}
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
31
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
32 if [ "$VALA" = "yes" ]; then
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 766
diff changeset
33 PKGDEPENDS="vala $PKGDEPENDS"
718
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
34 with_vala="-D vapi=true"
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
35 else
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
36 with_vala="-D vapi=false"
08f07e05c4ad desktop/dconf: add VALA option
David Demelier <markand@malikania.fr>
parents: 606
diff changeset
37 fi
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
38
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
39 build()
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
40 {
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
41 rm -rf $PKGNAME-$PKGVERSION
606
25cecc6dca48 vanilla: use POSIX shell and busybox tar
David Demelier <markand@malikania.fr>
parents: 519
diff changeset
42 tar xvf $PKGNAME-$PKGVERSION.tar.xz
25cecc6dca48 vanilla: use POSIX shell and busybox tar
David Demelier <markand@malikania.fr>
parents: 519
diff changeset
43 cd $PKGNAME-$PKGVERSION
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
44
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
45 # TODO: enable documentation once docbook-xml is there.
496
089b46d20c00 desktop: convert packages to clang
David Demelier <markand@malikania.fr>
parents: 374
diff changeset
46 # https://gitlab.gnome.org/GNOME/dconf/issues/47
089b46d20c00 desktop: convert packages to clang
David Demelier <markand@malikania.fr>
parents: 374
diff changeset
47 patch -p1 < ../patch-clang.patch
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
48 CC="$CC" \
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
49 CFLAGS="$CFLAGS" \
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
50 LDFLAGS="$LDFLAGS" \
766
e91fbcb3d1ef vanilla: consolidate FHS
David Demelier <markand@malikania.fr>
parents: 718
diff changeset
51 meson . build \
519
824fb5352478 desktop: use new FHS
David Demelier <markand@malikania.fr>
parents: 496
diff changeset
52 --prefix / \
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
53 --buildtype release \
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
54 --default-library shared \
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
55 -D man=false \
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
56 -D gtk_doc=false \
766
e91fbcb3d1ef vanilla: consolidate FHS
David Demelier <markand@malikania.fr>
parents: 718
diff changeset
57 $with_vala
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
58 ninja -C build
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
59 DESTDIR=$DESTDIR ninja -C build install
766
e91fbcb3d1ef vanilla: consolidate FHS
David Demelier <markand@malikania.fr>
parents: 718
diff changeset
60 sed -i -e "s|prefix=/|prefix=|" $DESTDIR/lib/pkgconfig/*.pc
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
61
606
25cecc6dca48 vanilla: use POSIX shell and busybox tar
David Demelier <markand@malikania.fr>
parents: 519
diff changeset
62 cd ..
374
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
63 rm -rf $PKGNAME-$PKGVERSION
753a7822d20c desktop/dconf: initial import, closes #1234
David Demelier <markand@malikania.fr>
parents:
diff changeset
64 }

mercurial