Added more configurations to the Travis build matrix.
authorDan Fandrich <dan@coneharvesters.com>
Fri, 24 Aug 2018 16:37:11 +0000 (18:37 +0200)
committerDan Fandrich <dan@coneharvesters.com>
Sat, 25 Aug 2018 17:14:31 +0000 (19:14 +0200)
.travis.yml

index 6b2851e..2d2b8c6 100644 (file)
@@ -10,10 +10,21 @@ addons:
     packages:
     - autopoint
 
+env:
+  matrix:
+    - CONFIG=normal
+    - CONFIG=c90
+    - CONFIG=stackprotect
+  global:
+    - MAKEFLAGS='-j 2'
+
 script:
   # Ensure brew gettext is in the PATH so autopoint is found on OS X
   - PATH="$PATH:/usr/local/opt/gettext/bin" autoreconf -sivf
-  - ./configure --prefix="${HOME}"
+  - if [ "$CONFIG" = "normal" ] ; then CFLAGS='-Wall -Wextra -O3'; fi
+  - if [ "$CONFIG" = "c90" ] ; then CFLAGS='-std=iso9899:1990 -D_XOPEN_SOURCE=500 -Wall -Wextra -O3'; fi
+  - if [ "$CONFIG" = "stackprotect" ] ; then CFLAGS='-g -O0 -fstack-protector-all'; fi
+  - ./configure --prefix="${HOME}" CFLAGS="$CFLAGS" || { tail -300 config.log; false; }
   - make
   - make check
   - make install