package/mraa: bump to version 2.2.0
- Refresh upstream status of first patch - Drop second patch (already in version) https://github.com/eclipse/mraa/blob/v2.2.0/docs/changelog.md Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
This commit is contained in:
parent
b72b849ad5
commit
5a30732769
@ -1,13 +1,14 @@
|
||||
From dbb5961f106ec42cd70689d933674c9c37aedfe1 Mon Sep 17 00:00:00 2001
|
||||
From aaa0a5cd4e401bde4fb3691dd4e6c70a5c61e031 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Bj=C3=B6rn=20Esser?= <besser82@fedoraproject.org>
|
||||
Date: Mon, 13 Apr 2020 20:12:11 +0200
|
||||
Subject: [PATCH] include: Declare gVERSION global as 'extern'.
|
||||
|
||||
Fixes build with '-fno-common'.
|
||||
|
||||
Signed-off-by: Thomas Ingleby <thomas.ingleby@intel.com>
|
||||
[Retrieved from:
|
||||
https://github.com/eclipse/mraa/pull/1012/commits/dbb5961f106ec42cd70689d933674c9c37aedfe1]
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmaail.com>
|
||||
https://github.com/eclipse/mraa/commit/aaa0a5cd4e401bde4fb3691dd4e6c70a5c61e031]
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
---
|
||||
include/version.h | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
@ -1,193 +0,0 @@
|
||||
From cb88e4dd1fbbb9d24e625dba2768b88ed99da309 Mon Sep 17 00:00:00 2001
|
||||
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
Date: Sat, 13 Jun 2020 22:51:37 +0200
|
||||
Subject: [PATCH] CMakeLists.txt: add BUILDCPP option
|
||||
|
||||
C++ is a mandatory dependency since version 1.4.0 and
|
||||
https://github.com/eclipse/mraa/commit/122cab1f1e53b7c9c7cd82905b962071f9bad9dc
|
||||
|
||||
As a result, build on embedded toolchains that do not support C++ fails
|
||||
on:
|
||||
|
||||
CMake Error at CMakeLists.txt:2 (project):
|
||||
The CMAKE_CXX_COMPILER:
|
||||
|
||||
/home/naourr/work/instance-1/output-1/per-package/mraa/host/bin/arm-linux-g++
|
||||
|
||||
is not a full path to an existing compiler tool.
|
||||
|
||||
Fixes:
|
||||
- http://autobuild.buildroot.org/results/31086422e03611c16ab59c4418e3669b580bc0c0
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
[Retrieved from:
|
||||
https://github.com/eclipse/mraa/commit/cb88e4dd1fbbb9d24e625dba2768b88ed99da309]
|
||||
---
|
||||
CMakeLists.txt | 69 +++++++++++++++++++----------------
|
||||
src/java/CMakeLists.txt | 4 +-
|
||||
src/javascript/CMakeLists.txt | 34 +++++++++--------
|
||||
3 files changed, 59 insertions(+), 48 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 250d9106e..90c0dc920 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -1,5 +1,5 @@
|
||||
cmake_minimum_required (VERSION 2.8.11)
|
||||
-project (mraa C CXX)
|
||||
+project (mraa C)
|
||||
|
||||
FIND_PACKAGE (Threads REQUIRED)
|
||||
|
||||
@@ -11,6 +11,8 @@ else ()
|
||||
set (CMAKE_C_STANDARD 99)
|
||||
endif ()
|
||||
|
||||
+option (BUILDCPP "Enable C++ (needed by FTDI4222 and tests)" ON)
|
||||
+
|
||||
###############################################################################
|
||||
# Detect supported warning flags
|
||||
# Modified from work By Dan Liew (fpbench - MIT)
|
||||
@@ -33,15 +35,18 @@ set (MRAA_C_WARNING_FLAGS
|
||||
-Werror=missing-parameter-type
|
||||
)
|
||||
|
||||
-# Warning flags for the C++ compiler only
|
||||
-set (MRAA_CXX_WARNING_FLAGS
|
||||
- -Wnon-virtual-dtor
|
||||
- -Woverloaded-virtual
|
||||
- -Wreorder
|
||||
-)
|
||||
-
|
||||
include (CheckCCompilerFlag)
|
||||
-include (CheckCXXCompilerFlag)
|
||||
+if (BUILDCPP)
|
||||
+ # Warning flags for the C++ compiler only
|
||||
+ set (MRAA_CXX_WARNING_FLAGS
|
||||
+ -Wnon-virtual-dtor
|
||||
+ -Woverloaded-virtual
|
||||
+ -Wreorder
|
||||
+ )
|
||||
+
|
||||
+ enable_language (CXX)
|
||||
+ include (CheckCXXCompilerFlag)
|
||||
+endif ()
|
||||
function (MRAA_SANITIZE_FLAG_NAME OUTPUT_VAR FLAG)
|
||||
string (REPLACE "-" "_" SANITIZED_FLAG_NAME "${FLAG}")
|
||||
string (REPLACE "/" "_" SANITIZED_FLAG_NAME "${SANITIZED_FLAG_NAME}")
|
||||
@@ -62,28 +67,30 @@ foreach (flag ${MRAA_BOTH_WARNING_FLAGS} ${MRAA_C_WARNING_FLAGS})
|
||||
endif ()
|
||||
endforeach ()
|
||||
|
||||
-# Globally set C++ compiler warning flags that are supported and emit
|
||||
-# a warning about unsupported flags
|
||||
-foreach (flag ${MRAA_BOTH_WARNING_FLAGS} ${MRAA_CXX_WARNING_FLAGS})
|
||||
- MRAA_SANITIZE_FLAG_NAME (SANITIZED_FLAG_NAME "${flag}")
|
||||
- CHECK_CXX_COMPILER_FLAG ("${flag}" HAS_CXX_${SANITIZED_FLAG_NAME})
|
||||
- if (HAS_CXX_${SANITIZED_FLAG_NAME})
|
||||
- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${flag}")
|
||||
- else ()
|
||||
- message (WARNING "C++ compiler does not support flag \"${flag}\"")
|
||||
- endif ()
|
||||
-endforeach ()
|
||||
-
|
||||
-# This function adds the c++11 flag to a c++ target (if supported)
|
||||
-function(use_cxx_11 targetname)
|
||||
- include(CheckCXXCompilerFlag)
|
||||
- CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11)
|
||||
- if (COMPILER_SUPPORTS_CXX11)
|
||||
- set_target_properties(${targetname} PROPERTIES COMPILE_FLAGS "-std=c++11")
|
||||
- else()
|
||||
- message(FATAL_ERROR "Target '${targetname}' requires c++11 which is not supported by this compiler")
|
||||
- endif()
|
||||
-endfunction()
|
||||
+if (BUILDCPP)
|
||||
+ # Globally set C++ compiler warning flags that are supported and emit
|
||||
+ # a warning about unsupported flags
|
||||
+ foreach (flag ${MRAA_BOTH_WARNING_FLAGS} ${MRAA_CXX_WARNING_FLAGS})
|
||||
+ MRAA_SANITIZE_FLAG_NAME (SANITIZED_FLAG_NAME "${flag}")
|
||||
+ CHECK_CXX_COMPILER_FLAG ("${flag}" HAS_CXX_${SANITIZED_FLAG_NAME})
|
||||
+ if (HAS_CXX_${SANITIZED_FLAG_NAME})
|
||||
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${flag}")
|
||||
+ else ()
|
||||
+ message (WARNING "C++ compiler does not support flag \"${flag}\"")
|
||||
+ endif ()
|
||||
+ endforeach ()
|
||||
+
|
||||
+ # This function adds the c++11 flag to a c++ target (if supported)
|
||||
+ function(use_cxx_11 targetname)
|
||||
+ include(CheckCXXCompilerFlag)
|
||||
+ CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11)
|
||||
+ if (COMPILER_SUPPORTS_CXX11)
|
||||
+ set_target_properties(${targetname} PROPERTIES COMPILE_FLAGS "-std=c++11")
|
||||
+ else()
|
||||
+ message(FATAL_ERROR "Target '${targetname}' requires c++11 which is not supported by this compiler")
|
||||
+ endif()
|
||||
+ endfunction()
|
||||
+endif()
|
||||
|
||||
# Set CMAKE_INSTALL_LIBDIR if not defined
|
||||
include(GNUInstallDirs)
|
||||
diff --git a/src/java/CMakeLists.txt b/src/java/CMakeLists.txt
|
||||
index 231c755fa..cfa72a0df 100644
|
||||
--- a/src/java/CMakeLists.txt
|
||||
+++ b/src/java/CMakeLists.txt
|
||||
@@ -16,7 +16,9 @@ include_directories (
|
||||
set_source_files_properties (mraajava.i PROPERTIES SWIG_FLAGS ";-package;mraa;-I${CMAKE_BINARY_DIR}/src")
|
||||
set_source_files_properties (mraajava.i PROPERTIES CPLUSPLUS ON)
|
||||
|
||||
-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive -DJAVACALLBACK")
|
||||
+if (BUILDCPP)
|
||||
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive -DJAVACALLBACK")
|
||||
+endif()
|
||||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DJAVACALLBACK")
|
||||
|
||||
if (NOT DEFINED ENV{JAVA_HOME_NATIVE})
|
||||
diff --git a/src/javascript/CMakeLists.txt b/src/javascript/CMakeLists.txt
|
||||
index 25fd36275..99a96b49d 100644
|
||||
--- a/src/javascript/CMakeLists.txt
|
||||
+++ b/src/javascript/CMakeLists.txt
|
||||
@@ -36,25 +36,27 @@ set_target_properties (mraajs PROPERTIES
|
||||
)
|
||||
|
||||
message (STATUS "INFO - swig Version ${SWIG_VERSION}")
|
||||
-message (STATUS "INFO - CXX compiler Version ${CMAKE_CXX_COMPILER_ID} ${CMAKE_CXX_COMPILER_VERSION}")
|
||||
+if (BUILDCPP)
|
||||
+ message (STATUS "INFO - CXX compiler Version ${CMAKE_CXX_COMPILER_ID} ${CMAKE_CXX_COMPILER_VERSION}")
|
||||
|
||||
-if (${V8_VERSION_MAJOR} GREATER 3)
|
||||
- message (STATUS "INFO - Using V8 version > 3 so requiring C++11 compiler")
|
||||
- # Node 0.12.x V8 engine major version is '3'.
|
||||
- # Node 2.1.0 V8 engine major version is '4'.
|
||||
- set_property (TARGET mraajs PROPERTY CXX_STANDARD 11)
|
||||
- set_property (TARGET mraajs PROPERTY CXX_STANDARD_REQUIRED ON)
|
||||
- if (CMAKE_VERSION VERSION_LESS "3.1")
|
||||
- message (WARNING "Need to use CMAKE version 3.1+, but it is ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}.${CMAKE_PATCH_VERSION}, using a workaround.")
|
||||
- if (CMAKE_COMPILER_IS_GNUCXX)
|
||||
- if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.7")
|
||||
- message (FATAL_ERROR "GNU gcc compiler is also too old (need 4.7+, but ${CMAKE_CXX_COMPILER_VERSION}) and does not support C++11 standard.")
|
||||
+ if (${V8_VERSION_MAJOR} GREATER 3)
|
||||
+ message (STATUS "INFO - Using V8 version > 3 so requiring C++11 compiler")
|
||||
+ # Node 0.12.x V8 engine major version is '3'.
|
||||
+ # Node 2.1.0 V8 engine major version is '4'.
|
||||
+ set_property (TARGET mraajs PROPERTY CXX_STANDARD 11)
|
||||
+ set_property (TARGET mraajs PROPERTY CXX_STANDARD_REQUIRED ON)
|
||||
+ if (CMAKE_VERSION VERSION_LESS "3.1")
|
||||
+ message (WARNING "Need to use CMAKE version 3.1+, but it is ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}.${CMAKE_PATCH_VERSION}, using a workaround.")
|
||||
+ if (CMAKE_COMPILER_IS_GNUCXX)
|
||||
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.7")
|
||||
+ message (FATAL_ERROR "GNU gcc compiler is also too old (need 4.7+, but ${CMAKE_CXX_COMPILER_VERSION}) and does not support C++11 standard.")
|
||||
+ endif ()
|
||||
+ set (MRAA_CXX11_WORKAROUND_OPTION "-std=gnu++11")
|
||||
+ else ()
|
||||
+ set (MRAA_CXX11_WORKAROUND_OPTION "-std=c++11")
|
||||
endif ()
|
||||
- set (MRAA_CXX11_WORKAROUND_OPTION "-std=gnu++11")
|
||||
- else ()
|
||||
- set (MRAA_CXX11_WORKAROUND_OPTION "-std=c++11")
|
||||
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${MRAA_CXX11_WORKAROUND_OPTION} ")
|
||||
endif ()
|
||||
- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${MRAA_CXX11_WORKAROUND_OPTION} ")
|
||||
endif ()
|
||||
endif ()
|
||||
|
@ -1,3 +1,3 @@
|
||||
# Locally calculated
|
||||
sha256 5351ce9eb654014d8ea7f43bdb2d17e6d1955536938a2ea0d467f4008e614345 mraa-2.1.0.tar.gz
|
||||
sha256 076669bee8423ffef3065735b293a329020be86630fea457174dbfcc67a0554a mraa-2.2.0.tar.gz
|
||||
sha256 fac52622ed3badd86b34857b21777ab90296d6ccbc2ac0fd457c09fdeefa9ef1 COPYING
|
||||
|
@ -4,7 +4,7 @@
|
||||
#
|
||||
################################################################################
|
||||
|
||||
MRAA_VERSION = 2.1.0
|
||||
MRAA_VERSION = 2.2.0
|
||||
MRAA_SITE = $(call github,eclipse,mraa,v$(MRAA_VERSION))
|
||||
MRAA_LICENSE = MIT
|
||||
MRAA_LICENSE_FILES = COPYING
|
||||
|
Loading…
Reference in New Issue
Block a user