mirror of
https://github.com/libexpat/libexpat.git
synced 2025-04-13 08:02:56 +00:00
commit
0e7efe2b01
4 changed files with 34 additions and 2 deletions
|
@ -30,6 +30,10 @@
|
|||
|
||||
set -e
|
||||
|
||||
if [[ ${TRAVIS_OS_NAME} = osx ]]; then
|
||||
export PATH="/usr/local/opt/coreutils/libexec/gnubin${PATH:+:}${PATH}"
|
||||
fi
|
||||
|
||||
PS4='# '
|
||||
set -x
|
||||
|
||||
|
|
11
.travis.yml
11
.travis.yml
|
@ -2,6 +2,9 @@
|
|||
# Licensed under the MIT license
|
||||
|
||||
language: cpp
|
||||
os:
|
||||
- linux
|
||||
- osx
|
||||
dist: trusty
|
||||
|
||||
# Unbreak clang address sanitizer, needs SYS_PTRACE
|
||||
|
@ -22,7 +25,15 @@ env:
|
|||
- MODE=distcheck
|
||||
- MODE=lib-coverage
|
||||
|
||||
matrix:
|
||||
exclude:
|
||||
- os: osx
|
||||
env: MODE=lib-coverage
|
||||
|
||||
addons:
|
||||
homebrew:
|
||||
update: true
|
||||
brewfile: true
|
||||
apt:
|
||||
packages:
|
||||
- cmake
|
||||
|
|
12
Brewfile
Normal file
12
Brewfile
Normal file
|
@ -0,0 +1,12 @@
|
|||
brew "automake"
|
||||
brew "autoconf"
|
||||
brew "libtool"
|
||||
brew "cmake"
|
||||
brew "docbook2x"
|
||||
brew "rpm"
|
||||
brew "coreutils"
|
||||
brew "ghostscript"
|
||||
brew "gcc"
|
||||
brew "m4"
|
||||
brew "gettext"
|
||||
brew "dos2unix"
|
|
@ -16,6 +16,7 @@ set -o nounset
|
|||
: ${MAKE:=make}
|
||||
|
||||
: ${BASE_COMPILE_FLAGS:="-pipe -Wall -Wextra -pedantic -Wno-overlength-strings -Wno-long-long"}
|
||||
: ${BASE_LINK_FLAGS:=}
|
||||
|
||||
ANNOUNCE() {
|
||||
local open='\e[1m'
|
||||
|
@ -43,7 +44,9 @@ main() {
|
|||
# http://clang.llvm.org/docs/AddressSanitizer.html
|
||||
local CC="${CLANG_CC}"
|
||||
local CXX="${CLANG_CXX}"
|
||||
local LD="${CLANG_CXX}"
|
||||
BASE_COMPILE_FLAGS+=" -g -fsanitize=address -fno-omit-frame-pointer"
|
||||
BASE_LINK_FLAGS+=" -g -Wc,-fsanitize=address" # "-Wc," is for libtool
|
||||
;;
|
||||
coverage | lib-coverage | app-coverage)
|
||||
local CC="${GCC_CC}"
|
||||
|
@ -78,6 +81,7 @@ main() {
|
|||
|
||||
local CFLAGS="-std=c89 ${BASE_COMPILE_FLAGS} ${CFLAGS:-}"
|
||||
local CXXFLAGS="-std=c++98 ${BASE_COMPILE_FLAGS} ${CXXFLAGS:-}"
|
||||
local LDFLAGS="${BASE_LINK_FLAGS} ${LDFLAGS:-}"
|
||||
|
||||
(
|
||||
set -e
|
||||
|
@ -85,8 +89,9 @@ main() {
|
|||
RUN CC="${CC}" CFLAGS="${CFLAGS}" \
|
||||
CXX="${CXX}" CXXFLAGS="${CXXFLAGS}" \
|
||||
AR="${AR}" \
|
||||
LD="${LD}" \
|
||||
./configure "$@"
|
||||
LD="${LD}" LDFLAGS="${LDFLAGS}" \
|
||||
./configure "$@" \
|
||||
|| { RUN cat config.log ; false ; }
|
||||
|
||||
RUN "${MAKE}" \
|
||||
CFLAGS="${CFLAGS} -Werror" \
|
||||
|
|
Loading…
Add table
Reference in a new issue