Ticket #4349: boost-trunk-autolinking.0.patch

File boost-trunk-autolinking.0.patch, 6.9 KB (added by eckhardt@…, 12 years ago)

patch against trunk

  • boost/config/auto_link.hpp

    Patch for boost ticket #4349 (https://svn.boost.org/trac/boost/ticket/4349)
    
     
    6060
    6161BOOST_LIB_RT_OPT:     A suffix that indicates the runtime library used,
    6262                      contains one or more of the following letters after
    63                       a hiphen:
     63                      a hyphen:
    6464
    6565                      s      static runtime (dynamic if not present).
    6666                      g      debug/diagnostic runtime (release if not present).
    6767                      y      Python debug/diagnostic runtime (release if not present).
    6868                      d      debug build (release if not present).
    69                       g      debug/diagnostic runtime (release if not present).
    70                       p      STLPort Build.
     69                      p      STLport build.
     70                      n      STLport build without its IOStreams.
    7171
    7272BOOST_LIB_VERSION:    The Boost version, in the form x_y, for Boost version x.y.
    7373
     
    118118#if defined(BOOST_MSVC) && (BOOST_MSVC < 1300)
    119119
    120120#  ifdef UNDER_CE
    121      // vc6:
     121     // eVC4:
    122122#    define BOOST_LIB_TOOLSET "evc4"
    123123#  else
    124124     // vc6:
     
    195195#            define BOOST_LIB_RT_OPT "-gdp"
    196196#        elif defined(_DEBUG)\
    197197               && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    198 #            define BOOST_LIB_RT_OPT "-gydp"
    199 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    200 #            error "Build options aren't compatible with pre-built libraries"
     198#           define BOOST_LIB_RT_OPT "-ydp"
     199#           ifdef BOOST_LIB_DIAGNOSTIC
     200#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     201#           endif
    201202#        elif defined(_DEBUG)
    202 #            define BOOST_LIB_RT_OPT "-gdp"
    203 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    204 #            error "Build options aren't compatible with pre-built libraries"
     203#           define BOOST_LIB_RT_OPT "-dp"
     204#           ifdef BOOST_LIB_DIAGNOSTIC
     205#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     206#           endif
    205207#        else
    206208#            define BOOST_LIB_RT_OPT "-p"
    207209#        endif
     
    215217#            define BOOST_LIB_RT_OPT "-gdpn"
    216218#        elif defined(_DEBUG)\
    217219               && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    218 #            define BOOST_LIB_RT_OPT "-gydpn"
    219 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    220 #            error "Build options aren't compatible with pre-built libraries"
     220#           define BOOST_LIB_RT_OPT "-ydpn"
     221#           ifdef BOOST_LIB_DIAGNOSTIC
     222#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     223#           endif
    221224#        elif defined(_DEBUG)
    222 #            define BOOST_LIB_RT_OPT "-gdpn"
    223 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    224 #            error "Build options aren't compatible with pre-built libraries"
     225#           define BOOST_LIB_RT_OPT "-dpn"
     226#           ifdef BOOST_LIB_DIAGNOSTIC
     227#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     228#           endif
    225229#        else
    226230#            define BOOST_LIB_RT_OPT "-pn"
    227231#        endif
     
    229233#     else
    230234
    231235#        if defined(_DEBUG) && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    232 #            define BOOST_LIB_RT_OPT "-gyd"
     236#            define BOOST_LIB_RT_OPT "-yd"
    233237#        elif defined(_DEBUG)
    234 #            define BOOST_LIB_RT_OPT "-gd"
     238#            define BOOST_LIB_RT_OPT "-d"
    235239#        else
    236240#            define BOOST_LIB_RT_OPT
    237241#        endif
     
    249253#            define BOOST_LIB_RT_OPT "-sgdp"
    250254#        elif defined(_DEBUG)\
    251255               && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    252 #             define BOOST_LIB_RT_OPT "-sgydp"
    253 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    254 #            error "Build options aren't compatible with pre-built libraries"
     256#            define BOOST_LIB_RT_OPT "-sydp"
     257#           ifdef BOOST_LIB_DIAGNOSTIC
     258#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     259#           endif
    255260#        elif defined(_DEBUG)
    256 #             define BOOST_LIB_RT_OPT "-sgdp"
    257 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    258 #            error "Build options aren't compatible with pre-built libraries"
     261#            define BOOST_LIB_RT_OPT "-sdp"
     262#           ifdef BOOST_LIB_DIAGNOSTIC
     263#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     264#           endif
    259265#        else
    260266#            define BOOST_LIB_RT_OPT "-sp"
    261267#        endif
     
    269275#            define BOOST_LIB_RT_OPT "-sgdpn"
    270276#        elif defined(_DEBUG)\
    271277               && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    272 #             define BOOST_LIB_RT_OPT "-sgydpn"
    273 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    274 #            error "Build options aren't compatible with pre-built libraries"
     278#           define BOOST_LIB_RT_OPT "-sydpn"
     279#           ifdef BOOST_LIB_DIAGNOSTIC
     280#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     281#           endif
    275282#        elif defined(_DEBUG)
    276 #             define BOOST_LIB_RT_OPT "-sgdpn"
    277 #            pragma message("warning: STLPort debug versions are built with /D_STLP_DEBUG=1")
    278 #            error "Build options aren't compatible with pre-built libraries"
     283#           define BOOST_LIB_RT_OPT "-sdpn"
     284#           ifdef BOOST_LIB_DIAGNOSTIC
     285#              pragma message("warning: STLport debug versions are built with /D_STLP_DEBUG by default")
     286#           endif
    279287#        else
    280288#            define BOOST_LIB_RT_OPT "-spn"
    281289#        endif
     
    284292
    285293#        if defined(_DEBUG)\
    286294               && defined(BOOST_DEBUG_PYTHON) && defined(BOOST_LINKING_PYTHON)
    287 #             define BOOST_LIB_RT_OPT "-sgyd"
     295#             define BOOST_LIB_RT_OPT "-syd"
    288296#        elif defined(_DEBUG)
    289 #             define BOOST_LIB_RT_OPT "-sgd"
     297#             define BOOST_LIB_RT_OPT "-sd"
    290298#        else
    291299#            define BOOST_LIB_RT_OPT "-s"
    292300#        endif
     
    307315// sanity check:
    308316//
    309317#if defined(__STL_DEBUG) || defined(_STLP_DEBUG)
    310 #error "Pre-built versions of the Boost libraries are not provided in STLPort-debug form"
     318#error "Pre-built versions of the Boost libraries are not provided in STLport-debug form"
    311319#endif
    312320
    313321#  ifdef _RTLDLL