configure.ac                                                                   
   |    2 
 download.lst                                                                   
   |    4 
 
external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
 |  606 ----------
 external/liborcus/Library_orcus-parser.mk                                      
   |    1 
 external/liborcus/Library_orcus.mk                                             
   |    3 
 external/liborcus/UnpackedTarball_liborcus.mk                                  
   |    4 
 external/liborcus/libtool.patch.0                                              
   |   14 
 external/liborcus/win_path_utf16.patch                                         
   |   33 
 external/liborcus/windows-constants-hack.patch                                 
   |    2 
 include/sal/log-areas.dox                                                      
   |    1 
 sc/Library_scfilt.mk                                                           
   |    1 
 sc/source/filter/inc/orcus_utils.hxx                                           
   |   16 
 sc/source/filter/inc/orcusinterface.hxx                                        
   |    2 
 sc/source/filter/orcus/interface.cxx                                           
   |    5 
 sc/source/filter/orcus/orcusfiltersimpl.cxx                                    
   |   12 
 sc/source/filter/orcus/utils.cxx                                               
   |   19 
 sc/source/filter/orcus/xmlcontext.cxx                                          
   |    6 
 17 files changed, 66 insertions(+), 665 deletions(-)

New commits:
commit 2e5e6c6ef3a31834a729aca8c93f086a3693bdc1
Author:     Kohei Yoshida <[email protected]>
AuthorDate: Tue Aug 19 22:28:39 2025 -0400
Commit:     Kohei Yoshida <[email protected]>
CommitDate: Wed Aug 20 05:50:12 2025 +0200

    Upgrade liborcus to 0.20.2
    
    For Windows build, explicitly define HAVE_FILESYSTEM which forces
    orcus to use std::filesystem for all filesystem related operations.
    
    Also, pass to the ctor of orcus::file_content a filepath as
    std::u16string_view on Windows to hopefully correctly handle unicode
    filepaths.
    
    Change-Id: Ie6f5403212e73c81f1a36db0413133d26a3a67f2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189892
    Reviewed-by: Kohei Yoshida <[email protected]>
    Tested-by: Jenkins

diff --git a/configure.ac b/configure.ac
index e6c60719cbd8..4714fa7aef6b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -11586,7 +11586,7 @@ fi
 dnl ===================================================================
 dnl Orcus
 dnl ===================================================================
-libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.20 >= 0.20.0])
+libo_CHECK_SYSTEM_MODULE([orcus],[ORCUS],[liborcus-0.20 >= 0.20.2])
 if test "$with_system_orcus" != "yes"; then
     if test "$SYSTEM_BOOST" = "TRUE"; then
         dnl Link with Boost.System
diff --git a/download.lst b/download.lst
index 93699991656f..ce730f54d4f9 100644
--- a/download.lst
+++ b/download.lst
@@ -554,8 +554,8 @@ OPENSSL_TARBALL := openssl-3.0.17.tar.gz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
-ORCUS_SHA256SUM := 
ec27f30e8445a2a3f307f7e829fc446fd48193150b7f8f23bb5bfb25ec6e4e27
-ORCUS_TARBALL := liborcus-0.20.1.tar.xz
+ORCUS_SHA256SUM := 
85fb0af34042108f2b6aa8e7f3994fe972fd79efe3f1cd01dc7a49b0ffc5ca13
+ORCUS_TARBALL := liborcus-0.20.2.tar.xz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
diff --git 
a/external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
 
b/external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
deleted file mode 100644
index 9d3b283ad252..000000000000
--- 
a/external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
+++ /dev/null
@@ -1,606 +0,0 @@
-From 5641adad370edf85df712fcd6c553273f515a868 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <[email protected]>
-Date: Fri, 18 Jul 2025 21:08:49 +0100
-Subject: [PATCH] const up some things and move them out of data section
-
----
- include/orcus/tokens.hpp                  |  4 +-
- misc/xml-tokens/gen-odf-tokens.py         |  4 +-
- misc/xml-tokens/token_util.py             |  4 +-
- src/liborcus/gnumeric_namespace_types.cpp |  4 +-
- src/liborcus/gnumeric_namespace_types.hpp |  2 +-
- src/liborcus/gnumeric_tokens.inl          |  4 +-
- src/liborcus/odf_namespace_types_cpp.inl  |  2 +-
- src/liborcus/odf_namespace_types_hpp.inl  |  2 +-
- src/liborcus/odf_tokens.inl               |  4 +-
- src/liborcus/ods_content_xml_context.cpp  |  2 +-
- src/liborcus/ooxml_content_types.cpp      |  4 +-
- src/liborcus/ooxml_content_types.hpp      |  2 +-
- src/liborcus/ooxml_namespace_types.cpp    | 12 +++---
- src/liborcus/ooxml_namespace_types.hpp    |  6 +--
- src/liborcus/ooxml_schemas.cpp            | 50 +++++++++++------------
- src/liborcus/ooxml_schemas.hpp            | 48 +++++++++++-----------
- src/liborcus/ooxml_tokens.inl             |  4 +-
- src/liborcus/opc_context.cpp              |  2 +-
- src/liborcus/opc_tokens.inl               |  4 +-
- src/liborcus/xls_xml_namespace_types.cpp  |  4 +-
- src/liborcus/xls_xml_namespace_types.hpp  |  2 +-
- src/liborcus/xls_xml_tokens.inl           |  4 +-
- src/liborcus/yaml_document_tree.cpp       | 12 +++---
- src/parser/tokens.cpp                     |  2 +-
- src/parser/types.cpp                      |  2 +-
- 25 files changed, 95 insertions(+), 95 deletions(-)
-
-diff --git a/include/orcus/tokens.hpp b/include/orcus/tokens.hpp
-index 9edc8771..fde4b924 100644
---- a/include/orcus/tokens.hpp
-+++ b/include/orcus/tokens.hpp
-@@ -31,7 +31,7 @@ class ORCUS_PSR_DLLPUBLIC tokens
- public:
-     tokens() = delete;
-     tokens(const tokens&) = delete;
--    tokens(const char** token_names, size_t token_name_count);
-+    tokens(const char* const* token_names, size_t token_name_count);
-     ~tokens();
- 
-     /**
-@@ -64,7 +64,7 @@ private:
-     using token_map_type = std::unordered_map<std::string_view, xml_token_t>;
- 
-     token_map_type m_tokens;
--    const char** m_token_names;
-+    const char* const* m_token_names;
-     size_t m_token_name_count;
- };
- 
-diff --git a/misc/xml-tokens/gen-odf-tokens.py 
b/misc/xml-tokens/gen-odf-tokens.py
-index 2838604b..af83ed80 100755
---- a/misc/xml-tokens/gen-odf-tokens.py
-+++ b/misc/xml-tokens/gen-odf-tokens.py
-@@ -98,7 +98,7 @@ def gen_namespace_tokens(filepath, ns_values):
-         outfile.write("extern const xmlns_id_t NS_odf_")
-         outfile.write(key)
-         outfile.write(";
")
--    outfile.write("
extern const xmlns_id_t* NS_odf_all;
")
-+    outfile.write("
extern const xmlns_id_t* const NS_odf_all;
")
-     outfile.write("
}

")
-     outfile.close()
- 
-@@ -125,7 +125,7 @@ def gen_namespace_tokens(filepath, ns_values):
-     outfile.write("};

")
-     outfile.write("} // anonymous

")
- 
--    outfile.write("const xmlns_id_t* NS_odf_all = odf_ns;

")
-+    outfile.write("const xmlns_id_t* const NS_odf_all = odf_ns;

")
- 
-     outfile.write("}

")
-     outfile.close()
-diff --git a/misc/xml-tokens/token_util.py b/misc/xml-tokens/token_util.py
-index 19ba4369..ddf637ac 100644
---- a/misc/xml-tokens/token_util.py
-+++ b/misc/xml-tokens/token_util.py
-@@ -57,7 +57,7 @@ def gen_token_names(outfile, tokens):
-         print(get_auto_gen_warning(), file=f)
-         print(file=f)
- 
--        print("const char* token_names[] = {", file=f)
-+        print("const char* const token_names[] = {", file=f)
-         print(f"    \"{unknown_token_name}\", // 0", file=f)
- 
-         for i, token in enumerate(tokens):
-@@ -67,4 +67,4 @@ def gen_token_names(outfile, tokens):
-             print(f"    \"{token}\"{s} // {i+1}", file=f)
-         print("};", file=f)
-         print(file=f)
--        print(f"size_t token_name_count = {len(tokens)+1};", file=f)
-+        print(f"const size_t token_name_count = {len(tokens)+1};", file=f)
-diff --git a/src/liborcus/gnumeric_namespace_types.cpp 
b/src/liborcus/gnumeric_namespace_types.cpp
-index 1ff0ec97..91c97c8f 100644
---- a/src/liborcus/gnumeric_namespace_types.cpp
-+++ b/src/liborcus/gnumeric_namespace_types.cpp
-@@ -18,7 +18,7 @@ const xmlns_id_t NS_gnumeric_xsi = 
"http://www.w3.org/2001/XMLSchema-instance";;
- 
- namespace {
- 
--xmlns_id_t gnumeric_ns[] = {
-+const xmlns_id_t gnumeric_ns[] = {
-     NS_gnumeric_dc,
-     NS_gnumeric_gnm,
-     NS_gnumeric_ooo,
-@@ -32,7 +32,7 @@ xmlns_id_t gnumeric_ns[] = {
- 
- }
- 
--const xmlns_id_t* NS_gnumeric_all = gnumeric_ns;
-+const xmlns_id_t* const NS_gnumeric_all = gnumeric_ns;
- 
- }
- /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-diff --git a/src/liborcus/gnumeric_namespace_types.hpp 
b/src/liborcus/gnumeric_namespace_types.hpp
-index 2d6b7ab2..4fa89fc8 100644
---- a/src/liborcus/gnumeric_namespace_types.hpp
-+++ b/src/liborcus/gnumeric_namespace_types.hpp
-@@ -18,7 +18,7 @@ extern const xmlns_id_t NS_gnumeric_ooo;
- extern const xmlns_id_t NS_gnumeric_xlink;
- extern const xmlns_id_t NS_gnumeric_xsi;
- 
--extern const xmlns_id_t* NS_gnumeric_all;
-+extern const xmlns_id_t* const NS_gnumeric_all;
- 
- }
- 
-diff --git a/src/liborcus/gnumeric_tokens.inl 
b/src/liborcus/gnumeric_tokens.inl
-index c20fb69b..ecd8e74d 100644
---- a/src/liborcus/gnumeric_tokens.inl
-+++ b/src/liborcus/gnumeric_tokens.inl
-@@ -1,6 +1,6 @@
- // This file has been auto-generated.  Do not hand-edit this.
- 
--const char* token_names[] = {
-+const char* const token_names[] = {
-     "??", // 0
-     "Active", // 1
-     "AllowBlank", // 2
-@@ -279,4 +279,4 @@ const char* token_names[] = {
-     "width"  // 275
- };
- 
--size_t token_name_count = 276;
-+const size_t token_name_count = 276;
-diff --git a/src/liborcus/odf_namespace_types_cpp.inl 
b/src/liborcus/odf_namespace_types_cpp.inl
-index 8b0dc1ff..a91959a3 100644
---- a/src/liborcus/odf_namespace_types_cpp.inl
-+++ b/src/liborcus/odf_namespace_types_cpp.inl
-@@ -57,7 +57,7 @@ const xmlns_id_t odf_ns[] = {
- 
- } // anonymous
- 
--const xmlns_id_t* NS_odf_all = odf_ns;
-+const xmlns_id_t* const NS_odf_all = odf_ns;
- 
- }
- 
-diff --git a/src/liborcus/odf_namespace_types_hpp.inl 
b/src/liborcus/odf_namespace_types_hpp.inl
-index a80c9173..75941235 100644
---- a/src/liborcus/odf_namespace_types_hpp.inl
-+++ b/src/liborcus/odf_namespace_types_hpp.inl
-@@ -25,7 +25,7 @@ extern const xmlns_id_t NS_odf_xforms;
- extern const xmlns_id_t NS_odf_xhtml;
- extern const xmlns_id_t NS_odf_xlink;
- 
--extern const xmlns_id_t* NS_odf_all;
-+extern const xmlns_id_t* const NS_odf_all;
- 
- }
- 
-diff --git a/src/liborcus/odf_tokens.inl b/src/liborcus/odf_tokens.inl
-index 623c7216..21c85618 100644
---- a/src/liborcus/odf_tokens.inl
-+++ b/src/liborcus/odf_tokens.inl
-@@ -1,6 +1,6 @@
- // This file has been auto-generated.  Do not hand-edit this.
- 
--const char* token_names[] = {
-+const char* const token_names[] = {
-     "??", // 0
-     "0", // 1
-     "0deg", // 2
-@@ -2282,4 +2282,4 @@ const char* token_names[] = {
-     "zero-values"  // 2278
- };
- 
--size_t token_name_count = 2279;
-\ No newline at end of file
-+const size_t token_name_count = 2279;
-diff --git a/src/liborcus/ods_content_xml_context.cpp 
b/src/liborcus/ods_content_xml_context.cpp
-index bd84b2f8..18c56276 100644
---- a/src/liborcus/ods_content_xml_context.cpp
-+++ b/src/liborcus/ods_content_xml_context.cpp
-@@ -34,7 +34,7 @@ namespace cell_value {
- using map_type = 
mdds::sorted_string_map<ods_content_xml_context::cell_value_type>;
- 
- // Keys must be sorted.
--map_type::entry_type entries[] = {
-+constexpr map_type::entry_type entries[] = {
-     { "date",   ods_content_xml_context::vt_date },
-     { "float",  ods_content_xml_context::vt_float },
-     { "string", ods_content_xml_context::vt_string }
-diff --git a/src/liborcus/ooxml_content_types.cpp 
b/src/liborcus/ooxml_content_types.cpp
-index eb614c7b..13e78d15 100644
---- a/src/liborcus/ooxml_content_types.cpp
-+++ b/src/liborcus/ooxml_content_types.cpp
-@@ -37,7 +37,7 @@ const content_type_t CT_image_png                   = 
"image/png";
- 
- namespace {
- 
--content_type_t cts[] = {
-+const content_type_t cts[] = {
-     CT_ooxml_extended_properties,
-     CT_ooxml_drawing,
-     CT_ooxml_vml_drawing,
-@@ -68,7 +68,7 @@ content_type_t cts[] = {
- 
- }
- 
--const content_type_t* CT_all = cts;
-+const content_type_t* const CT_all = cts;
- 
- }
- /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-diff --git a/src/liborcus/ooxml_content_types.hpp 
b/src/liborcus/ooxml_content_types.hpp
-index d82dd53f..af8ab7c7 100644
---- a/src/liborcus/ooxml_content_types.hpp
-+++ b/src/liborcus/ooxml_content_types.hpp
-@@ -41,7 +41,7 @@ extern const content_type_t CT_image_png;
- /**
-  * Null-terminated array of all content types.
-  */
--extern const content_type_t* CT_all;
-+extern const content_type_t* const CT_all;
- 
- }
- 
-diff --git a/src/liborcus/ooxml_namespace_types.cpp 
b/src/liborcus/ooxml_namespace_types.cpp
-index 8c1224b2..31b26d2d 100644
---- a/src/liborcus/ooxml_namespace_types.cpp
-+++ b/src/liborcus/ooxml_namespace_types.cpp
-@@ -22,7 +22,7 @@ const xmlns_id_t NS_mso_x14 = 
"http://schemas.microsoft.com/office/spreadsheetml
- 
- namespace {
- 
--xmlns_id_t ooxml_ns[] = {
-+const xmlns_id_t ooxml_ns[] = {
-     NS_ooxml_a,
-     NS_ooxml_r,
-     NS_ooxml_xdr,
-@@ -30,13 +30,13 @@ xmlns_id_t ooxml_ns[] = {
-     nullptr
- };
- 
--xmlns_id_t opc_ns[] = {
-+const xmlns_id_t opc_ns[] = {
-     NS_opc_ct,
-     NS_opc_rel,
-     nullptr
- };
- 
--xmlns_id_t misc_ns[] = {
-+const xmlns_id_t misc_ns[] = {
-     NS_mc,
-     NS_mso_x14,
-     nullptr
-@@ -44,9 +44,9 @@ xmlns_id_t misc_ns[] = {
- 
- }
- 
--const xmlns_id_t* NS_ooxml_all = ooxml_ns;
--const xmlns_id_t* NS_opc_all = opc_ns;
--const xmlns_id_t* NS_misc_all = misc_ns;
-+const xmlns_id_t* const NS_ooxml_all = ooxml_ns;
-+const xmlns_id_t* const NS_opc_all = opc_ns;
-+const xmlns_id_t* const NS_misc_all = misc_ns;
- 
- }
- /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-diff --git a/src/liborcus/ooxml_namespace_types.hpp 
b/src/liborcus/ooxml_namespace_types.hpp
-index 8183bf89..5cd5f519 100644
---- a/src/liborcus/ooxml_namespace_types.hpp
-+++ b/src/liborcus/ooxml_namespace_types.hpp
-@@ -26,17 +26,17 @@ extern const xmlns_id_t NS_mso_x14;
- /**
-  * Null-terminated array of all ooxml namespaces.
-  */
--extern const xmlns_id_t* NS_ooxml_all;
-+extern const xmlns_id_t* const NS_ooxml_all;
- 
- /**
-  * Null-terminated array of all opc namespaces.
-  */
--extern const xmlns_id_t* NS_opc_all;
-+extern const xmlns_id_t* const NS_opc_all;
- 
- /**
-  * Null-terminated array of all the other namespaces.
-  */
--extern const xmlns_id_t* NS_misc_all;
-+extern const xmlns_id_t* const NS_misc_all;
- 
- }
- 
-diff --git a/src/liborcus/ooxml_schemas.cpp b/src/liborcus/ooxml_schemas.cpp
-index b0e86e49..22364ced 100644
---- a/src/liborcus/ooxml_schemas.cpp
-+++ b/src/liborcus/ooxml_schemas.cpp
-@@ -9,33 +9,33 @@
- 
- namespace orcus {
- 
--schema_t SCH_mc                           = 
"http://schemas.openxmlformats.org/markup-compatibility/2006";;
--schema_t SCH_opc_content_types            = 
"http://schemas.openxmlformats.org/package/2006/content-types";;
--schema_t SCH_opc_rels                     = 
"http://schemas.openxmlformats.org/package/2006/relationships";;
--schema_t SCH_opc_rels_metadata_core_props = 
"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties";;
--schema_t SCH_od_rels_calc_chain           = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/calcChain";;
--schema_t SCH_od_rels_connections          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/connections";;
--schema_t SCH_od_rels_printer_settings     = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/printerSettings";;
--schema_t SCH_od_rels_rev_headers          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/revisionHeaders";;
--schema_t SCH_od_rels_rev_log              = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/revisionLog";;
--schema_t SCH_od_rels_shared_strings       = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings";;
--schema_t SCH_od_rels_styles               = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles";;
--schema_t SCH_od_rels_theme                = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme";;
--schema_t SCH_od_rels_usernames            = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/usernames";;
--schema_t SCH_od_rels_worksheet            = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet";;
--schema_t SCH_od_rels_extended_props       = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties";;
--schema_t SCH_od_rels_office_doc           = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument";;
--schema_t SCH_od_rels_table                = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table";;
--schema_t SCH_od_rels_pivot_cache_def      = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheDefinition";;
--schema_t SCH_od_rels_pivot_cache_rec      = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheRecords";;
--schema_t SCH_od_rels_pivot_table          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotTable";;
--schema_t SCH_od_rels_drawing              = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing";;
--schema_t SCH_xlsx_main                    = 
"http://schemas.openxmlformats.org/spreadsheetml/2006/main";;
--schema_t SCH_mso_x14ac                    = 
"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac";;
-+const schema_t SCH_mc                           = 
"http://schemas.openxmlformats.org/markup-compatibility/2006";;
-+const schema_t SCH_opc_content_types            = 
"http://schemas.openxmlformats.org/package/2006/content-types";;
-+const schema_t SCH_opc_rels                     = 
"http://schemas.openxmlformats.org/package/2006/relationships";;
-+const schema_t SCH_opc_rels_metadata_core_props = 
"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties";;
-+const schema_t SCH_od_rels_calc_chain           = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/calcChain";;
-+const schema_t SCH_od_rels_connections          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/connections";;
-+const schema_t SCH_od_rels_printer_settings     = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/printerSettings";;
-+const schema_t SCH_od_rels_rev_headers          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/revisionHeaders";;
-+const schema_t SCH_od_rels_rev_log              = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/revisionLog";;
-+const schema_t SCH_od_rels_shared_strings       = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings";;
-+const schema_t SCH_od_rels_styles               = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles";;
-+const schema_t SCH_od_rels_theme                = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme";;
-+const schema_t SCH_od_rels_usernames            = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/usernames";;
-+const schema_t SCH_od_rels_worksheet            = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet";;
-+const schema_t SCH_od_rels_extended_props       = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties";;
-+const schema_t SCH_od_rels_office_doc           = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument";;
-+const schema_t SCH_od_rels_table                = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table";;
-+const schema_t SCH_od_rels_pivot_cache_def      = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheDefinition";;
-+const schema_t SCH_od_rels_pivot_cache_rec      = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheRecords";;
-+const schema_t SCH_od_rels_pivot_table          = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotTable";;
-+const schema_t SCH_od_rels_drawing              = 
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing";;
-+const schema_t SCH_xlsx_main                    = 
"http://schemas.openxmlformats.org/spreadsheetml/2006/main";;
-+const schema_t SCH_mso_x14ac                    = 
"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac";;
- 
- namespace {
- 
--schema_t schs[] = {
-+const schema_t schs[] = {
-     SCH_mc,
-     SCH_opc_content_types,
-     SCH_opc_rels,
-@@ -64,7 +64,7 @@ schema_t schs[] = {
- 
- }
- 
--schema_t* SCH_all = schs;
-+const schema_t* const SCH_all = schs;
- 
- }
- /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-diff --git a/src/liborcus/ooxml_schemas.hpp b/src/liborcus/ooxml_schemas.hpp
-index 85adb6f2..bb0c0a06 100644
---- a/src/liborcus/ooxml_schemas.hpp
-+++ b/src/liborcus/ooxml_schemas.hpp
-@@ -12,34 +12,34 @@
- 
- namespace orcus {
- 
--extern schema_t SCH_mc;
--extern schema_t SCH_opc_content_types;
--extern schema_t SCH_opc_rels;
--extern schema_t SCH_opc_rels_metadata_core_props;
--extern schema_t SCH_od_rels_calc_chain;
--extern schema_t SCH_od_rels_connections;
--extern schema_t SCH_od_rels_printer_settings;
--extern schema_t SCH_od_rels_rev_headers;
--extern schema_t SCH_od_rels_rev_log;
--extern schema_t SCH_od_rels_shared_strings;
--extern schema_t SCH_od_rels_styles;
--extern schema_t SCH_od_rels_theme;
--extern schema_t SCH_od_rels_usernames;
--extern schema_t SCH_od_rels_worksheet;
--extern schema_t SCH_od_rels_extended_props;
--extern schema_t SCH_od_rels_office_doc;
--extern schema_t SCH_od_rels_table;
--extern schema_t SCH_od_rels_pivot_cache_def;
--extern schema_t SCH_od_rels_pivot_cache_rec;
--extern schema_t SCH_od_rels_pivot_table;
--extern schema_t SCH_od_rels_drawing;
--extern schema_t SCH_xlsx_main;
--extern schema_t SCH_mso_x14ac;
-+const extern schema_t SCH_mc;
-+const extern schema_t SCH_opc_content_types;
-+const extern schema_t SCH_opc_rels;
-+const extern schema_t SCH_opc_rels_metadata_core_props;
-+const extern schema_t SCH_od_rels_calc_chain;
-+const extern schema_t SCH_od_rels_connections;
-+const extern schema_t SCH_od_rels_printer_settings;
-+const extern schema_t SCH_od_rels_rev_headers;
-+const extern schema_t SCH_od_rels_rev_log;
-+const extern schema_t SCH_od_rels_shared_strings;
-+const extern schema_t SCH_od_rels_styles;
-+const extern schema_t SCH_od_rels_theme;
-+const extern schema_t SCH_od_rels_usernames;
-+const extern schema_t SCH_od_rels_worksheet;
-+const extern schema_t SCH_od_rels_extended_props;
-+const extern schema_t SCH_od_rels_office_doc;
-+const extern schema_t SCH_od_rels_table;
-+const extern schema_t SCH_od_rels_pivot_cache_def;
-+const extern schema_t SCH_od_rels_pivot_cache_rec;
-+const extern schema_t SCH_od_rels_pivot_table;
-+const extern schema_t SCH_od_rels_drawing;
-+const extern schema_t SCH_xlsx_main;
-+const extern schema_t SCH_mso_x14ac;
- 
- /**
-  * Null-terminated array of all schema types.
-  */
--extern schema_t* SCH_all;
-+const extern schema_t* const SCH_all;
- 
- }
- 
-diff --git a/src/liborcus/ooxml_tokens.inl b/src/liborcus/ooxml_tokens.inl
-index 5fa2ad05..e9a74419 100644
---- a/src/liborcus/ooxml_tokens.inl
-+++ b/src/liborcus/ooxml_tokens.inl
-@@ -1,6 +1,6 @@
- // This file has been auto-generated.  Do not hand-edit this.
- 
--const char* token_names[] = {
-+const char* const token_names[] = {
-     "??", // 0
-     "AbbreviatedCaseNumber", // 1
-     "Accel", // 2
-@@ -3521,4 +3521,4 @@ const char* token_names[] = {
-     "zoomToFit"  // 3517
- };
- 
--size_t token_name_count = 3518;
-\ No newline at end of file
-+const size_t token_name_count = 3518;
-diff --git a/src/liborcus/opc_context.cpp b/src/liborcus/opc_context.cpp
-index e3b1bb57..a9936a2c 100644
---- a/src/liborcus/opc_context.cpp
-+++ b/src/liborcus/opc_context.cpp
-@@ -240,7 +240,7 @@ 
opc_relations_context::opc_relations_context(session_context& session_cxt, const
-     xml_context_base(session_cxt, _tokens)
- {
-     // build content type cache.
--    for (schema_t* p = SCH_all; *p; ++p)
-+    for (const schema_t* p = SCH_all; *p; ++p)
-         m_schema_cache.insert(std::string_view(*p));
- }
- 
-diff --git a/src/liborcus/opc_tokens.inl b/src/liborcus/opc_tokens.inl
-index 5f72a6a1..e8cc7c6d 100644
---- a/src/liborcus/opc_tokens.inl
-+++ b/src/liborcus/opc_tokens.inl
-@@ -1,6 +1,6 @@
- // This file has been auto-generated.  Do not hand-edit this.
- 
--const char* token_names[] = {
-+const char* const token_names[] = {
-     "??", // 0
-     "ContentType", // 1
-     "Default", // 2
-@@ -32,5 +32,5 @@ const char* token_names[] = {
-     "version"  // 28
- };
- 
--size_t token_name_count = 29;
-+const size_t token_name_count = 29;
- 
-diff --git a/src/liborcus/xls_xml_namespace_types.cpp 
b/src/liborcus/xls_xml_namespace_types.cpp
-index 96ccf6de..a93758f9 100644
---- a/src/liborcus/xls_xml_namespace_types.cpp
-+++ b/src/liborcus/xls_xml_namespace_types.cpp
-@@ -16,7 +16,7 @@ const xmlns_id_t NS_xls_xml_html 
="http://www.w3.org/TR/REC-html40";;
- 
- namespace {
- 
--xmlns_id_t xls_xml_ns[] = {
-+const xmlns_id_t xls_xml_ns[] = {
-     NS_xls_xml_ss,
-     NS_xls_xml_o,
-     NS_xls_xml_x,
-@@ -26,7 +26,7 @@ xmlns_id_t xls_xml_ns[] = {
- 
- }
- 
--const xmlns_id_t* NS_xls_xml_all = xls_xml_ns;
-+const xmlns_id_t* const NS_xls_xml_all = xls_xml_ns;
- 
- }
- /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
-diff --git a/src/liborcus/xls_xml_namespace_types.hpp 
b/src/liborcus/xls_xml_namespace_types.hpp
-index 37de5b0a..de7bf4a1 100644
---- a/src/liborcus/xls_xml_namespace_types.hpp
-+++ b/src/liborcus/xls_xml_namespace_types.hpp
-@@ -20,7 +20,7 @@ extern const xmlns_id_t NS_xls_xml_html;
- /**
-  * Null-terminated array of all xls xml namespaces.
-  */
--extern const xmlns_id_t* NS_xls_xml_all;
-+extern const xmlns_id_t* const NS_xls_xml_all;
- 
- }
- 
-diff --git a/src/liborcus/xls_xml_tokens.inl b/src/liborcus/xls_xml_tokens.inl
-index 73cd1fc5..ca961b97 100644
---- a/src/liborcus/xls_xml_tokens.inl
-+++ b/src/liborcus/xls_xml_tokens.inl
-@@ -1,6 +1,6 @@
- // This file has been auto-generated.  Do not hand-edit this.
- 
--const char* token_names[] = {
-+const char* const token_names[] = {
-     "??", // 0
-     "AcceptLabelsInFormulas", // 1
-     "Action", // 2
-@@ -994,4 +994,4 @@ const char* token_names[] = {
-     "yrange"  // 990
- };
- 
--size_t token_name_count = 991;
-+const size_t token_name_count = 991;
-diff --git a/src/liborcus/yaml_document_tree.cpp 
b/src/liborcus/yaml_document_tree.cpp
-index 1bd37a8b..c65793f4 100644
---- a/src/liborcus/yaml_document_tree.cpp
-+++ b/src/liborcus/yaml_document_tree.cpp
-@@ -558,11 +558,11 @@ const_node document_tree::get_document_root(size_t 
index) const
- 
- namespace {
- 
--const char* indent = "    ";
--const char* kw_true = "true";
--const char* kw_false = "false";
--const char* kw_tilde = "~";
--const char* kw_null = "null";
-+const char* const indent = "    ";
-+const char* const kw_true = "true";
-+const char* const kw_false = "false";
-+const char* const kw_tilde = "~";
-+const char* const kw_null = "null";
- 
- const char quote = '"';
- 
-@@ -812,7 +812,7 @@ void dump_json_node(std::ostringstream& os, const 
yaml_value& node, size_t scope
-     }
- }
- 
--const char* warning_multiple_documents =
-+const char* const warning_multiple_documents =
- "warning: this YAML file contains multiple documents.  Only the first document
"
- "will be written.";
- 
-diff --git a/src/parser/tokens.cpp b/src/parser/tokens.cpp
-index 5d3c5333..e28219f7 100644
---- a/src/parser/tokens.cpp
-+++ b/src/parser/tokens.cpp
-@@ -9,7 +9,7 @@
- 
- namespace orcus {
- 
--tokens::tokens(const char** token_names, size_t token_name_count) :
-+tokens::tokens(const char* const* token_names, size_t token_name_count) :
-     m_token_names(token_names), 
-     m_token_name_count(token_name_count)
- {
-diff --git a/src/parser/types.cpp b/src/parser/types.cpp
-index ae8843e2..fdf39cb0 100644
---- a/src/parser/types.cpp
-+++ b/src/parser/types.cpp
-@@ -1427,7 +1427,7 @@ std::ostream& operator<< (std::ostream& os, const 
date_time_t& v)
- 
- std::ostream& operator<< (std::ostream& os, format_t v)
- {
--    static const char* values[] = {
-+    static const char* const values[] = {
-         "unknown",
-         "ods",
-         "xlsx",
--- 
-2.49.0
-
diff --git a/external/liborcus/Library_orcus-parser.mk 
b/external/liborcus/Library_orcus-parser.mk
index ef1393a998d1..3680d57d41b4 100644
--- a/external/liborcus/Library_orcus-parser.mk
+++ b/external/liborcus/Library_orcus-parser.mk
@@ -30,6 +30,7 @@ $(eval $(call gb_Library_set_include,orcus-parser,\
 ))
 
 $(eval $(call gb_Library_add_defs,orcus-parser,\
+       -DHAVE_FILESYSTEM \
        -DBOOST_ALL_NO_LIB \
        -D__ORCUS_PSR_BUILDING_DLL \
 ))
diff --git a/external/liborcus/Library_orcus.mk 
b/external/liborcus/Library_orcus.mk
index 776f5c2f04ad..582dc6b6e474 100644
--- a/external/liborcus/Library_orcus.mk
+++ b/external/liborcus/Library_orcus.mk
@@ -31,6 +31,7 @@ $(eval $(call gb_Library_set_include,orcus,\
 ))
 
 $(eval $(call gb_Library_add_defs,orcus,\
+       -DHAVE_FILESYSTEM \
        -DBOOST_ALL_NO_LIB \
        -D__ORCUS_BUILDING_DLL \
        -D__ORCUS_GNUMERIC \
@@ -108,10 +109,12 @@ $(eval $(call 
gb_Library_add_generated_exception_objects,orcus,\
        UnpackedTarball/liborcus/src/liborcus/orcus_import_ods \
        UnpackedTarball/liborcus/src/liborcus/orcus_import_xlsx \
        UnpackedTarball/liborcus/src/liborcus/orcus_json \
+       UnpackedTarball/liborcus/src/liborcus/orcus_json_filter \
        UnpackedTarball/liborcus/src/liborcus/orcus_ods \
        UnpackedTarball/liborcus/src/liborcus/orcus_xls_xml \
        UnpackedTarball/liborcus/src/liborcus/orcus_xlsx \
        UnpackedTarball/liborcus/src/liborcus/orcus_xml \
+       UnpackedTarball/liborcus/src/liborcus/orcus_xml_filter \
        UnpackedTarball/liborcus/src/liborcus/orcus_xml_impl \
        UnpackedTarball/liborcus/src/liborcus/orcus_xml_map_def \
        UnpackedTarball/liborcus/src/liborcus/session_context \
diff --git a/external/liborcus/UnpackedTarball_liborcus.mk 
b/external/liborcus/UnpackedTarball_liborcus.mk
index da57d0de383c..705feccef8c0 100644
--- a/external/liborcus/UnpackedTarball_liborcus.mk
+++ b/external/liborcus/UnpackedTarball_liborcus.mk
@@ -13,19 +13,17 @@ $(eval $(call 
gb_UnpackedTarball_set_tarball,liborcus,$(ORCUS_TARBALL)))
 
 $(eval $(call gb_UnpackedTarball_update_autoconf_configs,liborcus))
 
-# 
external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
 
+# 
external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
 # upstream effort as: https://gitlab.com/orcus/orcus/-/merge_requests/225
 
 $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
        external/liborcus/rpath.patch.0 \
        external/liborcus/libtool.patch.0 \
-       
external/liborcus/0001-const-up-some-things-and-move-them-out-of-data-secti.patch
 \
 ))
 
 ifeq ($(OS),WNT)
 $(eval $(call gb_UnpackedTarball_add_patches,liborcus,\
        external/liborcus/windows-constants-hack.patch \
-       external/liborcus/win_path_utf16.patch \
 ))
 endif
 
diff --git a/external/liborcus/libtool.patch.0 
b/external/liborcus/libtool.patch.0
index 663dbd8099d7..7015c1edd18b 100644
--- a/external/liborcus/libtool.patch.0
+++ b/external/liborcus/libtool.patch.0
@@ -1,11 +1,11 @@
---- ltmain.sh.orig     2020-09-09 21:20:23.069433984 -0400
-+++ ltmain.sh  2020-09-09 21:27:13.168073996 -0400
-@@ -7373,7 +7373,7 @@
+--- ltmain.sh.orig     2025-08-18 22:24:46.033069332 -0400
++++ ltmain.sh  2025-08-18 22:27:25.705417808 -0400
+@@ -7555,7 +7555,7 @@
        -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
        
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
        
-O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
--      -specs=*|-fsanitize=*|-fuse-ld=*|-static-*|-fcilkplus)
-+      -specs=*|-fsanitize=*|-fuse-ld=*|--ld-path=*|-static-*|-fcilkplus)
-         func_quote_for_eval "$arg"
-       arg=$func_quote_for_eval_result
+-      -specs=*|-fsanitize=*|-fuse-ld=*|-static-*|-fcilkplus|-Wa,*)
++      -specs=*|-fsanitize=*|-fuse-ld=*|--ld-path=*|-static-*|-fcilkplus|-Wa,*)
+         func_quote_arg pretty "$arg"
+       arg=$func_quote_arg_result
          func_append compile_command " $arg"
diff --git a/external/liborcus/win_path_utf16.patch 
b/external/liborcus/win_path_utf16.patch
deleted file mode 100644
index 0a6781e728b3..000000000000
--- a/external/liborcus/win_path_utf16.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-diff --git a/src/parser/stream.cpp b/src/parser/stream.cpp
-index 00395f59ff25..8f385fb8965a 100644
---- a/src/parser/stream.cpp
-+++ b/src/parser/stream.cpp
-@@ -147,6 +147,14 @@ std::tuple<std::string_view, size_t, size_t> 
find_line_with_offset(std::string_v
-     return std::make_tuple(line, line_num, offset_on_line);
- }
- 
-+#ifdef _WIN32
-+std::wstring to_wstring(std::string_view s)
-+{
-+    std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>> conversion;
-+    return conversion.from_bytes(s.data(), s.data() + s.size());
-+}
-+#endif
-+
- } // anonymous namespace
- 
- struct file_content::impl
-@@ -162,8 +170,13 @@ struct file_content::impl
-     impl() : content_size(0), content(nullptr) {}
- 
-     impl(std::string_view filepath) :
-+#ifdef _WIN32
-+        content_size(fs::file_size(to_wstring(filepath))),
-+        mapped_file(to_wstring(filepath).c_str(), bip::read_only),
-+#else
-         content_size(fs::file_size(std::string{filepath}.c_str())),
-         mapped_file(std::string{filepath}.c_str(), bip::read_only),
-+#endif
-         mapped_region(mapped_file, bip::read_only, 0, content_size),
-         content(nullptr)
-     {
diff --git a/external/liborcus/windows-constants-hack.patch 
b/external/liborcus/windows-constants-hack.patch
index 28cf0997a168..7f79ae86c513 100644
--- a/external/liborcus/windows-constants-hack.patch
+++ b/external/liborcus/windows-constants-hack.patch
@@ -8,7 +8,7 @@ index ae571f5..539ce18 100644
 
 -#include "constants.inl"
 +#define ORCUS_MAJOR_VERSION 0
-+#define ORCUS_MINOR_VERSION 19
++#define ORCUS_MINOR_VERSION 20
 +#define ORCUS_MICRO_VERSION 2
 
  namespace orcus {
diff --git a/include/sal/log-areas.dox b/include/sal/log-areas.dox
index 984cf9c92041..a442a4d9a1eb 100644
--- a/include/sal/log-areas.dox
+++ b/include/sal/log-areas.dox
@@ -154,6 +154,7 @@ certain functionality.
 @li @c sc.orcus
 @li @c sc.orcus.autofilter
 @li @c sc.orcus.condformat
+@li @c sc.orcus.sheet
 @li @c sc.orcus.style
 @li @c sc.orcus.table
 @li @c sc.qa
diff --git a/sc/Library_scfilt.mk b/sc/Library_scfilt.mk
index e2cd534226d9..5c265503df12 100644
--- a/sc/Library_scfilt.mk
+++ b/sc/Library_scfilt.mk
@@ -240,6 +240,7 @@ $(eval $(call gb_Library_add_exception_objects,scfilt,\
        sc/source/filter/orcus/orcusfiltersimpl \
        sc/source/filter/orcus/xmlcontext \
        sc/source/filter/orcus/filterdetect \
+       sc/source/filter/orcus/utils \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/sc/source/filter/inc/orcus_utils.hxx 
b/sc/source/filter/inc/orcus_utils.hxx
new file mode 100644
index 000000000000..ca7e73db59f2
--- /dev/null
+++ b/sc/source/filter/inc/orcus_utils.hxx
@@ -0,0 +1,16 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#pragma once
+
+#include <rtl/ustring.hxx>
+
+#include <orcus/stream.hpp>
+
+orcus::file_content toFileContent(const OUString& rPath);
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/filter/inc/orcusinterface.hxx 
b/sc/source/filter/inc/orcusinterface.hxx
index 7d15b68c18c9..e3f666bb4cef 100644
--- a/sc/source/filter/inc/orcusinterface.hxx
+++ b/sc/source/filter/inc/orcusinterface.hxx
@@ -385,6 +385,8 @@ public:
                           std::string_view value) override;
     virtual void set_string(orcus::spreadsheet::row_t row, 
orcus::spreadsheet::col_t col,
                             orcus::spreadsheet::string_id_t sindex) override;
+    virtual void set_string(orcus::spreadsheet::row_t row, 
orcus::spreadsheet::col_t col,
+                            std::string_view s) override;
     virtual void set_value(orcus::spreadsheet::row_t row, 
orcus::spreadsheet::col_t col,
                            double value) override;
     virtual void set_bool(orcus::spreadsheet::row_t row, 
orcus::spreadsheet::col_t col,
diff --git a/sc/source/filter/orcus/interface.cxx 
b/sc/source/filter/orcus/interface.cxx
index ffd9068300b3..9481226689ab 100644
--- a/sc/source/filter/orcus/interface.cxx
+++ b/sc/source/filter/orcus/interface.cxx
@@ -1108,6 +1108,11 @@ void ScOrcusSheet::set_string(os::row_t row, os::col_t 
col, os::string_id_t sind
     cellInserted();
 }
 
+void ScOrcusSheet::set_string(os::row_t /*row*/, os::col_t /*col*/, 
std::string_view /*s*/)
+{
+    SAL_WARN("sc.orcus.sheet", "set_string() with non-indexed string is 
ignored for now");
+}
+
 void ScOrcusSheet::set_value(os::row_t row, os::col_t col, double value)
 {
     mrFactory.pushCellStoreToken(ScAddress(col, row, mnTab), value);
diff --git a/sc/source/filter/orcus/orcusfiltersimpl.cxx 
b/sc/source/filter/orcus/orcusfiltersimpl.cxx
index acb391f6e3a1..85a04df3ea2a 100644
--- a/sc/source/filter/orcus/orcusfiltersimpl.cxx
+++ b/sc/source/filter/orcus/orcusfiltersimpl.cxx
@@ -9,6 +9,7 @@
 
 #include <orcusfiltersimpl.hxx>
 #include <orcusinterface.hxx>
+#include <orcus_utils.hxx>
 #include <tokenarray.hxx>
 
 #include <osl/thread.hxx>
@@ -58,7 +59,7 @@ public:
         maTemp.CloseStream();
     }
 
-    OString getFileName() const { return maTemp.GetFileName().toUtf8(); }
+    OUString getFileName() const { return maTemp.GetFileName(); }
 };
 
 uno::Reference<task::XStatusIndicator> getStatusIndicator(const SfxMedium& 
rMedium)
@@ -81,7 +82,7 @@ bool loadFileContent(SfxMedium& rMedium, 
orcus::iface::import_filter& filter)
     {
         // memory-map the temp file and start the import
         CopiedTempStream aTemp(*pSrc);
-        orcus::file_content input(aTemp.getFileName());
+        auto input = toFileContent(aTemp.getFileName());
         filter.read_stream(input.str());
     }
     catch (const std::exception& e)
@@ -130,12 +131,7 @@ bool ScOrcusFiltersImpl::importODS_Styles(ScDocument& 
rDoc, OUString& aPath) con
 {
     try
     {
-#if defined _WIN32
-        OString aPath8 = OUStringToOString(aPath, RTL_TEXTENCODING_UTF8);
-#else
-        OString aPath8 = OUStringToOString(aPath, osl_getThreadTextEncoding());
-#endif
-        orcus::file_content content(aPath8);
+        auto content = toFileContent(aPath);
         ScOrcusFactory aFactory(rDoc);
         ScOrcusStyles aStyles(aFactory);
         orcus::import_ods::read_styles(content.str(), &aStyles);
diff --git a/sc/source/filter/orcus/utils.cxx b/sc/source/filter/orcus/utils.cxx
new file mode 100644
index 000000000000..61b6d6c542cf
--- /dev/null
+++ b/sc/source/filter/orcus/utils.cxx
@@ -0,0 +1,19 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include <orcus_utils.hxx>
+
+orcus::file_content toFileContent(const OUString& rPath)
+{
+#ifdef _WIN32
+    return orcus::file_content(rPath);
+#else
+    return orcus::file_content(rPath.toUtf8());
+#endif
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/filter/orcus/xmlcontext.cxx 
b/sc/source/filter/orcus/xmlcontext.cxx
index 8a15a52ad3a4..cda6546de0fc 100644
--- a/sc/source/filter/orcus/xmlcontext.cxx
+++ b/sc/source/filter/orcus/xmlcontext.cxx
@@ -9,6 +9,7 @@
 
 #include <orcusfiltersimpl.hxx>
 #include <orcusinterface.hxx>
+#include <orcus_utils.hxx>
 #include <orcusxml.hxx>
 #include <document.hxx>
 #include <tokenarray.hxx>
@@ -216,9 +217,6 @@ void ScOrcusXMLContextImpl::importXML(const 
ScOrcusImportXMLParam& rParam)
     if (osl::FileBase::getSystemPathFromFileURL(maPath, aSysPath) != 
osl::FileBase::E_None)
         return;
 
-    OString aOSysPath = OUStringToOString(aSysPath, RTL_TEXTENCODING_UTF8);
-    const char* path = aOSysPath.getStr();
-
     try
     {
         orcus::orcus_xml filter(maNsRepo, &aFactory, nullptr);
@@ -264,7 +262,7 @@ void ScOrcusXMLContextImpl::importXML(const 
ScOrcusImportXMLParam& rParam)
             filter.commit_range();
         }
 
-        orcus::file_content content(path);
+        orcus::file_content content = toFileContent(aSysPath);
         filter.read_stream(content.str());
 
         aFactory.finalize();

Reply via email to