summaryrefslogtreecommitdiff
path: root/packages/dev-libs/rapidjson/rapidjson.exlib
diff options
context:
space:
mode:
Diffstat (limited to 'packages/dev-libs/rapidjson/rapidjson.exlib')
-rw-r--r--packages/dev-libs/rapidjson/rapidjson.exlib48
1 files changed, 48 insertions, 0 deletions
diff --git a/packages/dev-libs/rapidjson/rapidjson.exlib b/packages/dev-libs/rapidjson/rapidjson.exlib
new file mode 100644
index 0000000..21bdf6d
--- /dev/null
+++ b/packages/dev-libs/rapidjson/rapidjson.exlib
@@ -0,0 +1,48 @@
+# Distributed under the terms of the GNU General Public License v2
+# Copyright 2018 Gluzskiy Alexandr <sss@sss.chaoslab.ru>
+
+
+SCM_EXTERNAL_REFS="
+ thirdparty/gtest:gtest
+"
+
+SCM_SECONDARY_REPOSITORIES="gtest"
+
+SCM_gtest_REPOSITORY="https://github.com/google/googletest.git"
+
+
+require github [ user=miloyip ]
+require cmake [ api=2 ]
+
+SUMMARY="A fast JSON parser/generator for C++ with both SAX/DOM style API"
+HOMEPAGE="http://rapidjson.org/"
+
+LICENCES="MIT"
+
+SLOT="0"
+
+export_exlib_phases src_configure
+
+MYOPTIONS="
+ doc
+ examples
+"
+
+
+DEPENDENCIES="
+ test:
+ dev-cpp/gtest
+ dev-util/valgrind
+ build:
+ doc? ( app-doc/doxygen )
+"
+
+rapidjson_src_configure() {
+ local cmakeparams=(
+ -DRAPIDJSON_BUILD_DOC=$(option doc && echo ON || echo OFF)
+ -DRAPIDJSON_BUILD_EXAMPLES=$(option examples && echo ON || echo OFF)
+ -DRAPIDJSON_BUILD_THIRDPARTY_GTEST=OFF
+ -DRAPIDJSON_BUILD_TESTS=$(expecting_tests && echo ON || echo OFF)
+ )
+ ecmake "${cmakeparams[@]}"
+}