Log4cxx
  1. Log4cxx
  2. LOGCXX-8

Compilation problems using VC5 or VC6 with later Platform SDKs

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.7
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Thread starting at:
      http://nagoya.apache.org/eyebrowse/ReadMsg?listName=log4cxx-user@logging.apache.org&msgNo=165

      The major issue is that the prototypes for the InterlockedCompareExchange and similar methods were changed in the Platform SDK sometime after the release of VC6. The existing log4cxx code used #if _MSC_VER == 1200 to select whether to use the old form or the new form. That has two problems, VC5 is shipped with the old SDK but compiles with the new signature since its value of _MSC_VER is not equal to 1200 (it is less). Second, it is possible to use the older compiler with later Platform SDK's that use the new signatures. In that case, the compiler version is not a reliable indication of the form of the prototypes.

      The proposed solution is to add a distinct macro LOG4CXX_OLD_WIN32_INTERLOCKS that would control whether the old or new form are used. Unless set externally, this would be initialized in config_msvc.h based on the _MSC_VER.

      VC5 compilation had a few other issues where internal compiler errors would occur on valid C++ code.

      1. vc5.patch
        9 kB
        Curt Arnold

        Activity

        Curt Arnold created issue -
        Curt Arnold made changes -
        Field Original Value New Value
        Assignee Michaël CATANZARITI [ mcatan ] Curt Arnold [ carnold@apache.org ]
        Curt Arnold made changes -
        Attachment vc5.patch [ 14911 ]
        Curt Arnold made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]

          People

          • Assignee:
            Curt Arnold
            Reporter:
            Curt Arnold
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development