From 574951a35985eed899923e4cee5c4153568c6d5e Mon Sep 17 00:00:00 2001 From: "Oleg.Korshul" Date: Wed, 5 Aug 2015 16:04:45 +0000 Subject: [PATCH] win64 git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@63898 954022d7-b5bf-4e40-9824-e11837661b57 --- DesktopEditor/xml/build/qt/libxml2.pri | 105 ++++++++++++------------- DjVuFile/DjVuFile.pro | 1 + HtmlFile/test/main.cpp | 6 +- HtmlRenderer/htmlrenderer.pro | 1 + HtmlRenderer/test/main.cpp | 18 ++++- XpsFile/XpsFile.pro | 1 + 6 files changed, 69 insertions(+), 63 deletions(-) diff --git a/DesktopEditor/xml/build/qt/libxml2.pri b/DesktopEditor/xml/build/qt/libxml2.pri index 222d5cf1cd..f42b85afdb 100644 --- a/DesktopEditor/xml/build/qt/libxml2.pri +++ b/DesktopEditor/xml/build/qt/libxml2.pri @@ -1,64 +1,57 @@ DEFINES += HAVE_VA_COPY INCLUDEPATH += \ - ../DesktopEditor/xml/libxml2/include \ - ../DesktopEditor/xml/libxml2/include/libxml \ - ../DesktopEditor/xml/build/qt + $$LIB_XML_PRI_PATH/libxml2/include \ + $$LIB_XML_PRI_PATH/libxml2/include/libxml \ + $$LIB_XML_PRI_PATH/build/qt SOURCES += \ - ../DesktopEditor/xml/libxml2/buf.c \ - ../DesktopEditor/xml/libxml2/c14n.c \ - ../DesktopEditor/xml/libxml2/catalog.c \ - ../DesktopEditor/xml/libxml2/chvalid.c \ - ../DesktopEditor/xml/libxml2/debugXML.c \ - ../DesktopEditor/xml/libxml2/dict.c \ - ../DesktopEditor/xml/libxml2/DOCBparser.c \ - ../DesktopEditor/xml/libxml2/encoding.c \ - ../DesktopEditor/xml/libxml2/entities.c \ - ../DesktopEditor/xml/libxml2/error.c \ - ../DesktopEditor/xml/libxml2/globals.c \ - ../DesktopEditor/xml/libxml2/HTMLparser.c \ - ../DesktopEditor/xml/libxml2/HTMLtree.c \ - ../DesktopEditor/xml/libxml2/legacy.c \ - ../DesktopEditor/xml/libxml2/list.c \ - ../DesktopEditor/xml/libxml2/nanoftp.c \ - ../DesktopEditor/xml/libxml2/nanohttp.c \ - ../DesktopEditor/xml/libxml2/parser.c \ - ../DesktopEditor/xml/libxml2/pattern.c \ - ../DesktopEditor/xml/libxml2/relaxng.c \ - ../DesktopEditor/xml/libxml2/SAX.c \ - ../DesktopEditor/xml/libxml2/SAX2.c \ - ../DesktopEditor/xml/libxml2/schematron.c \ - ../DesktopEditor/xml/libxml2/threads.c \ - ../DesktopEditor/xml/libxml2/tree.c \ - ../DesktopEditor/xml/libxml2/uri.c \ - ../DesktopEditor/xml/libxml2/valid.c \ - ../DesktopEditor/xml/libxml2/xinclude.c \ - ../DesktopEditor/xml/libxml2/xlink.c \ - ../DesktopEditor/xml/libxml2/xmlIO.c \ - ../DesktopEditor/xml/libxml2/xmlmemory.c \ - ../DesktopEditor/xml/libxml2/xmlmodule.c \ - ../DesktopEditor/xml/libxml2/xmlreader.c \ - ../DesktopEditor/xml/libxml2/xmlregexp.c \ - ../DesktopEditor/xml/libxml2/xmlsave.c \ - ../DesktopEditor/xml/libxml2/xmlschemas.c \ - ../DesktopEditor/xml/libxml2/xmlschemastypes.c \ - ../DesktopEditor/xml/libxml2/xmlstring.c \ - ../DesktopEditor/xml/libxml2/xmlunicode.c \ - ../DesktopEditor/xml/libxml2/xmlwriter.c \ - ../DesktopEditor/xml/libxml2/xpath.c \ - ../DesktopEditor/xml/libxml2/xpointer.c \ - ../DesktopEditor/xml/libxml2/parserInternals.c \ - ../DesktopEditor/xml/libxml2/hash.c + $$LIB_XML_PRI_PATH/libxml2/buf.c \ + $$LIB_XML_PRI_PATH/libxml2/c14n.c \ + $$LIB_XML_PRI_PATH/libxml2/catalog.c \ + $$LIB_XML_PRI_PATH/libxml2/chvalid.c \ + $$LIB_XML_PRI_PATH/libxml2/debugXML.c \ + $$LIB_XML_PRI_PATH/libxml2/dict.c \ + $$LIB_XML_PRI_PATH/libxml2/DOCBparser.c \ + $$LIB_XML_PRI_PATH/libxml2/encoding.c \ + $$LIB_XML_PRI_PATH/libxml2/entities.c \ + $$LIB_XML_PRI_PATH/libxml2/error.c \ + $$LIB_XML_PRI_PATH/libxml2/globals.c \ + $$LIB_XML_PRI_PATH/libxml2/HTMLparser.c \ + $$LIB_XML_PRI_PATH/libxml2/HTMLtree.c \ + $$LIB_XML_PRI_PATH/libxml2/legacy.c \ + $$LIB_XML_PRI_PATH/libxml2/list.c \ + $$LIB_XML_PRI_PATH/libxml2/nanoftp.c \ + $$LIB_XML_PRI_PATH/libxml2/nanohttp.c \ + $$LIB_XML_PRI_PATH/libxml2/parser.c \ + $$LIB_XML_PRI_PATH/libxml2/pattern.c \ + $$LIB_XML_PRI_PATH/libxml2/relaxng.c \ + $$LIB_XML_PRI_PATH/libxml2/SAX.c \ + $$LIB_XML_PRI_PATH/libxml2/SAX2.c \ + $$LIB_XML_PRI_PATH/libxml2/schematron.c \ + $$LIB_XML_PRI_PATH/libxml2/threads.c \ + $$LIB_XML_PRI_PATH/libxml2/tree.c \ + $$LIB_XML_PRI_PATH/libxml2/uri.c \ + $$LIB_XML_PRI_PATH/libxml2/valid.c \ + $$LIB_XML_PRI_PATH/libxml2/xinclude.c \ + $$LIB_XML_PRI_PATH/libxml2/xlink.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlIO.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlmemory.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlmodule.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlreader.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlregexp.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlsave.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlschemas.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlschemastypes.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlstring.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlunicode.c \ + $$LIB_XML_PRI_PATH/libxml2/xmlwriter.c \ + $$LIB_XML_PRI_PATH/libxml2/xpath.c \ + $$LIB_XML_PRI_PATH/libxml2/xpointer.c \ + $$LIB_XML_PRI_PATH/libxml2/parserInternals.c \ + $$LIB_XML_PRI_PATH/libxml2/hash.c SOURCES += \ - ../DesktopEditor/xml/src/xmllight.cpp \ - ../DesktopEditor/xml/src/xmldom.cpp - - -HEADERS += \ - ../XML/elfgcchack.h \ - ../XML/libxml.h - - + $$LIB_XML_PRI_PATH/src/xmllight.cpp \ + $$LIB_XML_PRI_PATH/src/xmldom.cpp diff --git a/DjVuFile/DjVuFile.pro b/DjVuFile/DjVuFile.pro index 8a76777684..4c281e840d 100644 --- a/DjVuFile/DjVuFile.pro +++ b/DjVuFile/DjVuFile.pro @@ -49,6 +49,7 @@ shared { LIBS += -L$$DESTDIR -lgraphics LIBS += -L$$DESTDIR -lPdfWriter + LIB_XML_PRI_PATH = ../DesktopEditor/xml include(../DesktopEditor/xml/build/qt/libxml2.pri) message(dynamic) diff --git a/HtmlFile/test/main.cpp b/HtmlFile/test/main.cpp index bc04c5a7bd..e5d3760d19 100644 --- a/HtmlFile/test/main.cpp +++ b/HtmlFile/test/main.cpp @@ -3,8 +3,8 @@ int main(int argc, char *argv[]) { -#if 0 - std::wstring sPath = NSFile::GetProcessDirectory() + L"/../../Internal/windows/Debug/"; +#ifdef WIN32 + std::wstring sPath = NSFile::GetProcessDirectory() + L"/../../Internal/windows/Release/"; std::wstring sXml = L"\ \ @@ -14,7 +14,7 @@ int main(int argc, char *argv[]) \ "; #else - std::wstring sPath = NSFile::GetProcessDirectory() + L"/../../Internal/linux/Debug/"; + std::wstring sPath = NSFile::GetProcessDirectory() + L"/../../Internal/linux/Release/"; std::wstring sXml = L"\ \ diff --git a/HtmlRenderer/htmlrenderer.pro b/HtmlRenderer/htmlrenderer.pro index e40965130b..4727ecb244 100644 --- a/HtmlRenderer/htmlrenderer.pro +++ b/HtmlRenderer/htmlrenderer.pro @@ -51,6 +51,7 @@ shared { LIBS += -L$$DESTDIR -lASCOfficeUtilsLib LIBS += -L$$DESTDIR -lgraphics + LIB_XML_PRI_PATH = ../DesktopEditor/xml include(../DesktopEditor/xml/build/qt/libxml2.pri) message(dynamic) diff --git a/HtmlRenderer/test/main.cpp b/HtmlRenderer/test/main.cpp index 0114d97131..4275fe3f34 100644 --- a/HtmlRenderer/test/main.cpp +++ b/HtmlRenderer/test/main.cpp @@ -5,6 +5,7 @@ #include "../../PdfReader/PdfReader.h" #include "../../DjVuFile/DjVu.h" #include "../../XpsFile/XpsFile.h" +#include "../../PdfWriter/PdfRenderer.h" #include "../include/HTMLRenderer3.h" int main(int argc, char *argv[]) @@ -21,8 +22,8 @@ int main(int argc, char *argv[]) #if 1 //std::wstring sFile = L"/home/oleg/activex/Android intro(2p).pdf"; - std::wstring sFile = L"/home/oleg/activex/knut.djvu"; - //std::wstring sFile = L"/home/oleg/activex/bankomats.xps"; + //std::wstring sFile = L"/home/oleg/activex/knut.djvu"; + std::wstring sFile = L"/home/oleg/activex/bankomats.xps"; std::wstring sDst = L"/home/oleg/activex/1"; #endif @@ -34,19 +35,24 @@ int main(int argc, char *argv[]) oReader.SetTempFolder(sDst.c_str()); #endif -#if 1 +#if 0 CDjVuFile oReader; #endif -#if 0 +#if 1 CXpsFile oReader(&oFonts); oReader.SetTempFolder(sDst.c_str()); #endif bool bResult = oReader.LoadFromFile(sFile.c_str()); +#if 0 NSHtmlRenderer::CASCHTMLRenderer3 oHtmlRenderer; oHtmlRenderer.CreateOfficeFile(sDst); +#else + CPdfRenderer oHtmlRenderer(&oFonts); + oHtmlRenderer.SetTempFolder(sDst); +#endif int nPagesCount = oReader.GetPagesCount(); for (int i = 0; i < nPagesCount; ++i) @@ -69,7 +75,11 @@ int main(int argc, char *argv[]) oHtmlRenderer.EndCommand(c_nPageType); } +#if 0 oHtmlRenderer.CloseFile(); +#else + oHtmlRenderer.SaveToFile(L"/home/oleg/activex/1/1.pdf"); +#endif return 0; } diff --git a/XpsFile/XpsFile.pro b/XpsFile/XpsFile.pro index aa1402c738..6991d093a2 100644 --- a/XpsFile/XpsFile.pro +++ b/XpsFile/XpsFile.pro @@ -49,6 +49,7 @@ shared { LIBS += -L$$DESTDIR -lgraphics LIBS += -L$$DESTDIR -lPdfWriter + LIB_XML_PRI_PATH = ../DesktopEditor/xml include(../DesktopEditor/xml/build/qt/libxml2.pri) message(dynamic)