Permalink
Browse files

add --disable-sendfile option to configure, fix src/Makefile to clean…

… yaws_configure.hrl

git-svn-id: https://erlyaws.svn.sourceforge.net/svnroot/erlyaws/trunk/yaws@1375 9fbdc01b-0d2c-0410-bfb7-fb27d70d8b52
  • Loading branch information...
1 parent 0426e49 commit cd68727307a4ba96dc83edf3a5339e5fed386245 @vinoski vinoski committed Jan 29, 2009
Showing with 19 additions and 8 deletions.
  1. +12 −3 configure
  2. +5 −3 configure.in
  3. +2 −2 src/Makefile
View
@@ -1261,13 +1261,16 @@ if test -n "$ac_init_help"; then
Optional Features:
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
---disable-pam disables pam auth
+ --disable-pam disables pam auth
+ --disable-sendfile disables use of sendfile system call
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-defaultcharset=String specify default charset, i.e UTF-8
- --with-extrainclude= dir to include if e.g. pam is installed in some odd place
+ --with-defaultcharset=String
+ specify default charset, i.e UTF-8
+ --with-extrainclude=DIR dir to include if e.g. pam is installed in some odd
+ place
Some influential environment variables:
CC C compiler command
@@ -1940,6 +1943,7 @@ ERLBINDIR=`dirname "$ERL"` ; ERLBINDIR=`dirname "$ERLBINDIR"`/lib/erlang/bin
+
# Check whether --with-default-charset was given.
if test "${with_default_charset+set}" = set; then
withval=$with_default_charset;
@@ -3949,6 +3953,11 @@ echo "$as_me: error: Non-supported target OS!" >&2;}
;;
esac
+# Check whether --enable-sendfile was given.
+if test "${enable_sendfile+set}" = set; then
+ enableval=$enable_sendfile; test "$enableval" = no && HAVE_SENDFILE=false
+fi
+
YTOP=`pwd`
View
@@ -18,7 +18,7 @@ AC_SUBST(ERLC)
AC_SUBST(ERLBINDIR)
AC_ARG_WITH(default-charset,
-[ --with-defaultcharset=String specify default charset, i.e UTF-8 ])
+AS_HELP_STRING([--with-defaultcharset=String], [specify default charset, i.e UTF-8]))
if test "x$with_defaultcharset" = "x" ; then
@@ -32,7 +32,7 @@ AC_SUBST(DEFAULT_CHARSET)
AC_ARG_WITH(extrainclude,
-[ --with-extrainclude= dir to include if e.g. pam is installed in some odd place ])
+AS_HELP_STRING([--with-extrainclude=DIR], [dir to include if e.g. pam is installed in some odd place]))
if test "x$with_extrainclude" = "x" ; then
@@ -45,7 +45,7 @@ AC_SUBST(EXTRAINCLUDE)
-AC_ARG_ENABLE(pam, [--disable-pam disables pam auth], EPAM=, EPAM=../priv/epam)
+AC_ARG_ENABLE(pam, AS_HELP_STRING([--disable-pam], [disables pam auth]), EPAM=, EPAM=../priv/epam)
AC_SUBST(EPAM)
@@ -260,6 +260,8 @@ case "$target_os" in
;;
esac
+AC_ARG_ENABLE(sendfile, AS_HELP_STRING([--disable-sendfile], [disables use of sendfile system call]),
+ [ test "$enableval" = no && HAVE_SENDFILE=false ])
AC_SUBST(HAVE_SENDFILE)
YTOP=`pwd`
AC_SUBST(YTOP)
View
@@ -67,7 +67,7 @@ yaws_generated.erl: yaws_generated.template ../vsn.mk
../scripts/Subst %localinstall% true | \
../scripts/Subst %ETCDIR% ${ETCDIR} > yaws_generated.erl
-yaws_configure.hrl: ../vsn.mk
+yaws_configure.hrl: ../vsn.mk ../include.mk
set -x; \
if [ $(HAVE_SENDFILE) = "true" ]; then \
echo "-define(HAVE_SENDFILE, true)." > yaws_configure.hrl; \
@@ -95,7 +95,7 @@ debug:
$(MAKE) TYPE=debug
clean:
- rm -f $(EBIN_FILES) yaws_generated.erl charset.def mime_types.erl
+ rm -f $(EBIN_FILES) yaws_generated.erl charset.def mime_types.erl yaws_configure.hrl
install: regen all docsinstall
$(INSTALL) -d $(DESTDIR)$(PREFIX)/lib/yaws/examples/ebin

0 comments on commit cd68727

Please sign in to comment.