From b26f49a47aa6aae6ce647bb7d8022d6c096824b3 Mon Sep 17 00:00:00 2001 From: Alexander Egorenkov Date: Sat, 19 Aug 2017 11:40:09 +0200 Subject: [PATCH] New package: rapidjson-1.1.0 --- ...ve-march-native-from-CMAKE_CXX_FLAGS.patch | 22 +++++++++++++++++++ srcpkgs/rapidjson/template | 17 ++++++++++++++ 2 files changed, 39 insertions(+) create mode 100644 srcpkgs/rapidjson/patches/0001-remove-march-native-from-CMAKE_CXX_FLAGS.patch create mode 100644 srcpkgs/rapidjson/template diff --git a/srcpkgs/rapidjson/patches/0001-remove-march-native-from-CMAKE_CXX_FLAGS.patch b/srcpkgs/rapidjson/patches/0001-remove-march-native-from-CMAKE_CXX_FLAGS.patch new file mode 100644 index 0000000000..eb0b76b21e --- /dev/null +++ b/srcpkgs/rapidjson/patches/0001-remove-march-native-from-CMAKE_CXX_FLAGS.patch @@ -0,0 +1,22 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index ceda71b1..9fc52736 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -50,7 +50,7 @@ if(CCACHE_FOUND) + endif(CCACHE_FOUND) + + if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native -Wall -Wextra -Werror") ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror") + if (RAPIDJSON_BUILD_CXX11) + if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.7.0") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x") +@@ -73,7 +73,7 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") + endif() + endif() + elseif (CMAKE_CXX_COMPILER_ID MATCHES "Clang") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native -Wall -Wextra -Werror -Wno-missing-field-initializers") ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror -Wno-missing-field-initializers") + if (RAPIDJSON_BUILD_CXX11) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + endif() diff --git a/srcpkgs/rapidjson/template b/srcpkgs/rapidjson/template new file mode 100644 index 0000000000..14f3e9f523 --- /dev/null +++ b/srcpkgs/rapidjson/template @@ -0,0 +1,17 @@ +# Template build file for 'rapidjson'. +pkgname=rapidjson +version=1.1.0 +revision=1 +build_style=cmake +patch_args="-Np1" +noarch=yes +short_desc="A fast JSON parser/generator for C++ with both SAX/DOM style API" +maintainer="Alexander Egorenkov " +license="BSD, MIT" +homepage="https://github.com/miloyip/rapidjson" +distfiles="https://github.com/miloyip/${pkgname}/archive/v${version}.tar.gz" +checksum=bf7ced29704a1e696fbccf2a2b4ea068e7774fa37f6d7dd4039d0787f8bed98e + +post_install() { + vlicense license.txt +}