diff options
-rw-r--r-- | m4/mod_ftpd_providers.m4 | 96 |
1 files changed, 0 insertions, 96 deletions
diff --git a/m4/mod_ftpd_providers.m4 b/m4/mod_ftpd_providers.m4 deleted file mode 100644 index e018666..0000000 --- a/m4/mod_ftpd_providers.m4 +++ /dev/null | |||
@@ -1,96 +0,0 @@ | |||
1 | dnl This file is Copyright 2003,2004 Edward Rudd | ||
2 | dnl Usage, modification, and distribution of this file in other projects is | ||
3 | dnl allowed and encouraged so long as this copyright notice is retained. | ||
4 | dnl You are encouraged to send any patches to the me at | ||
5 | dnl urkle <at> outoforder <dot> cc, but this is not a requirement | ||
6 | |||
7 | dnl | ||
8 | dnl MOD_FTPD_OUTPUT(file) | ||
9 | dnl adds "file" to the list of files generated by AC_OUPUT | ||
10 | AC_DEFUN([MOD_FTP_OUTPUT], [ | ||
11 | MOD_FTPD_OUTPUT_FILES="$MOD_FTPD_OUTPUT_FILES $1" | ||
12 | ])dnl | ||
13 | |||
14 | dnl | ||
15 | dnl MOD_FTPD_PROVIDER(name, helptext[, default[, config]]]]) | ||
16 | dnl default is one of: | ||
17 | dnl yes -- enabled by default. user must explicitly disable. | ||
18 | dnl no -- disabled under default, most, all. user must explicitly enable. | ||
19 | dnl most -- disabled by default. enabled explicitly or with most or all. | ||
20 | dnl "" -- disabled under default, most. enabled explicitly or with all. | ||
21 | dnl | ||
22 | dnl basically: yes/no is a hard setting. "most" means follow the "most" | ||
23 | dnl setting. otherwise, fall under the "all" setting. | ||
24 | dnl explicit yes/no always overrides. | ||
25 | dnl | ||
26 | AC_DEFUN([MOD_FTPD_PROVIDER],[ | ||
27 | AC_MSG_CHECKING(whether to enable mod_ftpd_$1) | ||
28 | define([optname],[--]ifelse($3,yes,disable,enable)[-]translit($1,_,-))dnl | ||
29 | AC_ARG_ENABLE(translit($1,_,-),AC_HELP_STRING(optname(),$2),,enable_$1=ifelse($3,,maybe-all,$3)) | ||
30 | undefine([optname])dnl | ||
31 | _apmod_extra_msg="" | ||
32 | |||
33 | if test "$provider_selection" = "most" -a "$enable_$1" = "most"; then | ||
34 | _apmod_error_fatal=no | ||
35 | else | ||
36 | _apmod_error_fatal=yes | ||
37 | fi | ||
38 | |||
39 | if test "$enable_$1" = "yes"; then | ||
40 | _apmod_extra_msg=" ($provider_selection)" | ||
41 | elif test "$enable_$1" = "most"; then | ||
42 | if test "$provider_selection" = "most" -o "$provider_selection" = "all"; then | ||
43 | enable_$1=yes | ||
44 | _apmod_extra_msg=" ($provider_selection)" | ||
45 | elif test "$enable_$1" != "yes"; then | ||
46 | enable_$1=no | ||
47 | fi | ||
48 | elif test "$enable_$1" = "maybe-all"; then | ||
49 | if test "$provider_selection" = "all"; then | ||
50 | enable_$1=yes | ||
51 | _apmod_extra_msg=" (all)" | ||
52 | else | ||
53 | enable_$1=no | ||
54 | fi | ||
55 | fi | ||
56 | if test "$enable_$1" != "no"; then | ||
57 | ifelse([$4],,:,[AC_MSG_RESULT([checking dependencies]) | ||
58 | $4 | ||
59 | AC_MSG_CHECKING(whether to enable mod_$1) | ||
60 | if test "$enable_$1" = "no"; then | ||
61 | if test "$_apmod_error_fatal" = "no"; then | ||
62 | _apmod_extra_msg=" (disabled)" | ||
63 | else | ||
64 | AC_MSG_ERROR([mod_ftpd_$1 has been requested by can not be build due to prerequisite failure]) | ||
65 | fi | ||
66 | fi]) | ||
67 | fi | ||
68 | AC_MSG_RESULT($enable_$1$_apmod_extra_msg) | ||
69 | if test "$enable_$1" != "no"; then | ||
70 | PROVIDER_LIST="$PROVIDER_LIST $provider_dir/$1" | ||
71 | fi | ||
72 | ])dnl | ||
73 | |||
74 | dnl | ||
75 | dnl MOD_FTPD_INCLUDE_PROVIDERS(directory) | ||
76 | dnl searches directory for mod_ftpd provider config.m4 files | ||
77 | dnl | ||
78 | AC_DEFUN([MOD_FTPD_INCLUDE_PROVIDERS],[ | ||
79 | AC_ARG_ENABLE(providers, | ||
80 | AC_HELP_STRING([--enable-providers=PROVIDER-LIST],[Providers to enable]),[ | ||
81 | for i in $enableval; do | ||
82 | if test "$i" = "all" -o "$i" = "most"; then | ||
83 | provider_selection=$i | ||
84 | else | ||
85 | eval "enable_$i=yes" | ||
86 | fi | ||
87 | done | ||
88 | ], | ||
89 | provider_selection=most | ||
90 | ) | ||
91 | |||
92 | provider_dir=$1 | ||
93 | esyscmd(./config-stubs $provider_dir) | ||
94 | |||
95 | AC_CONFIG_SUBDIRS($PROVIDER_LIST) | ||
96 | ])dnl | ||