summaryrefslogtreecommitdiff
path: root/autogen
blob: 1df7898293d657ac994cd54b4cabd6623e1957c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/sh -e
#**************************************************************************
#*                                                                        *
#*                                 OCaml                                  *
#*                                                                        *
#*                David Allsopp, MetaStack Solutions Ltd.                 *
#*                                                                        *
#*   Copyright 2019 MetaStack Solutions Ltd.                              *
#*                                                                        *
#*   All rights reserved.  This file is distributed under the terms of    *
#*   the GNU Lesser General Public License version 2.1, with the          *
#*   special exception on linking described in the file LICENSE.          *
#*                                                                        *
#**************************************************************************

autoconf --force --warnings=all,error
# Some distros have the 2013 --runstatedir patch to autoconf (see
# http://git.savannah.gnu.org/cgit/autoconf.git/commit/?id=a197431414088a417b407b9b20583b2e8f7363bd
# in the GNU autoconf repo), and some don't, so ensure its effects are
# removed for CI consistency...
# POSIX Notes
#  - sed -i without a backup file is not portable, hence configure.tmp
#  - GNU sed's /../,+8d becomes /../{N;..;d;} (and the last ; is important)
sed -e '/^runstatedir/d' \
    -e '/-runstatedir /{N;N;N;N;N;N;N;N;d;}' \
    -e '/--runstatedir=DIR/d' \
    -e 's/ runstatedir//' configure > configure.tmp
mv -f configure.tmp configure
chmod +x configure