mail/neomutt/neomutt.sh

Fri, 30 Aug 2019 18:14:59 +0200

author
David Demelier <markand@malikania.fr>
date
Fri, 30 Aug 2019 18:14:59 +0200
changeset 1038
ff9f0c0f36bd
parent 1019
ddab65a5b3f5
child 1107
7791d3dbfecf
permissions
-rwxr-xr-x

mail/neomutt: allow SSL=yes for default implementation

1019
ddab65a5b3f5 vanilla: use /bin/busybox sh as default shell
David Demelier <markand@malikania.fr>
parents: 902
diff changeset
1 #!/bin/busybox sh
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 #
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
3 # Copyright (c) 2019 David Demelier <markand@malikania.fr>
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
4 #
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
5 # Permission to use, copy, modify, and/or distribute this software for any
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 # purpose with or without fee is hereby granted, provided that the above
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 # copyright notice and this permission notice appear in all copies.
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
8 #
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
16 #
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
17
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
18 PKGNAME=neomutt
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
19 PKGVERSION=20180716
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
20 PKGREVISION=1
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
21 PKGLICENSE="GPLv2+"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
22 PKGSUMMARY="mutt fork with more features"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
23 PKGDOWNLOAD="https://github.com/neomutt/neomutt/archive/$PKGNAME-$PKGVERSION.tar.gz"
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 831
diff changeset
24 PKGDEPENDS="gettext tcl:build ncurses libxslt:build www/w3m:build"
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
25 PKGOPTIONS="IDN2 NLS NOTMUCH SSL"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
26 PKGPROTECT="etc/neomuttrc"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
27
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
28 : ${CHOST:=$(uname -m)-linux-musl}
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
29 : ${CBUILD:=$(uname -m)-linux-musl}
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
30 : ${CC:=clang}
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
31 : ${CFLAGS:=-O2}
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
32 : ${LDFLAGS:=}
1038
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
33 : ${IDN2:=yes}
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
34 : ${NLS:=yes}
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
35 : ${NOTMUCH:=no}
1038
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
36 : ${SSL:=libressl} # Note: can be libressl (or yes) or gnutls.
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
37
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
38 if [ "$IDN2" = "yes" ]; then
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 831
diff changeset
39 PKGDEPENDS="libidn2 $PKGDEPENDS"
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
40 with_idn2="--disable-idn --idn2"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
41 fi
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
42
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
43 if [ "$NLS" != "yes" ]; then
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
44 with_nls="--disable-nls"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
45 fi
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
46
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
47 if [ "$NOTMUCH" = "yes" ]; then
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
48 with_notmuch="--notmuch"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
49 fi
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
50
1038
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
51 case $SSL in
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
52 "yes"|"libressl")
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 831
diff changeset
53 PKGDEPENDS="libressl $PKGDEPENDS"
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
54 with_ssl="--ssl"
1038
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
55 ;;
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
56 "gnutls")
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 831
diff changeset
57 PKGDEPENDS="gnutls $PKGDEPENDS"
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
58 with_ssl="--gnutls"
1038
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
59 ;;
ff9f0c0f36bd mail/neomutt: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
60 esac
622
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
61
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
62 build()
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
63 {
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
64 rm -rf $PKGNAME-$PKGVERSION
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
65 tar xvf $PKGNAME-$PKGVERSION.tar.gz
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
66 cd $PKGNAME-$PKGNAME-$PKGVERSION
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
67
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
68 ./configure \
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
69 --prefix= \
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
70 $with_idn2 \
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
71 $with_nls \
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
72 $with_notmuch \
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
73 $with_ssl
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
74 make CC="$CC" EXTRA_CFLAGS="$CFLAGS" EXTRA_LDFLAGS="$LDFLAGS"
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
75 make install DESTDIR=$DESTDIR
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
76
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
77 cd ..
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
78 rm -rf $PKGNAME-$PKGNAME-$PKGVERSION
e04beece0bd7 mail/neomutt: initial import, closes #1698
David Demelier <markand@malikania.fr>
parents:
diff changeset
79 }

mercurial