Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
R
rapidjson
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
rapidjson
Commits
2de47aae
Commit
2de47aae
authored
Feb 27, 2016
by
Milo Yip
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into example_parsebyparts
parents
f44961ff
4de9ba54
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
151 additions
and
40 deletions
+151
-40
.travis.yml
.travis.yml
+123
-39
CMakeLists.txt
CMakeLists.txt
+9
-0
rapidjson.h
include/rapidjson/rapidjson.h
+1
-1
CMakeLists.txt
test/perftest/CMakeLists.txt
+9
-0
CMakeLists.txt
test/unittest/CMakeLists.txt
+9
-0
No files found.
.travis.yml
View file @
2de47aae
language
:
cpp
sudo
:
false
cache
:
-
ccache
compiler
:
-
clang
-
gcc
addons
:
apt
:
packages
:
&default_packages
-
cmake
-
valgrind
env
:
matrix
:
-
CONF=debug ARCH=x86_64 CXX11=ON
-
CONF=release ARCH=x86_64 CXX11=ON
-
CONF=debug ARCH=x86 CXX11=ON
-
CONF=release ARCH=x86 CXX11=ON
-
CONF=debug ARCH=x86_64 CXX11=OFF
-
CONF=debug ARCH=x86 CXX11=OFF
global
:
global
:
-
USE_CCACHE=1
-
CCACHE_SLOPPINESS=pch_defines,time_macros
-
CCACHE_COMPRESS=1
-
CCACHE_MAXSIZE=100M
-
ARCH_FLAGS_x86='-m32'
# #266: don't use SSE on 32-bit
-
ARCH_FLAGS_x86_64='-msse4.2'
# use SSE4.2 on 64-bit
-
GITHUB_REPO='miloyip/rapidjson'
-
secure
:
"
HrsaCb+N66EG1HR+LWH1u51SjaJyRwJEDzqJGYMB7LJ/bfqb9mWKF1fLvZGk46W5t7TVaXRDD5KHFx9DPWvKn4gRUVkwTHEy262ah5ORh8M6n/6VVVajeV/AYt2C0sswdkDBDO4Xq+xy5gdw3G8s1A4Inbm73pUh+6vx+7ltBbk="
before_install
:
-
sudo apt-get update -qq
-
sudo apt-get install -qq cmake valgrind
-
sudo apt-get --no-install-recommends install doxygen
# Don't install LaTeX stuffs
-
if [ "$ARCH" = "x86" ]; then sudo apt-get install -qq g++-multilib libc6-dbg:i386; fi
-
if [ "$CC" = "gcc" ] && [ "$CONF" = "debug" ]; then sudo pip install cpp-coveralls; export GCOV_FLAGS='--coverage'; fi
install
:
true
matrix
:
include
:
# gcc
-
env
:
CONF=release ARCH=x86 CXX11=ON
compiler
:
gcc
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
-
env
:
CONF=release ARCH=x86_64 CXX11=ON
compiler
:
gcc
-
env
:
CONF=debug ARCH=x86 CXX11=OFF
compiler
:
gcc
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
-
env
:
CONF=debug ARCH=x86_64 CXX11=OFF
compiler
:
gcc
# clang
-
env
:
CONF=debug ARCH=x86 CXX11=ON CCACHE_CPP2=yes
compiler
:
clang
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
-
env
:
CONF=debug ARCH=x86_64 CXX11=ON CCACHE_CPP2=yes
compiler
:
clang
-
env
:
CONF=debug ARCH=x86 CXX11=OFF CCACHE_CPP2=yes
compiler
:
clang
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
-
env
:
CONF=debug ARCH=x86_64 CXX11=OFF CCACHE_CPP2=yes
compiler
:
clang
-
env
:
CONF=release ARCH=x86 CXX11=ON CCACHE_CPP2=yes
compiler
:
clang
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
-
env
:
CONF=release ARCH=x86_64 CXX11=ON CCACHE_CPP2=yes
compiler
:
clang
# coverage report
-
env
:
CONF=debug ARCH=x86 CXX11=ON GCOV_FLAGS='--coverage'
compiler
:
gcc
cache
:
-
ccache
-
pip
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
after_success
:
-
pip install --user cpp-coveralls
-
coveralls -r .. --gcov-options '\-lp' -e thirdparty -e example -e test -e build/CMakeFiles -e include/rapidjson/msinttypes -e include/rapidjson/internal/meta.h -e include/rapidjson/error/en.h
-
env
:
CONF=debug ARCH=x86_64 GCOV_FLAGS='--coverage'
compiler
:
gcc
cache
:
-
ccache
-
pip
addons
:
apt
:
packages
:
-
*default_packages
-
g++-multilib
-
libc6-dbg:i386
after_success
:
-
pip install --user cpp-coveralls
-
coveralls -r .. --gcov-options '\-lp' -e thirdparty -e example -e test -e build/CMakeFiles -e include/rapidjson/msinttypes -e include/rapidjson/internal/meta.h -e include/rapidjson/error/en.h
-
script
:
# Documentation task
-
cd build
-
cmake .. -DRAPIDJSON_HAS_STDSTRING=ON -DCMAKE_VERBOSE_MAKEFILE=ON
-
make travis_doc
cache
:
false
addons
:
apt
:
packages
:
-
doxygen
before_script
:
# hack to avoid Valgrind bug (https://bugs.kde.org/show_bug.cgi?id=326469),
# exposed by merging PR#163 (using -march=native)
-
ccache -s
# hack to avoid Valgrind bug (https://bugs.kde.org/show_bug.cgi?id=326469),
# exposed by merging PR#163 (using -march=native)
# TODO
:
Since this bug is already fixed. Remove this when valgrind can be upgraded.
-
sed -i "s/-march=native//" CMakeLists.txt
-
mkdir build
-
>
eval "ARCH_FLAGS=\${ARCH_FLAGS_${ARCH}}" ;
(cd build && cmake
-DRAPIDJSON_HAS_STDSTRING=ON
-DRAPIDJSON_BUILD_CXX11=$CXX11
-DCMAKE_VERBOSE_MAKEFILE=ON
-DCMAKE_BUILD_TYPE=$CONF
-DCMAKE_CXX_FLAGS="$ARCH_FLAGS $GCOV_FLAGS"
-DCMAKE_EXE_LINKER_FLAGS=$GCOV_FLAGS
..)
-
mkdir build
script
:
-
>
eval "ARCH_FLAGS=\${ARCH_FLAGS_${ARCH}}" ;
(cd build && cmake
-DRAPIDJSON_HAS_STDSTRING=ON
-DRAPIDJSON_BUILD_CXX11=$CXX11
-DCMAKE_VERBOSE_MAKEFILE=ON
-DCMAKE_BUILD_TYPE=$CONF
-DCMAKE_CXX_FLAGS="$ARCH_FLAGS $GCOV_FLAGS"
-DCMAKE_EXE_LINKER_FLAGS=$GCOV_FLAGS
..)
-
cd build
-
make tests
-
make examples
-
ctest -V `[ "$CONF" = "release" ] || echo "-E perftest"`
-
make travis_doc
after_success
:
-
coveralls -r .. --gcov-options '\-lp' -e thirdparty -e example -e test -e build/CMakeFiles -e include/rapidjson/msinttypes -e include/rapidjson/internal/meta.h -e include/rapidjson/error/en.h
-
make tests -j 2
-
make examples -j 2
-
ctest -j 2 -V `[ "$CONF" = "release" ] || echo "-E perftest"`
CMakeLists.txt
View file @
2de47aae
...
...
@@ -29,6 +29,15 @@ if(RAPIDJSON_HAS_STDSTRING)
add_definitions
(
-DRAPIDJSON_HAS_STDSTRING
)
endif
()
find_program
(
CCACHE_FOUND ccache
)
if
(
CCACHE_FOUND
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_LINK ccache
)
if
(
CMAKE_CXX_COMPILER_ID MATCHES
"Clang"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Qunused-arguments -fcolor-diagnostics"
)
endif
()
endif
(
CCACHE_FOUND
)
if
(
"
${
CMAKE_CXX_COMPILER_ID
}
"
STREQUAL
"GNU"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-march=native -Wall -Wextra -Werror"
)
if
(
RAPIDJSON_BUILD_CXX11
)
...
...
include/rapidjson/rapidjson.h
View file @
2de47aae
...
...
@@ -159,7 +159,7 @@
*/
#ifndef RAPIDJSON_NO_INT64DEFINE
//!@cond RAPIDJSON_HIDDEN_FROM_DOXYGEN
#if
def _MSC_VER
#if
defined(_MSC_VER) && (_MSC_VER < 1800) // Visual Studio 2013
#include "msinttypes/stdint.h"
#include "msinttypes/inttypes.h"
#else
...
...
test/perftest/CMakeLists.txt
View file @
2de47aae
...
...
@@ -10,6 +10,15 @@ target_link_libraries(perftest ${TEST_LIBRARIES})
add_dependencies
(
tests perftest
)
find_program
(
CCACHE_FOUND ccache
)
if
(
CCACHE_FOUND
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_LINK ccache
)
if
(
CMAKE_CXX_COMPILER_ID MATCHES
"Clang"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Qunused-arguments -fcolor-diagnostics"
)
endif
()
endif
(
CCACHE_FOUND
)
IF
(
NOT
(
CMAKE_BUILD_TYPE STREQUAL
"Debug"
))
add_test
(
NAME perftest
COMMAND
${
CMAKE_RUNTIME_OUTPUT_DIRECTORY
}
/perftest
...
...
test/unittest/CMakeLists.txt
View file @
2de47aae
...
...
@@ -25,6 +25,15 @@ set(UNITTEST_SOURCES
valuetest.cpp
writertest.cpp
)
find_program
(
CCACHE_FOUND ccache
)
if
(
CCACHE_FOUND
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache
)
set_property
(
GLOBAL PROPERTY RULE_LAUNCH_LINK ccache
)
if
(
CMAKE_CXX_COMPILER_ID MATCHES
"Clang"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Qunused-arguments -fcolor-diagnostics"
)
endif
()
endif
(
CCACHE_FOUND
)
if
(
"
${
CMAKE_CXX_COMPILER_ID
}
"
STREQUAL
"GNU"
)
set
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Werror -Wall -Wextra -Weffc++ -Wswitch-default -Wfloat-equal"
)
elseif
(
CMAKE_CXX_COMPILER_ID MATCHES
"Clang"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment