diff options
author | Carsten Driesner <cd@openoffice.org> | 2010-06-07 13:16:44 +0200 |
---|---|---|
committer | Carsten Driesner <cd@openoffice.org> | 2010-06-07 13:16:44 +0200 |
commit | e54612ea425f775ef22ba038dba697540d916eaa (patch) | |
tree | c240a88e600b4557181d7e7266c597e6aa461cc0 | |
parent | 0b7aa4d5b3f2fad7158531486a8f4f9c230a6640 (diff) |
fwk139: #i10000# Next idea to fix build problem with build bot
-rw-r--r-- | sfx2/source/doc/makefile.mk | 1 | ||||
-rwxr-xr-x | sfx2/source/doc/syspath.cxx | 46 | ||||
-rw-r--r-- | sfx2/source/doc/syspathw32.cxx | 21 |
3 files changed, 60 insertions, 8 deletions
diff --git a/sfx2/source/doc/makefile.mk b/sfx2/source/doc/makefile.mk index fd812297a8ab..69fee96ccf18 100644 --- a/sfx2/source/doc/makefile.mk +++ b/sfx2/source/doc/makefile.mk @@ -84,6 +84,7 @@ SLOFILES = \ $(SLO)$/sfxacldetect.obj \ $(SLO)$/docstoragemodifylistener.obj \ $(SLO)$/querytemplate.obj \ + $(SLO)$/syspath.obj \ $(SLO)$/syspathw32.obj # $(SLO)$/applet.obj \ diff --git a/sfx2/source/doc/syspath.cxx b/sfx2/source/doc/syspath.cxx new file mode 100755 index 000000000000..96bbee376306 --- /dev/null +++ b/sfx2/source/doc/syspath.cxx @@ -0,0 +1,46 @@ +/************************************************************************* +* +* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +* +* Copyright 2008 by Sun Microsystems, Inc. +* +* OpenOffice.org - a multi-platform office productivity suite +* +* $RCSfile: shutdowniconw32.cxx,v $ +* $Revision: 1.48 $ +* +* This file is part of OpenOffice.org. +* +* OpenOffice.org is free software: you can redistribute it and/or modify +* it under the terms of the GNU Lesser General Public License version 3 +* only, as published by the Free Software Foundation. +* +* OpenOffice.org is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Lesser General Public License version 3 for more details +* (a copy is included in the LICENSE file that accompanied this code). +* +* You should have received a copy of the GNU Lesser General Public License +* version 3 along with OpenOffice.org. If not, see +* <http://www.openoffice.org/license.html> +* for a copy of the LGPLv3 License. +* +************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +// Comment out precompiled statement due to redefinition errors +#include "precompiled_sfx2.hxx" + +#include "syspath.hxx" + +extern "C" bool GetUserTemplateLocation(sal_Unicode*, int nSize); + +bool SystemPath::GetUserTemplateLocation(sal_Unicode* pFolder, int nSize ) +{ +#ifdef WNT + return ::GetUserTemplateLocation( pFolder, nSize ); +#else + return false; +#endif +} diff --git a/sfx2/source/doc/syspathw32.cxx b/sfx2/source/doc/syspathw32.cxx index a47880bc0c0c..ba2e96f5b1f5 100644 --- a/sfx2/source/doc/syspathw32.cxx +++ b/sfx2/source/doc/syspathw32.cxx @@ -28,18 +28,23 @@ * ************************************************************************/ -// MARKER(update_precomp.py): autogen include statement, do not remove -// Comment out precompiled statement due to redefinition errors -//#include "precompiled_sfx2.hxx" - -#include "syspath.hxx" - #ifdef WNT #ifdef _MSC_VER #pragma warning(disable:4917) #endif #include <shlobj.h> +// Copied from sal/types.h to circumvent problems with precompiled headers +// and redefinitions of BOOL, INT32 and other types. Unfortunately tools +// also define these type incompatible with Win32 types which leads from +// time to time to very nasty compilation errors. If someone finds a better +// way to solve these probs please remove this copied part! +#if ( defined(WIN32) && !defined(__MINGW32__) ) + typedef wchar_t sal_Unicode; +#else + typedef sal_uInt16 sal_Unicode; +#endif + static bool _SHGetSpecialFolderW32( int nFolderID, WCHAR* pszFolder, int nSize ) { LPITEMIDLIST pidl; @@ -65,10 +70,10 @@ static bool _SHGetSpecialFolderW32( int nFolderID, WCHAR* pszFolder, int nSize ) #endif -bool SystemPath::GetUserTemplateLocation(sal_Unicode* pFolder, int nSize ) +extern "C" bool GetUserTemplateLocation(sal_Unicode* pFolder, int nSize) { #ifdef WNT - return _SHGetSpecialFolderW32(CSIDL_TEMPLATES, pFolder, nSize ); + return _SHGetSpecialFolderW32( CSIDL_TEMPLATES, pFolder, nSize ); #else return false; #endif |