summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.travis.yml27
-rw-r--r--README.md2
-rw-r--r--include/urweb/types_cpp.h7
-rw-r--r--src/c/urweb.c7
4 files changed, 35 insertions, 8 deletions
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 00000000..ead1ad85
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,27 @@
+language: c
+
+os:
+ - linux
+ - osx
+
+compiler:
+ - clang
+ - gcc
+
+# when https://github.com/travis-ci/apt-package-whitelist/issues/792 is closed, use the container-based infrastructure
+#sudo: false
+#addons:
+# apt:
+# packages:
+# - mlton
+
+before_install:
+ - export CONFIGURE_ARGS=""
+ - if command -v apt-get &>/dev/null; then sudo apt-get update -qq; fi
+ - if command -v apt-get &>/dev/null; then sudo apt-get install -y mlton; fi
+ - if command -v brew &>/dev/null; then brew update; fi
+ - if command -v brew &>/dev/null; then brew tap homebrew/boneyard; fi
+ - if command -v brew &>/dev/null; then brew install openssl mlton; fi
+ - if command -v brew &>/dev/null; then export CONFIGURE_ARGS="--with-openssl=/usr/local/opt/openssl"; fi
+
+script: ./autogen.sh && ./configure $CONFIGURE_ARGS && make && make test
diff --git a/README.md b/README.md
index af4201bc..3bfd94a1 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,5 @@
+[![Build Status](https://api.travis-ci.org/urweb/urweb.png?branch=master)](https://travis-ci.org/urweb/urweb)
+
# The Ur/Web Programming Language
Implementation of a domain-specific functional programming language for web applications. Please see [the Ur/Web project web site](http://www.impredicative.com/ur/) for much more information! Here's a summary:
diff --git a/include/urweb/types_cpp.h b/include/urweb/types_cpp.h
index ce0f2825..77e4c611 100644
--- a/include/urweb/types_cpp.h
+++ b/include/urweb/types_cpp.h
@@ -130,7 +130,12 @@ typedef struct uw_Sqlcache_Value {
unsigned long timeValid;
} uw_Sqlcache_Value;
-typedef struct uw_Sqlcache_Entry uw_Sqlcache_Entry;
+typedef struct uw_Sqlcache_Entry {
+ char *key;
+ uw_Sqlcache_Value *value;
+ unsigned long timeInvalid;
+ UT_hash_handle hh;
+} uw_Sqlcache_Entry;
typedef struct uw_Sqlcache_Cache {
pthread_rwlock_t lockOut;
diff --git a/src/c/urweb.c b/src/c/urweb.c
index 50aac5e8..c057688c 100644
--- a/src/c/urweb.c
+++ b/src/c/urweb.c
@@ -4562,13 +4562,6 @@ void uw_set_remoteSock(uw_context ctx, int sock) {
// Sqlcache
-typedef struct uw_Sqlcache_Entry {
- char *key;
- uw_Sqlcache_Value *value;
- unsigned long timeInvalid;
- UT_hash_handle hh;
-} uw_Sqlcache_Entry;
-
static void uw_Sqlcache_freeValue(uw_Sqlcache_Value *value) {
if (value) {
free(value->result);