Commit b3a5da068abd2f2983d9e67adbf41b0e0f34e37f

Josh Triplett 2014-03-15T23:27:56

.travis.yml: Test on both 32-bit and 64-bit

diff --git a/.travis.yml b/.travis.yml
index c321813..5d8b048 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -2,7 +2,16 @@ language: c
 compiler:
   - gcc
   - clang
+env:
+  - build32=false
+  - build32=true
+matrix:
+  exclude:
+    - compiler: clang
+      env: build32=true
 
-before_script: sudo apt-get install dejagnu texinfo
+before_script:
+  - sudo apt-get install dejagnu texinfo
+  - if $build32 ; then sudo apt-get install gcc-multilib g++-multilib ; fi
 
-script: ./autogen.sh && ./configure && make && make check
+script: run= && if $build32 ; then run=i386 && mkdir path32 && PATH="$(pwd)/path32:$PATH" && printf '#!/bin/sh\nexec /usr/bin/'"$CC"' -m32 "$@"' > "path32/$CC" && chmod a+x "path32/$CC" ; fi && ./autogen.sh && $run ./configure && make && make check