Skip to content

Commit b6da630

Browse files
authored
Update .travis.yml for newer libcurl. (#33)
1 parent 090d2cc commit b6da630

File tree

2 files changed

+47
-16
lines changed

2 files changed

+47
-16
lines changed

.travis.yml

+44-13
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
language: c
22
compiler: gcc
33
sudo: false
4+
env:
5+
NGHTTP2_VERSION=1.24.0
6+
CURL_VERSION=7.49.0
7+
CURL_DIR=curl-${CURL_VERSION}
48
addons:
59
apt:
610
packages:
@@ -16,21 +20,48 @@ addons:
1620
- zzuf
1721
- socat
1822
install:
19-
- if [ $TRAVIS_OS_NAME = linux ]; then
20-
curl -L https://github.com/nghttp2/nghttp2/releases/download/v1.24.0/nghttp2-1.24.0.tar.gz |
21-
tar xzf - &&
22-
(cd nghttp2-1.24.0 && CXX="g++-4.8" ./configure --prefix=/usr --enable-lib-only && make && sudo make install);
23-
fi
23+
- |
24+
cd ~/build/ &&
25+
curl -L https://github.com/nghttp2/nghttp2/releases/download/v${NGHTTP2_VERSION}/nghttp2-${NGHTTP2_VERSION}.tar.gz |
26+
tar xzf - &&
27+
cd nghttp2-${NGHTTP2_VERSION} &&
28+
CXX="g++-4.8" ./configure --prefix=/usr --enable-lib-only &&
29+
make && sudo make install
30+
- |
31+
cd ~/build/ &&
32+
curl -L https://curl.haxx.se/download/curl-${CURL_VERSION}.tar.gz |
33+
tar xzf - &&
34+
cd ${CURL_DIR} &&
35+
CXX="g++-4.8" ./configure --prefix=/usr --with-nghttp2 --without-ssl --with-gnutls &&
36+
make && sudo make install
37+
- cd ~/build/maru/libmicrohttpd-http2/
2438
before_script:
2539
- autoreconf -fi
2640
script:
27-
- ./configure --enable-https --enable-http2 --with-nghttp2
28-
- echo '#undef HAVE_INET6' >> MHD_config.h
29-
- make
30-
- make check
31-
- sudo sh -c 'echo 0 > /proc/sys/net/ipv6/conf/all/disable_ipv6'
32-
- ./configure --enable-https
33-
- make
34-
- make check
41+
- export LD_LIBRARY_PATH=/usr/lib
42+
- |
43+
echo '
44+
#include <curl/curl.h>
45+
#include <stdio.h>
46+
47+
int
48+
main (int argc, char *const *argv)
49+
{
50+
curl_version_info_data *curlverd = curl_version_info (CURLVERSION_NOW);
51+
printf("curlverd->version %s\n", curlverd->version);
52+
return 0;
53+
}
54+
' | gcc -I/usr/include -L/usr/lib -xc - -lcurl && ./a.out && rm a.out
55+
- |
56+
./configure --prefix=/usr --enable-https --disable-doc --enable-silent-rules --enable-asserts &&
57+
echo '#undef HAVE_INET6' >> MHD_config.h &&
58+
make && make check
59+
- |
60+
./configure --prefix=/usr --enable-https --enable-http2 --with-nghttp2 --disable-doc --disable-silent-rules --enable-asserts &&
61+
echo '#undef HAVE_INET6' >> MHD_config.h &&
62+
make && make check
3563
after_failure:
3664
- cat src/microhttpd/test-suite.log
65+
- cat ./src/testcurl/test-suite.log
66+
- cat ./src/testcurl/https/test-suite.log
67+
- cat ./src/testzzuf/test-suite.log

configure.ac

+3-3
Original file line numberDiff line numberDiff line change
@@ -1193,7 +1193,7 @@ AC_ARG_ENABLE([curl],
11931193
curl=0
11941194
if test "$enable_curl" != "no"
11951195
then
1196-
LIBCURL_CHECK_CONFIG([yes],[7.16.4],[enable_curl=yes],
1196+
LIBCURL_CHECK_CONFIG([yes],[7.49.0],[enable_curl=yes],
11971197
[
11981198
if test "x$enable_curl" = "xyes"; then
11991199
AC_MSG_WARN([[cURL-based tests cannot be enabled because libcurl is missing]])
@@ -1204,7 +1204,7 @@ fi
12041204
if test "$enable_curl" != "no"
12051205
then
12061206
# Lib cURL & cURL - OpenSSL versions
1207-
AC_DEFINE([MHD_REQ_CURL_VERSION], ["7.16.4"], [required cURL version to run tests])
1207+
AC_DEFINE([MHD_REQ_CURL_VERSION], ["7.49.0"], [required cURL version to run tests])
12081208
AC_DEFINE([MHD_REQ_CURL_OPENSSL_VERSION], ["0.9.8"], [required cURL SSL version to run tests])
12091209
AC_DEFINE([MHD_REQ_CURL_GNUTLS_VERSION], ["2.8.6"], [gnuTLS lib version - used in conjunction with cURL])
12101210
AC_DEFINE([MHD_REQ_CURL_NSS_VERSION], ["3.12.0"], [NSS lib version - used in conjunction with cURL])
@@ -1909,8 +1909,8 @@ then
19091909
CFLAGS="$NGHTTP2_CFLAGS $CFLAGS"
19101910
LDFLAGS="$NGHTTP2_LIBS $LDFLAGS"
19111911
LIBS="$LIBS $NGHTTP2_LIBS"
1912-
AC_MSG_CHECKING([[whether nghttp2 is usable]])
19131912
NGHTTP2_CHECK()
1913+
AC_MSG_CHECKING([[whether nghttp2 is usable]])
19141914
AS_IF([test "x$have_nghttp2" = "xyes"],
19151915
[
19161916
AC_MSG_RESULT([[yes]])

0 commit comments

Comments
 (0)