Software /
code /
prosody
Annotate
configure @ 7614:bbdd97b913ea
configure: Add C compiler flag to indicate C89
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 19 Aug 2016 16:00:12 +0200 |
parent | 7613:1169097e0ef8 |
child | 7615:940603e99032 |
rev | line source |
---|---|
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
1 #!/bin/sh |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
2 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
3 # Defaults |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
4 |
7609 | 5 PREFIX="/usr/local" |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
6 SYSCONFDIR="$PREFIX/etc/prosody" |
6574
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
7 LIBDIR="$PREFIX/lib" |
502
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
8 DATADIR="$PREFIX/var/lib/prosody" |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
9 LUA_SUFFIX="" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
10 LUA_DIR="/usr" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
11 LUA_BINDIR="/usr/bin" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
12 LUA_INCDIR="/usr/include" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
13 LUA_LIBDIR="/usr/lib" |
7609 | 14 IDN_LIB="idn" |
3762
f02bac902a1e
util.encodings: Support for ICU for IDNA operations.
Tobias Markmann <tm@ayena.de>
parents:
3352
diff
changeset
|
15 ICU_FLAGS="-licui18n -licudata -licuuc" |
7609 | 16 OPENSSL_LIB="crypto" |
17 CC="gcc" | |
18 LD="gcc" | |
19 RUNWITH="lua" | |
20 EXCERTS="yes" | |
7187
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
21 PRNG= |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
22 PRNGLIBS= |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
23 |
7614
bbdd97b913ea
configure: Add C compiler flag to indicate C89
Kim Alvefur <zash@zash.se>
parents:
7613
diff
changeset
|
24 CFLAGS="-fPIC -Wall -pedantic -std=c89" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
25 LDFLAGS="-shared" |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
26 |
7609 | 27 IDN_LIBRARY="idn" |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
28 # Help |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
29 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
30 show_help() { |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
31 cat <<EOF |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
32 Configure Prosody prior to building. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
33 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
34 --help This help. |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
35 --ostype=OS Use one of the OS presets. |
6634
3e226e387a67
configure: Mention openbsd preset in --help
Kim Alvefur <zash@zash.se>
parents:
6580
diff
changeset
|
36 May be one of: debian, macosx, linux, freebsd, openbsd |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
37 --prefix=DIR Prefix where Prosody should be installed. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
38 Default is $PREFIX |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
39 --sysconfdir=DIR Location where the config file should be installed. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
40 Default is \$PREFIX/etc/prosody |
6574
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
41 --libdir=DIR Location where the server files should be stored. |
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
42 Default is \$PREFIX/lib |
502
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
43 --datadir=DIR Location where the server data should be stored. |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
44 Default is \$PREFIX/var/lib/prosody |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
45 --lua-suffix=SUFFIX Versioning suffix to use in Lua filenames. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
46 Default is "$LUA_SUFFIX" (lua$LUA_SUFFIX...) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
47 --with-lua=PREFIX Use Lua from given prefix. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
48 Default is $LUA_DIR |
5421
a3f0fe9431cf
configure: Add RUNWITH to --help
Kim Alvefur <zash@zash.se>
parents:
5401
diff
changeset
|
49 --runwith=BINARY What Lua binary to set as runtime environment. |
a3f0fe9431cf
configure: Add RUNWITH to --help
Kim Alvefur <zash@zash.se>
parents:
5401
diff
changeset
|
50 Default is $RUNWITH |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
51 --with-lua-include=DIR You can also specify Lua's includes dir. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
52 Default is \$LUA_DIR/include |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
53 --with-lua-lib=DIR You can also specify Lua's libraries dir. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
54 Default is \$LUA_DIR/lib |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
55 --with-idn=LIB The name of the IDN library to link with. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
56 Default is $IDN_LIB |
5422
396072d62695
configure: Replaces tabs with spaces in --help
Kim Alvefur <zash@zash.se>
parents:
5421
diff
changeset
|
57 --idn-library=(idn|icu) Select library to use for IDNA functionality. |
396072d62695
configure: Replaces tabs with spaces in --help
Kim Alvefur <zash@zash.se>
parents:
5421
diff
changeset
|
58 idn: use GNU libidn (default) |
396072d62695
configure: Replaces tabs with spaces in --help
Kim Alvefur <zash@zash.se>
parents:
5421
diff
changeset
|
59 icu: use ICU from IBM |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
60 --with-ssl=LIB The name of the SSL to link with. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
61 Default is $OPENSSL_LIB |
7187
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
62 --with-random=METHOD CSPRNG backend to use. One of |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
63 getrandom: Linux kernel |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
64 arc4random: OpenBSD kernel |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
65 openssl: OpenSSL RAND method |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
66 Default is to use /dev/urandom |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
67 --cflags=FLAGS Flags to pass to the compiler |
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
68 Default is $CFLAGS |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
69 --ldflags=FLAGS Flags to pass to the linker |
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
70 Default is $LDFLAGS |
798
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
71 --c-compiler=CC The C compiler to use when building modules. |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
72 Default is $CC |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
73 --linker=CC The linker to use when building modules. |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
74 Default is $LD |
4451
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
75 --require-config Will cause Prosody to refuse to run when |
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
76 it fails to find a configuration file |
5933
56b1f151f4a3
Makefile, configure: Add option for disabling generation of example certificates
Kim Alvefur <zash@zash.se>
parents:
5422
diff
changeset
|
77 --no-example-certs Disables generation of example certificates. |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
78 EOF |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
79 } |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
80 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
81 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
82 while [ "$1" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
83 do |
3050
76f0d653b347
configure: Fix to allow option values containing '=' (thanks Jakub)
Matthew Wild <mwild1@gmail.com>
parents:
1081
diff
changeset
|
84 value="`echo $1 | sed 's/[^=]*=\(.*\)/\1/'`" |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
85 if echo "$value" | grep -q "~" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
86 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
87 echo |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
88 echo '*WARNING*: the "~" sign is not expanded in flags.' |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
89 echo 'If you mean the home directory, use $HOME instead.' |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
90 echo |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
91 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
92 case "$1" in |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
93 --help) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
94 show_help |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
95 exit 0 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
96 ;; |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
97 --prefix=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
98 PREFIX="$value" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
99 PREFIX_SET=yes |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
100 ;; |
1063
b873715ffd96
configure: Honour --sysconfdir parameter; thanks to Michael Scherer
Matthew Wild <mwild1@gmail.com>
parents:
998
diff
changeset
|
101 --sysconfdir=*) |
b873715ffd96
configure: Honour --sysconfdir parameter; thanks to Michael Scherer
Matthew Wild <mwild1@gmail.com>
parents:
998
diff
changeset
|
102 SYSCONFDIR="$value" |
b873715ffd96
configure: Honour --sysconfdir parameter; thanks to Michael Scherer
Matthew Wild <mwild1@gmail.com>
parents:
998
diff
changeset
|
103 SYSCONFDIR_SET=yes |
b873715ffd96
configure: Honour --sysconfdir parameter; thanks to Michael Scherer
Matthew Wild <mwild1@gmail.com>
parents:
998
diff
changeset
|
104 ;; |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
105 --ostype=*) |
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
106 OSTYPE="$value" |
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
107 OSTYPE_SET=yes |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
108 if [ "$OSTYPE" = "debian" ]; then |
7608
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
109 if [ "$LUA_SUFFIX_SET" != "yes" ]; then |
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
110 LUA_SUFFIX="5.1"; |
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
111 LUA_SUFFIX_SET=yes |
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
112 fi |
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
113 RUNWITH="lua$LUA_SUFFIX" |
2306d261ca0a
configure: Respect Lua suffix in Debian preset if already set
Kim Alvefur <zash@zash.se>
parents:
7607
diff
changeset
|
114 LUA_INCDIR="/usr/include/lua$LUA_SUFFIX" |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
115 LUA_INCDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
116 CFLAGS="$CFLAGS -D_GNU_SOURCE" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
117 fi |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
118 if [ "$OSTYPE" = "macosx" ]; then |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
119 LUA_INCDIR=/usr/local/include; |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
120 LUA_INCDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
121 LUA_LIBDIR=/usr/local/lib |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
122 LUA_LIBDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
123 CFLAGS="$CFLAGS -mmacosx-version-min=10.3" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
124 LDFLAGS="-bundle -undefined dynamic_lookup" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
125 fi |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
126 if [ "$OSTYPE" = "linux" ]; then |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
127 LUA_INCDIR=/usr/local/include; |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
128 LUA_INCDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
129 LUA_LIBDIR=/usr/local/lib |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
130 LUA_LIBDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
131 CFLAGS="-Wall -fPIC -D_GNU_SOURCE" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
132 LDFLAGS="-shared" |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
133 fi |
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
134 if [ "$OSTYPE" = "freebsd" -o "$OSTYPE" = "openbsd" ]; then |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
135 LUA_INCDIR="/usr/local/include/lua51" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
136 LUA_INCDIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
137 CFLAGS="-Wall -fPIC -I/usr/local/include" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
138 LDFLAGS="-I/usr/local/include -L/usr/local/lib -shared" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
139 LUA_SUFFIX="-5.1" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
140 LUA_SUFFIX_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
141 LUA_DIR=/usr/local |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
142 LUA_DIR_SET=yes |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
143 CC=cc |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
144 LD=ld |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
145 fi |
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
146 if [ "$OSTYPE" = "openbsd" ]; then |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
147 LUA_INCDIR="/usr/local/include"; |
7610
8c60d7b4a0c1
configure: Indicate that LUA_INCDIR is set in openbsd preset
Kim Alvefur <zash@zash.se>
parents:
7609
diff
changeset
|
148 LUA_INCDIR_SET="yes" |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
149 fi |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
150 ;; |
6574
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
151 --libdir=*) |
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
152 LIBDIR="$value" |
6579
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
153 LIBDIR_SET=yes |
6574
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
154 ;; |
1081
d41e88b07225
configure: Change --data-dir to --datadir to make consistent with help and other dir flags
Matthew Wild <mwild1@gmail.com>
parents:
1063
diff
changeset
|
155 --datadir=*) |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
156 DATADIR="$value" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
157 DATADIR_SET=yes |
502
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
158 ;; |
4451
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
159 --require-config) |
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
160 REQUIRE_CONFIG=yes |
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
161 ;; |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
162 --lua-suffix=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
163 LUA_SUFFIX="$value" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
164 LUA_SUFFIX_SET=yes |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
165 ;; |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
166 --with-lua=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
167 LUA_DIR="$value" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
168 LUA_DIR_SET=yes |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
169 ;; |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
170 --with-lua-include=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
171 LUA_INCDIR="$value" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
172 LUA_INCDIR_SET=yes |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
173 ;; |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
174 --with-lua-lib=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
175 LUA_LIBDIR="$value" LUA_LIBDIR_SET=yes |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
176 ;; |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
177 --with-idn=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
178 IDN_LIB="$value" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
179 ;; |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
180 --idn-library=*) |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
181 IDN_LIBRARY="$value" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
182 ;; |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
183 --with-ssl=*) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
184 OPENSSL_LIB="$value" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
185 ;; |
7187
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
186 --with-random=getrandom) |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
187 PRNG=GETRANDOM |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
188 ;; |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
189 --with-random=openssl) |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
190 PRNG=OPENSSL |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
191 PRNGLIBS=-lcrypto |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
192 ;; |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
193 --with-random=arc4random) |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
194 PRNG=ARC4RANDOM |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
195 ;; |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
196 --cflags=*) |
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
197 CFLAGS="$value" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
198 ;; |
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
199 --ldflags=*) |
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
200 LDFLAGS="$value" |
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
201 ;; |
798
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
202 --c-compiler=*) |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
203 CC="$value" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
204 ;; |
798
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
205 --linker=*) |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
206 LD="$value" |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
207 ;; |
5145
53f741a5a73a
configure, Makefile: Allow runtime to be overridden.
Kim Alvefur <zash@zash.se>
parents:
5048
diff
changeset
|
208 --runwith=*) |
53f741a5a73a
configure, Makefile: Allow runtime to be overridden.
Kim Alvefur <zash@zash.se>
parents:
5048
diff
changeset
|
209 RUNWITH="$value" |
53f741a5a73a
configure, Makefile: Allow runtime to be overridden.
Kim Alvefur <zash@zash.se>
parents:
5048
diff
changeset
|
210 ;; |
5933
56b1f151f4a3
Makefile, configure: Add option for disabling generation of example certificates
Kim Alvefur <zash@zash.se>
parents:
5422
diff
changeset
|
211 --no-example-certs) |
56b1f151f4a3
Makefile, configure: Add option for disabling generation of example certificates
Kim Alvefur <zash@zash.se>
parents:
5422
diff
changeset
|
212 EXCERTS= |
56b1f151f4a3
Makefile, configure: Add option for disabling generation of example certificates
Kim Alvefur <zash@zash.se>
parents:
5422
diff
changeset
|
213 ;; |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
214 *) |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
215 echo "Error: Unknown flag: $1" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
216 exit 1 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
217 ;; |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
218 esac |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
219 shift |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
220 done |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
221 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
222 if [ "$PREFIX_SET" = "yes" -a ! "$SYSCONFDIR_SET" = "yes" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
223 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
224 if [ "$PREFIX" = "/usr" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
225 then SYSCONFDIR=/etc/prosody |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
226 else SYSCONFDIR=$PREFIX/etc/prosody |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
227 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
228 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
229 |
502
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
230 if [ "$PREFIX_SET" = "yes" -a ! "$DATADIR_SET" = "yes" ] |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
231 then |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
232 if [ "$PREFIX" = "/usr" ] |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
233 then DATADIR=/var/lib/prosody |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
234 else DATADIR=$PREFIX/var/lib/prosody |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
235 fi |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
236 fi |
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
237 |
6579
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
238 if [ "$PREFIX_SET" = "yes" -a ! "$LIBDIR_SET" = "yes" ] |
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
239 then |
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
240 LIBDIR=$PREFIX/lib |
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
241 fi |
5a82ee60e07e
configure: Fix for commit cd0088c73daf - update LIBDIR if --prefix is set and --libdir isn't (thanks Medics)
Matthew Wild <mwild1@gmail.com>
parents:
6574
diff
changeset
|
242 |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
243 find_program() { |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
244 path="$PATH" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
245 item="`echo "$path" | sed 's/\([^:]*\):.*/\1/'`" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
246 path="`echo "$path" | sed -n 's/[^:]*::*\(.*\)/\1/p'`" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
247 found="no" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
248 while [ "$item" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
249 do |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
250 if [ -f "$item/$1" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
251 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
252 found="yes" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
253 break |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
254 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
255 item="`echo "$path" | sed 's/\([^:]*\):.*/\1/'`" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
256 path="`echo "$path" | sed -n 's/[^:]*::*\(.*\)/\1/p'`" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
257 done |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
258 if [ "$found" = "yes" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
259 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
260 echo "$item" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
261 else |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
262 echo "" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
263 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
264 } |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
265 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
266 if [ "$LUA_SUFFIX_SET" != "yes" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
267 then |
467
66f145f5c932
Update Makefile to now pass config paths to prosody. Update prosody, modulemanager and connectionlisteners to obey these paths.
Matthew Wild <mwild1@gmail.com>
parents:
463
diff
changeset
|
268 for suffix in "5.1" "51" "" |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
269 do |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
270 LUA_SUFFIX="$suffix" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
271 if [ "$LUA_DIR_SET" = "yes" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
272 then |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
273 if [ -f "$LUA_DIR/bin/lua$suffix" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
274 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
275 find_lua="$LUA_DIR" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
276 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
277 else |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
278 find_lua=`find_program lua$suffix` |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
279 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
280 if [ "$find_lua" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
281 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
282 echo "Lua interpreter found: $find_lua/lua$suffix..." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
283 break |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
284 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
285 done |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
286 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
287 |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
288 if [ "$LUA_DIR_SET" != "yes" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
289 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
290 echo -n "Looking for Lua... " |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
291 if [ ! "$find_lua" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
292 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
293 find_lua=`find_program lua$LUA_SUFFIX` |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
294 echo "lua$LUA_SUFFIX found in \$PATH: $find_lua" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
295 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
296 if [ "$find_lua" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
297 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
298 LUA_DIR=`dirname $find_lua` |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
299 LUA_BINDIR="$find_lua" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
300 else |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
301 echo "lua$LUA_SUFFIX not found in \$PATH." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
302 echo "You may want to use the flags --with-lua and/or --lua-suffix. See --help." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
303 exit 1 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
304 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
305 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
306 |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
307 if [ "$LUA_INCDIR_SET" != "yes" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
308 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
309 LUA_INCDIR="$LUA_DIR/include" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
310 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
311 |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
312 if [ "$LUA_LIBDIR_SET" != "yes" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
313 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
314 LUA_LIBDIR="$LUA_DIR/lib" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
315 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
316 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
317 if [ "$LUA_DIR_SET" = "yes" ] |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
318 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
319 LUA_BINDIR="$LUA_DIR/bin" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
320 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
321 |
3762
f02bac902a1e
util.encodings: Support for ICU for IDNA operations.
Tobias Markmann <tm@ayena.de>
parents:
3352
diff
changeset
|
322 if [ "$IDN_LIBRARY" = "icu" ] |
f02bac902a1e
util.encodings: Support for ICU for IDNA operations.
Tobias Markmann <tm@ayena.de>
parents:
3352
diff
changeset
|
323 then |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
324 IDNA_LIBS="$ICU_FLAGS" |
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
325 CFLAGS="$CFLAGS -DUSE_STRINGPREP_ICU" |
3762
f02bac902a1e
util.encodings: Support for ICU for IDNA operations.
Tobias Markmann <tm@ayena.de>
parents:
3352
diff
changeset
|
326 fi |
5641
92ffddd02c96
configure: Fix poor layout
James Callahan <james@chatid.com>
parents:
5422
diff
changeset
|
327 if [ "$IDN_LIBRARY" = "idn" ] |
3764
323169f229fa
Make libidn default when not specifiying a IDN lib.
Tobias Markmann <tm@ayena.de>
parents:
3763
diff
changeset
|
328 then |
7607
d17bc0d0748e
configure: Normalize whitespace
Kim Alvefur <zash@zash.se>
parents:
7548
diff
changeset
|
329 IDNA_LIBS="-l$IDN_LIB" |
3764
323169f229fa
Make libidn default when not specifiying a IDN lib.
Tobias Markmann <tm@ayena.de>
parents:
3763
diff
changeset
|
330 fi |
323169f229fa
Make libidn default when not specifiying a IDN lib.
Tobias Markmann <tm@ayena.de>
parents:
3763
diff
changeset
|
331 |
6886
27f5a76e3fa5
configure,util-src/Makefile: Make a variable that includes -l for OpenSSL (like with IDNA_LIBS)
Kim Alvefur <zash@zash.se>
parents:
6878
diff
changeset
|
332 OPENSSL_LIBS="-l$OPENSSL_LIB" |
27f5a76e3fa5
configure,util-src/Makefile: Make a variable that includes -l for OpenSSL (like with IDNA_LIBS)
Kim Alvefur <zash@zash.se>
parents:
6878
diff
changeset
|
333 |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
334 echo -n "Checking Lua includes... " |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
335 lua_h="$LUA_INCDIR/lua.h" |
6810
533fd843d91f
configure, Makefile: Make compatible with plain Bourne shell as used on Solaris. Fixes #418 (thanks jcea)
Matthew Wild <mwild1@gmail.com>
parents:
6635
diff
changeset
|
336 if [ -f "$lua_h" ] |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
337 then |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
338 echo "lua.h found in $lua_h" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
339 else |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
340 echo "lua.h not found (looked in $lua_h)" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
341 echo "You may want to use the flag --with-lua-include. See --help." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
342 exit 1 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
343 fi |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
344 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
345 # Write config |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
346 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
347 echo "Writing configuration..." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
348 echo |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
349 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
350 cat <<EOF > config.unix |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
351 # This file was automatically generated by the configure script. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
352 # Run "./configure --help" for details. |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
353 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
354 PREFIX=$PREFIX |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
355 SYSCONFDIR=$SYSCONFDIR |
6574
cd0088c73daf
configure, Makefile: Add --libdir option to ./configure, allowing you to override the $PREFIX/lib/ default. Fixes #470.
Matthew Wild <mwild1@gmail.com>
parents:
5933
diff
changeset
|
356 LIBDIR=$LIBDIR |
502
21dc299387a6
Installation improvements (auto-creation of data directories)
Matthew Wild <mwild1@gmail.com>
parents:
467
diff
changeset
|
357 DATADIR=$DATADIR |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
358 LUA_SUFFIX=$LUA_SUFFIX |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
359 LUA_DIR=$LUA_DIR |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
360 LUA_INCDIR=$LUA_INCDIR |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
361 LUA_LIBDIR=$LUA_LIBDIR |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
362 LUA_BINDIR=$LUA_BINDIR |
4451
70275ab52ab2
configure: Add 'openbsd' preset (thanks xavier)
Matthew Wild <mwild1@gmail.com>
parents:
4444
diff
changeset
|
363 REQUIRE_CONFIG=$REQUIRE_CONFIG |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
364 IDN_LIB=$IDN_LIB |
3762
f02bac902a1e
util.encodings: Support for ICU for IDNA operations.
Tobias Markmann <tm@ayena.de>
parents:
3352
diff
changeset
|
365 IDNA_LIBS=$IDNA_LIBS |
6886
27f5a76e3fa5
configure,util-src/Makefile: Make a variable that includes -l for OpenSSL (like with IDNA_LIBS)
Kim Alvefur <zash@zash.se>
parents:
6878
diff
changeset
|
366 OPENSSL_LIBS=$OPENSSL_LIBS |
511
f9ab28562fda
Potential fixes for building on Mac OSX
Matthew Wild <mwild1@gmail.com>
parents:
502
diff
changeset
|
367 CFLAGS=$CFLAGS |
2315
174b4a83f5b7
configure: Add 'linux' ostype and rename lflags to LDFLAGS to match expectations.
Brian Cully <bjc@junctionnetworks.com>
parents:
1081
diff
changeset
|
368 LDFLAGS=$LDFLAGS |
798
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
369 CC=$CC |
2a92b58144a9
Use $CC, $LD in Makefile. Add --c-compiler, --linker flags to ./configure script. Add --lflags to ./configure script. Thanks to Lorenzo for the initial patch!
Matthew Wild <mwild1@gmail.com>
parents:
536
diff
changeset
|
370 LD=$LD |
5145
53f741a5a73a
configure, Makefile: Allow runtime to be overridden.
Kim Alvefur <zash@zash.se>
parents:
5048
diff
changeset
|
371 RUNWITH=$RUNWITH |
5933
56b1f151f4a3
Makefile, configure: Add option for disabling generation of example certificates
Kim Alvefur <zash@zash.se>
parents:
5422
diff
changeset
|
372 EXCERTS=$EXCERTS |
7187
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
373 RANDOM=$PRNG |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
374 RANDOM_LIBS=$PRNGLIBS |
3d2c2f0809ee
util.crand: C binding to one of OpenSSL, Linux getrandom() or OpenBSD arc4random() CSPRNG
Kim Alvefur <zash@zash.se>
parents:
6886
diff
changeset
|
375 |
463
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
376 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
377 EOF |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
378 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
379 echo "Installation prefix: $PREFIX" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
380 echo "Prosody configuration directory: $SYSCONFDIR" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
381 echo "Using Lua from: $LUA_DIR" |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
382 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
383 make clean > /dev/null 2> /dev/null |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
384 |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
385 echo |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
386 echo "Done. You can now run 'make' to build." |
a2452d3bd828
Add a top-level Makefile and ./configure script. Update util-src Makefile for this.
Matthew Wild <mwild1@gmail.com>
parents:
diff
changeset
|
387 echo |