Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.10.0
    • Fix Version/s: 0.10.0
    • Component/s: Build
    • Labels:
      None
    • Environment:
      Microsoft Windows XP SP2, Visual Studio 6

      Description

      I found two strange problems:

      First problem described here - http://qaix.com/apache-http-server/543-372-patch-rand-c-for-win32-read.shtml . So I can fix it manually and resume build.

      Second problem produce many errors of that kind:

      [cc] messagebuffer.cpp
      [cc] D:\Projects\apache-log4cxx\src\main\include\log4cxx/helpers/messagebuffer.h(299) : error C2785: 'class std::basic_ostream<char,struct std::char_traits<char> > &_thiscall log4cxx::helpers::MessageBuffer::operator <<(T)' and 'class log4cxx::helpers::WideMessageBuffer &_thiscall log4cxx::helpers::MessageBuffer::operator <<(const class std::basic_string<unsigned short,struct std::char_traits<unsigned short>,class std::allocator<unsigned short> > &)' have different return types
      [cc] D:\Projects\apache-log4cxx\src\main\include\log4cxx/helpers/messagebuffer.h(287) : see declaration of '<<'
      [cc] D:\Projects\apache-log4cxx\src\main\include\log4cxx/helpers/messagebuffer.h(306) : error C2785: 'class std::basic_ostream<char,struct std::char_traits<char> > &_thiscall log4cxx::helpers::MessageBuffer::operator <<(T)' and 'class log4cxx::helpers::WideMessageBuffer &_thiscall log4cxx::helpers::MessageBuffer::operator <<(const unsigned short *)' have different return types
      [cc] D:\Projects\apache-log4cxx\src\main\include\log4cxx/helpers/messagebuffer.h(287) : see declaration of '<<'

      I hope you fix it bug soon.

      1. build_log.rar
        20 kB
        Alexander E. Sorokin
      2. build_log.zip
        35 kB
        Alexander E. Sorokin

        Activity

        Hide
        Curt Arnold added a comment -

        I've reworked several classes to work around limitations of VC6 (committed changes against LOGCXX-18 and LOGCXX-204). Rev 594589 or later should be good for VC6.

        Show
        Curt Arnold added a comment - I've reworked several classes to work around limitations of VC6 (committed changes against LOGCXX-18 and LOGCXX-204 ). Rev 594589 or later should be good for VC6.
        Hide
        Alexander E. Sorokin added a comment -

        Task isn't done. Revision 596567 produce this errors on vc6 build:

        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(224) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(230) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(239) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(247) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(253) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(263) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(273) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(287) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(295) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(296) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(315) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(321) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(330) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(338) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(344) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(354) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(364) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(378) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(386) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(387) : error C2593: 'operator <<' is ambiguous
        [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(438) : error C2593: 'operator <<' is ambiguous

        Show
        Alexander E. Sorokin added a comment - Task isn't done. Revision 596567 produce this errors on vc6 build: [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(224) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(230) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(239) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(247) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(253) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(263) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(273) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(287) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(295) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(296) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(315) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(321) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(330) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(338) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(344) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(354) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(364) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(378) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(386) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(387) : error C2593: 'operator <<' is ambiguous [cc] D:\Projects\Libraries\apache-log4cxx\src\test\cpp\streamtestcase.cpp(438) : error C2593: 'operator <<' is ambiguous
        Hide
        Curt Arnold added a comment -

        I haven't been able to reproduce the problem with either VC6 or VC7 on Windows 2000. Could you retry with a fresh checkout and confirm the version of VC in use (cl /?).

        Show
        Curt Arnold added a comment - I haven't been able to reproduce the problem with either VC6 or VC7 on Windows 2000. Could you retry with a fresh checkout and confirm the version of VC in use (cl /?).
        Hide
        Alexander E. Sorokin added a comment -

        This is the version of cl:

        Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86
        Copyright (C) Microsoft Corp 1984-1998. All rights reserved.

        Bug is still present on rev 597387.

        I'll attach a build log in next comment

        Show
        Alexander E. Sorokin added a comment - This is the version of cl: Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86 Copyright (C) Microsoft Corp 1984-1998. All rights reserved. Bug is still present on rev 597387. I'll attach a build log in next comment
        Hide
        Alexander E. Sorokin added a comment -

        Now you can see all messages

        Show
        Alexander E. Sorokin added a comment - Now you can see all messages
        Hide
        Curt Arnold added a comment -

        it may just be coincidence but my notebook immediately crashed while attempting to uncompress the Rar archive and will not reboot. I'm on the road for the holidays and will not be able to troubleshoot until I return home.

        I recently added MessageBuffer::operator<<(char*) and operator<<(wchar_t*) since msvc was using the templates function instead of the operator<<(const char*). You might try removing those to see if that wasvtge cause of the ambiguity.

        Show
        Curt Arnold added a comment - it may just be coincidence but my notebook immediately crashed while attempting to uncompress the Rar archive and will not reboot. I'm on the road for the holidays and will not be able to troubleshoot until I return home. I recently added MessageBuffer::operator<<(char*) and operator<<(wchar_t*) since msvc was using the templates function instead of the operator<<(const char*). You might try removing those to see if that wasvtge cause of the ambiguity.
        Hide
        Alexander E. Sorokin added a comment -

        Ok, I'll wait. I can also compress build log with zip.

        Show
        Alexander E. Sorokin added a comment - Ok, I'll wait. I can also compress build log with zip.
        Hide
        Curt Arnold added a comment -

        I'm now guessing that my repeated crashing is due to a battery issue and not the archive file, but I'm not in the mood to test it.

        I'm not able to reproduce the problem, but I'm using a slightly later build cl (12.00.8804) which I assume corresponds to VC 6 with SP6. Could you see if the problem goes away if you install the service pack?

        Show
        Curt Arnold added a comment - I'm now guessing that my repeated crashing is due to a battery issue and not the archive file, but I'm not in the mood to test it. I'm not able to reproduce the problem, but I'm using a slightly later build cl (12.00.8804) which I assume corresponds to VC 6 with SP6. Could you see if the problem goes away if you install the service pack?
        Hide
        Alexander E. Sorokin added a comment -

        On Compiler Version 12.00.8804 problems still exists.

        What can I do to help you to reproduce this problem on your computer?

        Show
        Alexander E. Sorokin added a comment - On Compiler Version 12.00.8804 problems still exists. What can I do to help you to reproduce this problem on your computer?
        Hide
        Curt Arnold added a comment -

        Try rev 598875. You will need to update log4cxx.h (do an "ant clean" before building).

        I have not been able to reproduce the problem, but I had seen it before and had a workaround which I reintroduced. The problem I was seeing was on the LocationInfo insertion in the LOG4CXX_ENDMSG macro. There was an explicit operator<< in the logstream and wlogstream classes and the template could not be resolved, but it still thought that the explicit operator and template were ambiguous. The kludge was to insert a nop manipulator and then use an extraction operator>> (which only exists in the class) for LocationInfo. I had left traces of the previous kludge in stream.h (wlogstream::operator>> remained).

        Show
        Curt Arnold added a comment - Try rev 598875. You will need to update log4cxx.h (do an "ant clean" before building). I have not been able to reproduce the problem, but I had seen it before and had a workaround which I reintroduced. The problem I was seeing was on the LocationInfo insertion in the LOG4CXX_ENDMSG macro. There was an explicit operator<< in the logstream and wlogstream classes and the template could not be resolved, but it still thought that the explicit operator and template were ambiguous. The kludge was to insert a nop manipulator and then use an extraction operator>> (which only exists in the class) for LocationInfo. I had left traces of the previous kludge in stream.h (wlogstream::operator>> remained).
        Hide
        Alexander E. Sorokin added a comment -

        Sorry, it's my fault. I used "rmdir target" instead of "ant clean". Now it works.

        Show
        Alexander E. Sorokin added a comment - Sorry, it's my fault. I used "rmdir target" instead of "ant clean". Now it works.
        Hide
        Alexander E. Sorokin added a comment -

        Now it works

        Show
        Alexander E. Sorokin added a comment - Now it works

          People

          • Assignee:
            Curt Arnold
            Reporter:
            Alexander E. Sorokin
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development