diff options
Diffstat (limited to 'sal')
-rw-r--r-- | sal/CppunitTest_Module_DLL.mk | 1 | ||||
-rw-r--r-- | sal/CppunitTest_sal_osl.mk | 1 | ||||
-rw-r--r-- | sal/CppunitTest_sal_osl_security.mk | 1 | ||||
-rw-r--r-- | sal/CppunitTest_sal_rtl.mk | 1 | ||||
-rw-r--r-- | sal/CppunitTest_sal_types.mk | 1 | ||||
-rw-r--r-- | sal/Executable_cppunittester.mk | 1 | ||||
-rw-r--r-- | sal/Executable_osl_process_child.mk | 1 | ||||
-rw-r--r-- | sal/Library_sal.mk | 1 | ||||
-rw-r--r-- | sal/Library_sal_textenc.mk | 1 | ||||
-rw-r--r-- | sal/Library_uwinapi.mk | 48 | ||||
-rw-r--r-- | sal/Module_sal.mk | 2 | ||||
-rw-r--r-- | sal/systools/win32/uwinapi/legacy.c | 35 | ||||
-rw-r--r-- | sal/systools/win32/uwinapi/snprintf.c | 31 | ||||
-rw-r--r-- | sal/systools/win32/uwinapi/sntprintf.c | 120 | ||||
-rw-r--r-- | sal/systools/win32/uwinapi/snwprintf.c | 26 | ||||
-rw-r--r-- | sal/systools/win32/uwinapi/uwinapi.def | 8 |
16 files changed, 0 insertions, 279 deletions
diff --git a/sal/CppunitTest_Module_DLL.mk b/sal/CppunitTest_Module_DLL.mk index 637159992fb8..a00429de30d8 100644 --- a/sal/CppunitTest_Module_DLL.mk +++ b/sal/CppunitTest_Module_DLL.mk @@ -21,7 +21,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,Module_DLL,\ $(eval $(call gb_CppunitTest_use_libraries,Module_DLL,\ sal \ - $(gb_UWINAPI) \ )) # vim: set noet sw=4 ts=4: diff --git a/sal/CppunitTest_sal_osl.mk b/sal/CppunitTest_sal_osl.mk index 7432ff9a1c36..d96ab2d41483 100644 --- a/sal/CppunitTest_sal_osl.mk +++ b/sal/CppunitTest_sal_osl.mk @@ -27,7 +27,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,sal_osl,\ $(eval $(call gb_CppunitTest_use_libraries,sal_osl,\ sal \ - $(gb_UWINAPI) \ )) # the test uses the library created by Module_DLL diff --git a/sal/CppunitTest_sal_osl_security.mk b/sal/CppunitTest_sal_osl_security.mk index 6c75b7ca5dc3..0a0905c00734 100644 --- a/sal/CppunitTest_sal_osl_security.mk +++ b/sal/CppunitTest_sal_osl_security.mk @@ -16,7 +16,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,sal_osl_security,\ $(eval $(call gb_CppunitTest_use_libraries,sal_osl_security,\ sal \ - $(gb_UWINAPI) \ )) # vim: set noet sw=4 ts=4: diff --git a/sal/CppunitTest_sal_rtl.mk b/sal/CppunitTest_sal_rtl.mk index b69e330a87a6..43533fc5ab1c 100644 --- a/sal/CppunitTest_sal_rtl.mk +++ b/sal/CppunitTest_sal_rtl.mk @@ -50,7 +50,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,sal_rtl,\ $(eval $(call gb_CppunitTest_use_libraries,sal_rtl,\ sal \ - $(gb_UWINAPI) \ )) $(eval $(call gb_CppunitTest_set_include,sal_rtl,\ diff --git a/sal/CppunitTest_sal_types.mk b/sal/CppunitTest_sal_types.mk index 20a7c7240707..487d2f9a28a4 100644 --- a/sal/CppunitTest_sal_types.mk +++ b/sal/CppunitTest_sal_types.mk @@ -16,7 +16,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,sal_types,\ $(eval $(call gb_CppunitTest_use_libraries,sal_types,\ sal \ - $(gb_UWINAPI) \ )) # vim: set noet sw=4 ts=4: diff --git a/sal/Executable_cppunittester.mk b/sal/Executable_cppunittester.mk index f851c4d61083..509196b25ecd 100644 --- a/sal/Executable_cppunittester.mk +++ b/sal/Executable_cppunittester.mk @@ -17,7 +17,6 @@ $(eval $(call gb_Executable_set_include,cppunittester,\ $(eval $(call gb_Executable_use_libraries,cppunittester,\ sal \ - $(gb_UWINAPI) \ )) $(eval $(call gb_Executable_use_externals,cppunittester,\ diff --git a/sal/Executable_osl_process_child.mk b/sal/Executable_osl_process_child.mk index bbac3a54afa3..f64f9460541f 100644 --- a/sal/Executable_osl_process_child.mk +++ b/sal/Executable_osl_process_child.mk @@ -14,7 +14,6 @@ $(eval $(call gb_Executable_Executable,osl_process_child)) $(eval $(call gb_Executable_use_libraries,osl_process_child,\ sal \ - $(gb_UWINAPI) \ )) $(eval $(call gb_Executable_add_exception_objects,osl_process_child,\ diff --git a/sal/Library_sal.mk b/sal/Library_sal.mk index 4c047070df9d..0a2ccc4cf4cb 100644 --- a/sal/Library_sal.mk +++ b/sal/Library_sal.mk @@ -36,7 +36,6 @@ $(eval $(call gb_Library_use_libraries,sal,\ $(if $(filter $(OS),ANDROID), \ lo-bootstrap \ ) \ - $(gb_UWINAPI) \ )) $(eval $(call gb_Library_use_externals,sal,\ diff --git a/sal/Library_sal_textenc.mk b/sal/Library_sal_textenc.mk index 331b465434fd..15546ba4969e 100644 --- a/sal/Library_sal_textenc.mk +++ b/sal/Library_sal_textenc.mk @@ -14,7 +14,6 @@ $(eval $(call gb_Library_use_external,sal_textenc,boost_headers)) $(eval $(call gb_Library_use_libraries,sal_textenc,\ sal \ - $(gb_UWINAPI) \ )) $(eval $(call gb_Library_add_exception_objects,sal_textenc,\ diff --git a/sal/Library_uwinapi.mk b/sal/Library_uwinapi.mk deleted file mode 100644 index e9a00ab47551..000000000000 --- a/sal/Library_uwinapi.mk +++ /dev/null @@ -1,48 +0,0 @@ -# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- -# -# -# This file is part of the LibreOffice project. -# -# 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/. -# - -$(eval $(call gb_Library_Library,uwinapi)) - -$(eval $(call gb_Library_use_system_win32_libs,uwinapi,\ - $(if $(filter $(COM),MSC), \ - kernel32 \ - msvcrt \ - shlwapi \ - user32 \ - version \ - ) \ -)) - -$(eval $(call gb_Library_add_defs,uwinapi,\ - $(if $(filter $(COM),GCC), \ - -Wno-unused-parameter -Wno-return-type) \ -)) - -$(eval $(call gb_Library_add_cobjects,uwinapi,\ - sal/systools/win32/uwinapi/snprintf \ - sal/systools/win32/uwinapi/snwprintf \ -)) - -ifeq ($(COM),MSC) - -$(eval $(call gb_Library_add_cobjects,uwinapi,\ - sal/systools/win32/uwinapi/legacy \ -)) - -ifeq ($(VCVER),120) -$(eval $(call gb_Library_add_ldflags,uwinapi,\ - /DEF:$(SRCDIR)/sal/systools/win32/uwinapi/uwinapi.def \ -)) -endif - -endif - - -# vim: set noet sw=4 ts=4: diff --git a/sal/Module_sal.mk b/sal/Module_sal.mk index 3a40ed75105b..fe9523a7a6e2 100644 --- a/sal/Module_sal.mk +++ b/sal/Module_sal.mk @@ -15,8 +15,6 @@ $(eval $(call gb_Module_add_targets,sal,\ Library_lo-bootstrap) \ Library_sal \ $(if $(filter $(OS),ANDROID),,$(if $(filter TRUE,$(DISABLE_DYNLOADING)),,Library_sal_textenc)) \ - $(if $(filter $(OS),WNT), \ - Library_uwinapi) \ )) ifneq (,$(filter DESKTOP,$(BUILD_TYPE))) diff --git a/sal/systools/win32/uwinapi/legacy.c b/sal/systools/win32/uwinapi/legacy.c deleted file mode 100644 index e88c7524ed22..000000000000 --- a/sal/systools/win32/uwinapi/legacy.c +++ /dev/null @@ -1,35 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * 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/. - */ - -#define WIN32_LEAN_AND_MEAN -#include <windows.h> - -#ifdef _MSC_VER -#pragma warning(disable:4273) // inconsistent dll linkage -#endif - -#if (defined(_MSC_VER) && (_MSC_VER >= 1900)) || defined __clang__ -// older versions use uwinapi.def file for export -__declspec(dllexport) -#endif -DWORD WINAPI GetShortPathNameW(LPCWSTR lpszLongPath,LPWSTR lpszShortPath,DWORD cchBuffer) -{ - typedef DWORD (WINAPI * GetShortPathNameW_t) (LPCWSTR,LPWSTR,DWORD); - - GetShortPathNameW_t p_GetShortPathNameW = - (GetShortPathNameW_t) GetProcAddress ( - GetModuleHandle ("kernel32.dll"), "GetShortPathNameW"); - - if (p_GetShortPathNameW) - return p_GetShortPathNameW(lpszLongPath,lpszShortPath,cchBuffer); - else - return 0; -} - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sal/systools/win32/uwinapi/snprintf.c b/sal/systools/win32/uwinapi/snprintf.c deleted file mode 100644 index de927644404e..000000000000 --- a/sal/systools/win32/uwinapi/snprintf.c +++ /dev/null @@ -1,31 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -/* Not unicode */ -#undef _UNICODE - -/* Support MBCS and SBCS */ - -#ifndef _MBCS -#define _MBCS -#endif - -#include "sntprintf.c" - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sal/systools/win32/uwinapi/sntprintf.c b/sal/systools/win32/uwinapi/sntprintf.c deleted file mode 100644 index 22ce4f7d3050..000000000000 --- a/sal/systools/win32/uwinapi/sntprintf.c +++ /dev/null @@ -1,120 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#define LO_SNPRINTF_DLLIMPORT __declspec( dllexport ) - -#include <stdarg.h> -#include <stdio.h> - -#include <tchar.h> -#include <systools/win32/snprintf.h> - -#ifdef _MSC_VER -#pragma warning(disable:4273) // inconsistent dll linkage -#endif - -/* VS 2015 and above support ISO C snprintf */ -#if _MSC_VER < 1900 - -/* This function retrieves the pointer to the last character of a buffer. - That is the pointer to the last character of the buffer that fits - completely into that buffer or the position of the terminating zero. - - buffer Pointer to a _TXCHAR buffer to be examined - count size of the buffer to be examined - - return The pointer to the last character that fits into the buffer or - NULL if count is zero or count is one and the first byte was a - leading DBCS character -*/ - -static _TCHAR *GetLastBufferChar( _TCHAR *buffer, size_t count ) -{ - _TCHAR *last = NULL; - _TCHAR *cur = buffer; - - while ( (size_t)(cur - buffer) < count ) - { - last = cur; - - if ( !*last ) - break; - - cur = _tcsinc(last); - } - - return last; -} - - -/* Implementation of snprintf following the ISO/IEC 9899:1999 (ISO C99) standard */ - -LO_SNPRINTF_DLLIMPORT int __cdecl vsntprintf( _TCHAR *buffer, size_t count, const _TCHAR *format, va_list list ) -{ - int retval; - - /* First of all call the existing non POSIX standard function assuming - the buffer size will be large enough */ - - retval = _vsntprintf( buffer, count, format, list ); - - if ( retval < 0 ) - { - /* If the buffer wasn't large enough ensure that the buffer will be - zero terminated */ - - _TCHAR *last = GetLastBufferChar( buffer, count ); - if (last ) - *last = 0; - - /* Retrieve the count of characters that would have been written - if the buffer were large enough */ - - retval = _vsctprintf( format, list ); - } - else if ( (size_t)retval == count && count ) - { - /* If the buffer was large enough but not large enough for the trailing - zero make the buffer zero terminated */ - - _TCHAR *last = GetLastBufferChar( buffer, count ); - if (last ) - *last = 0; - } - - return retval; -} - -/* Implementation of snprintf following the ISO/IEC 9899:1999 (ISO C99) standard */ - -LO_SNPRINTF_DLLIMPORT int __cdecl sntprintf( _TCHAR *buffer, size_t count, const _TCHAR *format, ... ) -{ - va_list list; - int retval; - - va_start( list, format ); - retval = vsntprintf( buffer, count, format, list ); - va_end( list ); - - return retval; -} - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sal/systools/win32/uwinapi/snwprintf.c b/sal/systools/win32/uwinapi/snwprintf.c deleted file mode 100644 index cd076ae5795a..000000000000 --- a/sal/systools/win32/uwinapi/snwprintf.c +++ /dev/null @@ -1,26 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * 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/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#ifndef _UNICODE -#define _UNICODE -#endif - -#include "sntprintf.c" - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sal/systools/win32/uwinapi/uwinapi.def b/sal/systools/win32/uwinapi/uwinapi.def deleted file mode 100644 index f740fb1c160c..000000000000 --- a/sal/systools/win32/uwinapi/uwinapi.def +++ /dev/null @@ -1,8 +0,0 @@ -LIBRARY "uwinapi.dll" - -EXPORTS - GetShortPathNameW PRIVATE - snprintf - snwprintf - vsnprintf - vsnwprintf |