27 IDN_LIBRARY="idn" |
29 IDN_LIBRARY="idn" |
28 # Help |
30 # Help |
29 |
31 |
30 show_help() { |
32 show_help() { |
31 cat <<EOF |
33 cat <<EOF |
32 Configure Prosody prior to building. |
34 Configure $APP_NAME prior to building. |
33 |
35 |
34 --help This help. |
36 --help This help. |
35 --ostype=OS Use one of the OS presets. May be one of: |
37 --ostype=OS Use one of the OS presets. May be one of: |
36 debian, macosx, linux, freebsd, openbsd, netbsd |
38 debian, macosx, linux, freebsd, openbsd, netbsd |
37 --prefix=DIR Prefix where Prosody should be installed. |
39 --prefix=DIR Prefix where $APP_NAME should be installed. |
38 Default is $PREFIX |
40 Default is $PREFIX |
39 --sysconfdir=DIR Location where the config file should be installed. |
41 --sysconfdir=DIR Location where the config file should be installed. |
40 Default is \$PREFIX/etc/prosody |
42 Default is \$PREFIX/etc/$APP_DIRNAME |
41 --libdir=DIR Location where the server files should be stored. |
43 --libdir=DIR Location where the server files should be stored. |
42 Default is \$PREFIX/lib |
44 Default is \$PREFIX/lib |
43 --datadir=DIR Location where the server data should be stored. |
45 --datadir=DIR Location where the server data should be stored. |
44 Default is \$PREFIX/var/lib/prosody |
46 Default is \$PREFIX/var/lib/$APP_DIRNAME |
45 --lua-version=VERSION Use specific Lua version: 5.1, 5.2, or 5.3 |
47 --lua-version=VERSION Use specific Lua version: 5.1, 5.2, or 5.3 |
46 Default is auto-detected. |
48 Default is auto-detected. |
47 --lua-suffix=SUFFIX Versioning suffix to use in Lua filenames. |
49 --lua-suffix=SUFFIX Versioning suffix to use in Lua filenames. |
48 Default is "$LUA_SUFFIX" (lua$LUA_SUFFIX...) |
50 Default is "$LUA_SUFFIX" (lua$LUA_SUFFIX...) |
49 --with-lua=PREFIX Use Lua from given prefix. |
51 --with-lua=PREFIX Use Lua from given prefix. |
75 Default is $LDFLAGS |
77 Default is $LDFLAGS |
76 --c-compiler=CC The C compiler to use when building modules. |
78 --c-compiler=CC The C compiler to use when building modules. |
77 Default is $CC |
79 Default is $CC |
78 --linker=CC The linker to use when building modules. |
80 --linker=CC The linker to use when building modules. |
79 Default is $LD |
81 Default is $LD |
80 --require-config Will cause Prosody to refuse to run when |
82 --require-config Will cause $APP_NAME to refuse to run when |
81 it fails to find a configuration file |
83 it fails to find a configuration file |
82 --no-example-certs Disables generation of example certificates. |
84 --no-example-certs Disables generation of example certificates. |
83 EOF |
85 EOF |
84 } |
86 } |
85 |
87 |
323 done |
325 done |
324 |
326 |
325 if [ "$PREFIX_SET" = "yes" -a ! "$SYSCONFDIR_SET" = "yes" ] |
327 if [ "$PREFIX_SET" = "yes" -a ! "$SYSCONFDIR_SET" = "yes" ] |
326 then |
328 then |
327 if [ "$PREFIX" = "/usr" ] |
329 if [ "$PREFIX" = "/usr" ] |
328 then SYSCONFDIR=/etc/prosody |
330 then SYSCONFDIR=/etc/$APP_DIRNAME |
329 else SYSCONFDIR=$PREFIX/etc/prosody |
331 else SYSCONFDIR=$PREFIX/etc/$APP_DIRNAME |
330 fi |
332 fi |
331 fi |
333 fi |
332 |
334 |
333 if [ "$PREFIX_SET" = "yes" -a ! "$DATADIR_SET" = "yes" ] |
335 if [ "$PREFIX_SET" = "yes" -a ! "$DATADIR_SET" = "yes" ] |
334 then |
336 then |
335 if [ "$PREFIX" = "/usr" ] |
337 if [ "$PREFIX" = "/usr" ] |
336 then DATADIR=/var/lib/prosody |
338 then DATADIR=/var/lib/$APP_DIRNAME |
337 else DATADIR=$PREFIX/var/lib/prosody |
339 else DATADIR=$PREFIX/var/lib/$APP_DIRNAME |
338 fi |
340 fi |
339 fi |
341 fi |
340 |
342 |
341 if [ "$PREFIX_SET" = "yes" -a ! "$LIBDIR_SET" = "yes" ] |
343 if [ "$PREFIX_SET" = "yes" -a ! "$LIBDIR_SET" = "yes" ] |
342 then |
344 then |