bin/setup-neomutt

Sat, 24 Apr 2021 19:51:12 -0500

author
Meredith Howard <mhoward@roomag.org>
date
Sat, 24 Apr 2021 19:51:12 -0500
changeset 897
760d4f0ca87b
parent 715
e5da1bdb72b6
permissions
-rwxr-xr-x

Keep maps together

290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
1 #!/bin/sh
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
2 set -eu
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
3
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
4 case ${1:-} in *help|-h)
446
acd0b08d467e skip pager for tiny perldocs
Meredith Howard <mhoward@roomag.org>
parents: 437
diff changeset
5 exec perldoc -T $0;;
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
6 esac
312
2f0459c97d3e add build notes
Meredith Howard <mhoward@roomag.org>
parents: 311
diff changeset
7
290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
8 cd
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
9 mkdir -p sandbox
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
10
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
11 if [ ! -d sandbox/neomutt ]; then
482
2c7cb331d2dc Don't really need full clones
Meredith Howard <mhoward@roomag.org>
parents: 446
diff changeset
12 git clone --depth 1 https://github.com/neomutt/neomutt.git sandbox/neomutt
290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
13 else
596
8de875515620 Update for current neomutt
Meredith Howard <mhoward@roomag.org>
parents: 569
diff changeset
14 make -C sandbox/neomutt clean >/dev/null 2>&1 || true
290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
15 git -C sandbox/neomutt pull
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
16 fi
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
17
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
18 cd sandbox/neomutt
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
19
664
66ba2d649859 cleanup
Meredith Howard <mhoward@roomag.org>
parents: 663
diff changeset
20 case "$(uname -s)" in
596
8de875515620 Update for current neomutt
Meredith Howard <mhoward@roomag.org>
parents: 569
diff changeset
21 Darwin)
663
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
22 CONFIGURE_OPTIONS='--with-ssl=/opt/local --with-gpgme=/opt/local'
715
e5da1bdb72b6 Suddenly required this to build again
Meredith Howard <mhoward@roomag.org>
parents: 713
diff changeset
23 export EXTRA_CFLAGS="-iquote $(pwd)"
569
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
24 ;;
664
66ba2d649859 cleanup
Meredith Howard <mhoward@roomag.org>
parents: 663
diff changeset
25 *)
66ba2d649859 cleanup
Meredith Howard <mhoward@roomag.org>
parents: 663
diff changeset
26 CONFIGURE_OPTIONS=''
66ba2d649859 cleanup
Meredith Howard <mhoward@roomag.org>
parents: 663
diff changeset
27 ;;
388
50ed49b3d1dc Update for osx 10.11
Meredith Howard <mhoward@roomag.org>
parents: 366
diff changeset
28 esac
50ed49b3d1dc Update for osx 10.11
Meredith Howard <mhoward@roomag.org>
parents: 366
diff changeset
29
663
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
30 autoreconf -i --force || true
596
8de875515620 Update for current neomutt
Meredith Howard <mhoward@roomag.org>
parents: 569
diff changeset
31
663
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
32 ./configure \
709
1ee07b0bb607 update mailpath
Meredith Howard <mhoward@roomag.org>
parents: 664
diff changeset
33 --with-mailpath=/var/mail \
663
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
34 --ssl \
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
35 --sasl \
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
36 --lmdb \
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
37 --gpgme \
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
38 $CONFIGURE_OPTIONS \
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
39 --disable-doc
293
7df7f79939f0 drop hcache, make default
Meredith Howard <mhoward@roomag.org>
parents: 291
diff changeset
40
321
12d8f50e80a9 fix deps
Meredith Howard <mhoward@roomag.org>
parents: 318
diff changeset
41 make -s -j3
290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
42
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
43 cd ~/bin
713
650ca91e3197 copy binaries in case build fails
Meredith Howard <mhoward@roomag.org>
parents: 709
diff changeset
44 for BIN in neomutt pgpewrap; do
650ca91e3197 copy binaries in case build fails
Meredith Howard <mhoward@roomag.org>
parents: 709
diff changeset
45 cp ../sandbox/neomutt/$BIN .
364
dc8ef0de424d tweak neomutt build
Meredith Howard <mhoward@roomag.org>
parents: 359
diff changeset
46 done
713
650ca91e3197 copy binaries in case build fails
Meredith Howard <mhoward@roomag.org>
parents: 709
diff changeset
47 ln -sf neomutt mutt
290
6a140c2e1366 add build-neomutt
Meredith Howard <mhoward@roomag.org>
parents:
diff changeset
48
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
49 :<<=cut
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
50 =head1 NAME
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
51
446
acd0b08d467e skip pager for tiny perldocs
Meredith Howard <mhoward@roomag.org>
parents: 437
diff changeset
52 setup-neomutt - Clone/update and build neomutt
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
53
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
54 =head1 DESCRIPTION
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
55
713
650ca91e3197 copy binaries in case build fails
Meredith Howard <mhoward@roomag.org>
parents: 709
diff changeset
56 Run to do the above, incl. copying binaries into C<~/bin> after the neomutt
650ca91e3197 copy binaries in case build fails
Meredith Howard <mhoward@roomag.org>
parents: 709
diff changeset
57 build.
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
58
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
59 =head1 REQUIREMENTS
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
60
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
61 =head2 Debian
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
62
558
2ee5e91dbf58 add pandoc
Meredith Howard <mhoward@roomag.org>
parents: 546
diff changeset
63 apt install autoconf links pandoc gnupg2 gpgsm urlscan libncursesw5-dev \
663
0f2e760661e8 update build-neomutt
Meredith Howard <mhoward@roomag.org>
parents: 645
diff changeset
64 libssl-dev libsasl2-dev liblmdb-dev libgpgme11-dev
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
65
569
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
66 =head2 Cygwin / Babun
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
67
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
68 pact install autoconf links libncursesw-devel openssl-devel libsasl2-devel \
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
69 liblmdb-devel libgpgme-devel
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
70
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
71 gpg2 isn't available in cygwin, but there is a windows build. using it with
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
72 cygwin paths requires a wrapper though.
0190a692645c tweak for cygwin again
Meredith Howard <mhoward@roomag.org>
parents: 558
diff changeset
73
366
8d2d058ea98b fixup and doc for cygwin/babun
Meredith Howard <mhoward@roomag.org>
parents: 364
diff changeset
74 =cut

mercurial