Fix nan is not a member of std when building android
Change-Id: I4eab47fd3358d26587e61c9f030f9ed10b067677 Reviewed-on: https://gerrit.libreoffice.org/55783 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
This commit is contained in:
committed by
Tomaž Vajngerl
parent
c3fa7a82b7
commit
cc2bc0bf3c
6
external/libmwaw/UnpackedTarball_libmwaw.mk
vendored
6
external/libmwaw/UnpackedTarball_libmwaw.mk
vendored
@@ -41,4 +41,10 @@ $(eval $(call gb_UnpackedTarball_add_patches,libmwaw,\
|
||||
external/libmwaw/0001-ssize_t-is-not-std-type.patch.1 \
|
||||
))
|
||||
|
||||
ifeq ($(OS),ANDROID)
|
||||
$(eval $(call gb_UnpackedTarball_add_patches,libmwaw, \
|
||||
external/libmwaw/libmwaw_android_arm.patch.1 \
|
||||
))
|
||||
endif
|
||||
|
||||
# vim: set noet sw=4 ts=4:
|
||||
|
20
external/libmwaw/libmwaw_android_arm.patch.1
vendored
Normal file
20
external/libmwaw/libmwaw_android_arm.patch.1
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
--- a/src/lib/MultiplanParser.cxx
|
||||
+++ b/src/lib/MultiplanParser.cxx
|
||||
@@ -747,7 +747,7 @@ bool MultiplanParser::readSharedData(int pos, int cellType, MWAWVec2i const &cel
|
||||
f << "Nan" << input->readULong(1) << ",";
|
||||
input->seek(7, librevenge::RVNG_SEEK_CUR);
|
||||
content.m_contentType=content.C_NUMBER;
|
||||
- content.setValue(std::nan(""));
|
||||
+ content.setValue(nan(""));
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
@@ -1594,7 +1594,7 @@ bool MultiplanParser::sendCell(MWAWVec2i const &cellPos, int p)
|
||||
f << name << ",";
|
||||
}
|
||||
else if ((type&0x3)==2 && dSz==8) {
|
||||
- content.setValue(std::nan(""));
|
||||
+ content.setValue(nan(""));
|
||||
f << "Nan" << input->readULong(1) << ",";
|
||||
input->seek(7, librevenge::RVNG_SEEK_CUR);
|
||||
}
|
34
external/libwps/0001-Fix-nan-is-not-a-member-of-std.patch.1
vendored
Normal file
34
external/libwps/0001-Fix-nan-is-not-a-member-of-std.patch.1
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
From 11d84de5628a6afaebdf85e09791221888e641f4 Mon Sep 17 00:00:00 2001
|
||||
From: Mert Tumer <merttumer@outlook.com>
|
||||
Date: Wed, 13 Jun 2018 17:32:15 -0700
|
||||
Subject: Fix nan is not a member of std
|
||||
|
||||
---
|
||||
src/lib/Multiplan.cpp | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/lib/Multiplan.cpp b/src/lib/Multiplan.cpp
|
||||
index 26ceca3..11f83c8 100644
|
||||
--- a/src/lib/Multiplan.cpp
|
||||
+++ b/src/lib/Multiplan.cpp
|
||||
@@ -2222,7 +2222,7 @@ bool MultiplanParser::readSharedData(int pos, int cellType, Vec2i const &cellPos
|
||||
f << "Nan" << libwps::readU8(input) << ",";
|
||||
input->seek(7, librevenge::RVNG_SEEK_CUR);
|
||||
content.m_contentType=content.C_NUMBER;
|
||||
- content.setValue(std::nan(""));
|
||||
+ content.setValue(nan(""));
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
@@ -2622,7 +2622,7 @@ bool MultiplanParser::sendCell(Vec2i const &cellPos, int p)
|
||||
}
|
||||
else if (type==2 && dSz==8)
|
||||
{
|
||||
- content.setValue(std::nan(""));
|
||||
+ content.setValue(nan(""));
|
||||
f << "Nan" << int(libwps::readU8(input)) << ",";
|
||||
input->seek(7, librevenge::RVNG_SEEK_CUR);
|
||||
}
|
||||
--
|
||||
2.17.1
|
||||
|
6
external/libwps/UnpackedTarball_libwps.mk
vendored
6
external/libwps/UnpackedTarball_libwps.mk
vendored
@@ -39,4 +39,10 @@ $(eval $(call gb_UnpackedTarball_add_patches,libwps,\
|
||||
external/libwps/0001-avoid-name-clash-with-MultiplanParser-from-libmwaw.patch.1 \
|
||||
))
|
||||
|
||||
ifeq ($(OS),ANDROID)
|
||||
$(eval $(call gb_UnpackedTarball_add_patches,libwps, \
|
||||
external/libwps/0001-Fix-nan-is-not-a-member-of-std.patch.1 \
|
||||
))
|
||||
endif
|
||||
|
||||
# vim: set noet sw=4 ts=4:
|
||||
|
Reference in New Issue
Block a user