Skip to content

Commit

Permalink
add --disable-sendfile option to configure, fix src/Makefile to clean…
Browse files Browse the repository at this point in the history
… yaws_configure.hrl

git-svn-id: https://erlyaws.svn.sourceforge.net/svnroot/erlyaws/trunk/yaws@1375 9fbdc01b-0d2c-0410-bfb7-fb27d70d8b52
  • Loading branch information
vinoski committed Jan 29, 2009
1 parent 0426e49 commit cd68727
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 8 deletions.
15 changes: 12 additions & 3 deletions configure
Expand Up @@ -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
Expand Down Expand Up @@ -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;
Expand Down Expand Up @@ -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`
Expand Down
8 changes: 5 additions & 3 deletions configure.in
Expand Up @@ -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
Expand All @@ -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
Expand All @@ -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)


Expand Down Expand Up @@ -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)
Expand Down
4 changes: 2 additions & 2 deletions src/Makefile
Expand Up @@ -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; \
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit cd68727

Please sign in to comment.