new file mode 100644
@@ -0,0 +1,20 @@
+Fix
+
+sensor_factors_000.cpp:66:5: error: non-constant-expression cannot be narrowed from type 'int' to 'unsigned char' in initializer list [-Wc++11-narrowing]
+((dRExp << 4) & 0xf0) | (dBExp & 0x0f ), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: openhpi-3.6.1/plugins/ipmidirect/t/sensor_factors_000.cpp
+===================================================================
+--- openhpi-3.6.1.orig/plugins/ipmidirect/t/sensor_factors_000.cpp
++++ openhpi-3.6.1/plugins/ipmidirect/t/sensor_factors_000.cpp
+@@ -63,7 +63,7 @@ static cIpmiSdr sdr =
+ dB & 0xff,
+ ((dB >> 2) & 0xc0) | (dAccuracy & 0x3f),
+ ((dAccuracy >> 2) & 0xf0) | ((dAccuracyExp << 2) & 0x0c),
+- ((dRExp << 4) & 0xf0) | (dBExp & 0x0f ),
++ (unsigned char)(((dRExp << 4) & 0xf0) | (dBExp & 0x0f )),
+ 0,
+ 0,
+ }
@@ -38,6 +38,7 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \
file://0001-Fix-build-failures-with-gcc7.patch \
file://c++11.patch \
file://clang-c++11.patch \
+ file://fix-narrowing-warning.patch \
\
file://openhpi.init \
file://openhpid.service \
Signed-off-by: Khem Raj <raj.khem@gmail.com> --- .../openhpi/files/fix-narrowing-warning.patch | 20 ++++++++++++++++++++ .../recipes-daemons/openhpi/openhpi_3.6.1.bb | 1 + 2 files changed, 21 insertions(+) create mode 100644 meta-networking/recipes-daemons/openhpi/files/fix-narrowing-warning.patch -- 2.14.1 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel