summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG3
-rw-r--r--Makefile.in2
-rwxr-xr-xconfigure4
-rw-r--r--configure.ac4
-rw-r--r--doc/manual.tex12
-rw-r--r--src/c/Makefile.in2
-rw-r--r--src/compiler.sml4
-rw-r--r--src/config.sig2
-rw-r--r--src/config.sml.in2
9 files changed, 19 insertions, 16 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 2cd13f96..0e677365 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -5,6 +5,9 @@ Next
- Start of official tutorial
- Compiler support for generating nice tutorial HTML from literate source files
- New protocol 'static' for generating static pages
+- Replace GCCARGS configure variable with CCARGS
+- Applications consult URWEB_STACK_SIZE environment variable to determine thread
+ stack size
- Bug fixes
========
diff --git a/Makefile.in b/Makefile.in
index c34449d5..71a21371 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -113,6 +113,7 @@ AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
BIN := @BIN@
CC = @CC@
+CCARGS = @CCARGS@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
@@ -129,7 +130,6 @@ ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
-GCCARGS = @GCCARGS@
GREP = @GREP@
INCLUDE := @INCLUDE@
INSTALL = @INSTALL@
diff --git a/configure b/configure
index 75c5110f..cd01a3b6 100755
--- a/configure
+++ b/configure
@@ -615,7 +615,7 @@ LIBOBJS
SQHEADER
MSHEADER
PGHEADER
-GCCARGS
+CCARGS
SITELISP
INCLUDE
LIB
@@ -14578,7 +14578,7 @@ Ur/Web configuration:
include directory: INCLUDE $INCLUDE
site-lisp directory: SITELISP $SITELISP
C compiler: CC $CC
- Extra GCC args: GCCARGS $GCCARGS
+ Extra CC args: CCARGS $CCARGS
Postgres C header: PGHEADER $PGHEADER
MySQL C header: MSHEADER $MSHEADER
SQLite C header: SQHEADER $SQHEADER
diff --git a/configure.ac b/configure.ac
index 2cd5f2da..a4563564 100644
--- a/configure.ac
+++ b/configure.ac
@@ -89,7 +89,7 @@ AC_SUBST(BIN)
AC_SUBST(LIB)
AC_SUBST(INCLUDE)
AC_SUBST(SITELISP)
-AC_SUBST(GCCARGS)
+AC_SUBST(CCARGS)
AC_SUBST(PGHEADER)
AC_SUBST(MSHEADER)
AC_SUBST(SQHEADER)
@@ -111,7 +111,7 @@ Ur/Web configuration:
include directory: INCLUDE $INCLUDE
site-lisp directory: SITELISP $SITELISP
C compiler: CC $CC
- Extra GCC args: GCCARGS $GCCARGS
+ Extra CC args: CCARGS $CCARGS
Postgres C header: PGHEADER $PGHEADER
MySQL C header: MSHEADER $MSHEADER
SQLite C header: SQHEADER $SQHEADER
diff --git a/doc/manual.tex b/doc/manual.tex
index 6691876d..53e1eb8c 100644
--- a/doc/manual.tex
+++ b/doc/manual.tex
@@ -56,7 +56,7 @@ make
sudo make install
\end{verbatim}
-Some other packages must be installed for the above to work. At a minimum, you need a standard UNIX shell, with standard UNIX tools like sed and GCC in your execution path; MLton, the whole-program optimizing compiler for Standard ML; and the development files for the OpenSSL C library. As of this writing, in the ``testing'' version of Debian Linux, this command will install the more uncommon of these dependencies:
+Some other packages must be installed for the above to work. At a minimum, you need a standard UNIX shell, with standard UNIX tools like sed and GCC (or an alternate C compiler) in your execution path; MLton, the whole-program optimizing compiler for Standard ML; and the development files for the OpenSSL C library. As of this writing, in the ``testing'' version of Debian Linux, this command will install the more uncommon of these dependencies:
\begin{verbatim}
apt-get install mlton libssl-dev
\end{verbatim}
@@ -87,13 +87,13 @@ apt-get install emacs-goodies-el
If you don't want to install the Emacs mode, run \texttt{./configure} with the argument \texttt{--without-emacs}.
-Even with the right packages installed, configuration and building might fail to work. After you run \texttt{./configure}, you will see the values of some named environment variables printed. You may need to adjust these values to get proper installation for your system. To change a value, store your preferred alternative in the corresponding UNIX environment variable, before running \texttt{./configure}. For instance, here is how to change the list of extra arguments that the Ur/Web compiler will pass to GCC on every invocation. Some older GCC versions need this setting to mask a bug in function inlining.
+Even with the right packages installed, configuration and building might fail to work. After you run \texttt{./configure}, you will see the values of some named environment variables printed. You may need to adjust these values to get proper installation for your system. To change a value, store your preferred alternative in the corresponding UNIX environment variable, before running \texttt{./configure}. For instance, here is how to change the list of extra arguments that the Ur/Web compiler will pass to the C compiler and linker on every invocation. Some older GCC versions need this setting to mask a bug in function inlining.
\begin{verbatim}
-GCCARGS=-fno-inline ./configure
+CCARGS=-fno-inline ./configure
\end{verbatim}
-Since the author is still getting a handle on the GNU Autotools that provide the build system, you may need to do some further work to get started, especially in environments with significant differences from Linux (where most testing is done). The variables \texttt{PGHEADER}, \texttt{MSHEADER}, and \texttt{SQHEADER} may be used to set the proper C header files to include for the development libraries of PostgreSQL, MySQL, and SQLite, respectively. To get libpq to link, one OS X user reported setting \texttt{GCCARGS="-I/opt/local/include -L/opt/local/lib/postgresql84"}, after creating a symbolic link with \texttt{ln -s /opt/local/include/postgresql84 /opt/local/include/postgresql}.
+Since the author is still getting a handle on the GNU Autotools that provide the build system, you may need to do some further work to get started, especially in environments with significant differences from Linux (where most testing is done). The variables \texttt{PGHEADER}, \texttt{MSHEADER}, and \texttt{SQHEADER} may be used to set the proper C header files to include for the development libraries of PostgreSQL, MySQL, and SQLite, respectively. To get libpq to link, one OS X user reported setting \texttt{CCARGS="-I/opt/local/include -L/opt/local/lib/postgresql84"}, after creating a symbolic link with \texttt{ln -s /opt/local/include/postgresql84 /opt/local/include/postgresql}.
The Emacs mode can be set to autoload by adding the following to your \texttt{.emacs} file.
@@ -163,7 +163,7 @@ Here is the complete list of directive forms. ``FFI'' stands for ``foreign func
\item \texttt{time}: maximum running time of a single page request, in units of approximately 0.1 seconds
\item \texttt{transactionals}: maximum number of custom transactional actions (e.g., sending an e-mail) that may be run in a single page generation
\end{itemize}
-\item \texttt{link FILENAME} adds \texttt{FILENAME} to the list of files to be passed to the GCC linker at the end of compilation. This is most useful for importing extra libraries needed by new FFI modules.
+\item \texttt{link FILENAME} adds \texttt{FILENAME} to the list of files to be passed to the linker at the end of compilation. This is most useful for importing extra libraries needed by new FFI modules.
\item \texttt{minHeap NUMBYTES} sets the initial size for thread-local heaps used in handling requests. These heaps grow automatically as needed (up to any maximum set with \texttt{limit}), but each regrow requires restarting the request handling process.
\item \texttt{noXsrfProtection URIPREFIX} turns off automatic cross-site request forgery protection for the page handler identified by the given URI prefix. This will avoid checking cryptographic signatures on cookies, which is generally a reasonable idea for some pages, such as login pages that are going to discard all old cookie values, anyway.
\item \texttt{onError Module.var} changes the handling of fatal application errors. Instead of displaying a default, ugly error 500 page, the error page will be generated by calling function \texttt{Module.var} on a piece of XML representing the error message. The error handler should have type $\mt{xbody} \to \mt{transaction} \; \mt{page}$. Note that the error handler \emph{cannot} be in the application's main module, since that would register it as explicitly callable via URLs.
@@ -2382,7 +2382,7 @@ The program is translated to what is more or less a subset of C. If any use of
\subsection{C Compilation and Linking}
-The output of the last phase is pretty-printed as C source code and passed to GCC.
+The output of the last phase is pretty-printed as C source code and passed to the C compiler.
\end{document} \ No newline at end of file
diff --git a/src/c/Makefile.in b/src/c/Makefile.in
index 4b567a16..2c02db8d 100644
--- a/src/c/Makefile.in
+++ b/src/c/Makefile.in
@@ -117,6 +117,7 @@ AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
BIN = @BIN@
CC = @CC@
+CCARGS = @CCARGS@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
@@ -133,7 +134,6 @@ ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
-GCCARGS = @GCCARGS@
GREP = @GREP@
INCLUDE = @INCLUDE@
INSTALL = @INSTALL@
diff --git a/src/compiler.sml b/src/compiler.sml
index f12bcbfe..e47e5e2a 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -1320,11 +1320,11 @@ fun compileC {cname, oname, ename, libs, profile, debug, link = link'} =
else
"-L" ^ Config.lib ^ "/.. -lurweb " ^ #linkDynamic proto
- val compile = Config.ccompiler ^ " " ^ Config.gccArgs ^ " -Wimplicit -Werror -Wno-unused-value -O3 -I " ^ Config.includ
+ val compile = Config.ccompiler ^ " " ^ Config.ccArgs ^ " -Wimplicit -Werror -Wno-unused-value -O3 -I " ^ Config.includ
^ " " ^ #compile proto
^ " -c " ^ escapeFilename cname ^ " -o " ^ escapeFilename oname
- val link = Config.ccompiler ^ " -Werror -O3 -lm -pthread " ^ Config.gccArgs ^ " " ^ lib ^ " " ^ Config.openssl ^ " " ^ escapeFilename oname
+ val link = Config.ccompiler ^ " -Werror -O3 -lm -pthread " ^ Config.ccArgs ^ " " ^ lib ^ " " ^ Config.openssl ^ " " ^ escapeFilename oname
^ " -o " ^ escapeFilename ename ^ " " ^ libs
val (compile, link) =
diff --git a/src/config.sig b/src/config.sig
index 98455a3c..65c3926b 100644
--- a/src/config.sig
+++ b/src/config.sig
@@ -9,7 +9,7 @@ signature CONFIG = sig
val libJs : string
val ccompiler : string
- val gccArgs : string
+ val ccArgs : string
val openssl : string
val pgheader : string
diff --git a/src/config.sml.in b/src/config.sml.in
index bb5648c9..cd8d941a 100644
--- a/src/config.sml.in
+++ b/src/config.sml.in
@@ -13,7 +13,7 @@ val libJs = OS.Path.joinDirFile {dir = lib,
file = "js"}
val ccompiler = "@CC@"
-val gccArgs = "@GCCARGS@"
+val ccArgs = "@CCARGS@"
val openssl = "@OPENSSL_LDFLAGS@ @OPENSSL_LIBS@"
val pgheader = "@PGHEADER@"