Skip to content

trivial build fixes #321

@wolpers

Description

@wolpers

I am evaluating POCO and building it via a custom cmake script. And also via the BB10 SDK, so not the default POCO build system. Which is probably why I found a few minor issues in the code that should probably be fixed. They are all trivial and obvious from the following patch snippets. I am not familiar with git, so please excuse that I do not provide a pull request. But the changes are really small.

/include/Poco/FileStream.h:

--- HEAD
+++ Modified In Working Tree
@@ -42,9 +42,9 @@

 #include "Poco/Foundation.h"
 #if defined(POCO_OS_FAMILY_WINDOWS)
-#include "FileStream_WIN32.h"
+#include "Poco/FileStream_WIN32.h"
 #else
-#include "FileStream_POSIX.h"
+#include "Poco/FileStream_POSIX.h"
 #endif
 #include <istream>
 #include <ostream>

/src/RegularExpression.cpp:

--- <html>RegularExpression.cpp (<b>30.10.2013 12:44:49</b>)</html>
+++ <html><b>Current File</b></html>
@@ -40,6 +40,7 @@
 #if defined(POCO_UNBUNDLED)
 #include <pcre.h>
 #else
+#include "pcre_config.h"
 #include "pcre.h"
 #endif

/src/LoggingFactory.cpp:

--- <html>LoggingFactory.cpp (<b>06.11.2013 15:12:17</b>)</html>
+++ <html><b>Current File</b></html>
@@ -42,14 +42,14 @@
 #include "Poco/FormattingChannel.h"
 #include "Poco/SplitterChannel.h"
 #include "Poco/NullChannel.h"
-#if defined(POCO_OS_FAMILY_UNIX)
+#if defined(POCO_OS_FAMILY_UNIX) && !defined(POCO_NO_SYSLOGCHANNEL)
 #include "Poco/SyslogChannel.h"
 #endif
 #if defined(POCO_OS_FAMILY_VMS)
 #include "Poco/OpcomChannel.h"
 #endif
 #if defined(POCO_OS_FAMILY_WINDOWS) && !defined(_WIN32_WCE)
-#include "Poco/EventLogChannel.h"
+//#include "Poco/EventLogChannel.h"
 #include "Poco/WindowsConsoleChannel.h"
 #endif
 #include "Poco/PatternFormatter.h"

/include/Poco/UnicodeConverter.h:

--- <html>UnicodeConverter.h (<b>Today 09:22:10</b>)</html>
+++ <html><b>Current File</b></html>
@@ -129,7 +129,7 @@
    }

    template <typename T>
-   static size_t UTFStrlen(const T* ptr)
+   static std::size_t UTFStrlen(const T* ptr)
        /// Returns the length (in characters) of a zero-terminated UTF string.
    {
        if (ptr == 0) return 0;

/src/UnicodeConverter.cpp:

--- <html>UnicodeConverter.cpp (<b>Today 09:22:10</b>)</html>
+++ <html><b>Current File</b></html>
@@ -78,7 +78,7 @@

 void UnicodeConverter::convert(const char* utf8String, UTF32String& utf32String)
 {
-   if (!utf8String || !strlen(utf8String))
+   if (!utf8String || !std::strlen(utf8String))
    {
        utf32String.clear();
        return;
@@ -125,7 +125,7 @@

 void UnicodeConverter::convert(const char* utf8String, UTF16String& utf16String)
 {
-   if (!utf8String || !strlen(utf8String))
+   if (!utf8String || !std::strlen(utf8String))
    {
        utf16String.clear();
        return;

/include/impl/Poco/Platform_POSIX.h:

--- <html>Platform_POSIX.h (<b>Today 09:22:09</b>)</html>
+++ <html><b>Current File</b></html>
@@ -109,4 +109,12 @@
 #endif // __GNUC__


+//
+// No syslog.h on QNX/BB10
+//
+#if defined(__QNXNTO__)
+#define POCO_NO_SYSLOGCHANNEL
+#endif
+
+
 #endif // Foundation_Platform_POSIX_INCLUDED

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions