diff options
author | Adam Chlipala <adam@chlipala.net> | 2011-08-04 17:06:50 -0400 |
---|---|---|
committer | Adam Chlipala <adam@chlipala.net> | 2011-08-04 17:06:50 -0400 |
commit | 64f43be321e5ad4bef303831a589e1bd415e8673 (patch) | |
tree | 982f9f5673e512568490930bf5aff4f4bca9813e /src | |
parent | 7e42ca73d84c1938c881aa103a9c5bf40a9f1bfb (diff) |
Configure correct C compiler options for Pthreads
Diffstat (limited to 'src')
-rw-r--r-- | src/c/Makefile.in | 7 | ||||
-rw-r--r-- | src/compiler.sml | 6 | ||||
-rw-r--r-- | src/config.sig | 3 | ||||
-rw-r--r-- | src/config.sml.in | 3 |
4 files changed, 15 insertions, 4 deletions
diff --git a/src/c/Makefile.in b/src/c/Makefile.in index 2c02db8d..cdcc83b0 100644 --- a/src/c/Makefile.in +++ b/src/c/Makefile.in @@ -40,7 +40,8 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_openssl.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac + $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/m4_ax_pthread.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(install_sh) -d @@ -176,6 +177,9 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PGHEADER = @PGHEADER@ PKG_CONFIG = @PKG_CONFIG@ +PTHREAD_CC = @PTHREAD_CC@ +PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ @@ -196,6 +200,7 @@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ +ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ diff --git a/src/compiler.sml b/src/compiler.sml index e47e5e2a..21ffae27 100644 --- a/src/compiler.sml +++ b/src/compiler.sml @@ -1320,12 +1320,12 @@ fun compileC {cname, oname, ename, libs, profile, debug, link = link'} = else "-L" ^ Config.lib ^ "/.. -lurweb " ^ #linkDynamic proto - val compile = Config.ccompiler ^ " " ^ Config.ccArgs ^ " -Wimplicit -Werror -Wno-unused-value -O3 -I " ^ Config.includ + val compile = Config.ccompiler ^ " " ^ Config.ccArgs ^ " " ^ Config.pthreadCflags ^ " -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.ccArgs ^ " " ^ lib ^ " " ^ Config.openssl ^ " " ^ escapeFilename oname - ^ " -o " ^ escapeFilename ename ^ " " ^ libs + val link = Config.ccompiler ^ " -Werror -O3 -lm " ^ Config.ccArgs ^ " " ^ Config.pthreadCflags ^ " " ^ Config.pthreadLibs + ^ " " ^ lib ^ " " ^ Config.openssl ^ " " ^ escapeFilename oname ^ " -o " ^ escapeFilename ename ^ " " ^ libs val (compile, link) = if profile then diff --git a/src/config.sig b/src/config.sig index 65c3926b..70548b12 100644 --- a/src/config.sig +++ b/src/config.sig @@ -18,4 +18,7 @@ signature CONFIG = sig val versionNumber : string val versionString : string + + val pthreadCflags : string + val pthreadLibs : string end diff --git a/src/config.sml.in b/src/config.sml.in index cd8d941a..1d7e450f 100644 --- a/src/config.sml.in +++ b/src/config.sml.in @@ -23,4 +23,7 @@ val sqheader = "@SQHEADER@" val versionNumber = "@VERSION@" val versionString = "The Ur/Web compiler, version " ^ versionNumber +val pthreadCflags = "@PTHREAD_CFLAGS@" +val pthreadLibs = "@PTHREAD_LIBS@" + end |