Ticket #30202: patch-thread_visibility.diff

File patch-thread_visibility.diff, 2.0 KB (added by ejtttje@…, 13 years ago)

fixes linkage visibility issues in exception and thread modules

  • boost/exception/exception.hpp

    diff -ru boost/exception/exception.hpp /opt/local/include/boost/exception/exception.hpp
    old new  
    310310    namespace
    311311    exception_detail
    312312        {
     313#if defined(__GNUC__)
     314# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     315#  pragma GCC visibility push (default)
     316# endif
     317#endif
    313318        template <class T>
    314319        struct
    315320        error_info_injector:
     
    326331                {
    327332                }
    328333            };
     334#if defined(__GNUC__)
     335# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     336#  pragma GCC visibility pop
     337# endif
     338#endif
    329339
    330340        struct large_size { char c[256]; };
    331341        large_size dispatch_boost_exception( exception const * );
     
    373383    namespace
    374384    exception_detail
    375385        {
     386#if defined(__GNUC__)
     387# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     388#  pragma GCC visibility push (default)
     389# endif
     390#endif
    376391        class
    377392        clone_base
    378393            {
     
    439454                throw*this;
    440455                }
    441456            };
     457#if defined(__GNUC__)
     458# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     459#  pragma GCC visibility pop
     460# endif
     461#endif
    442462        }
    443463
    444464    template <class T>
  • boost/thread/exceptions.hpp

    diff -ru boost/thread/exceptions.hpp /opt/local/include/boost/thread/exceptions.hpp
    old new  
    2121
    2222#include <boost/config/abi_prefix.hpp>
    2323
     24#if defined(__GNUC__)
     25# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     26#  pragma GCC visibility push (default)
     27# endif
     28#endif
     29
    2430namespace boost
    2531{
    2632
     
    177183
    178184} // namespace boost
    179185
     186#if defined(__GNUC__)
     187# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
     188#  pragma GCC visibility pop
     189# endif
     190#endif
     191
    180192#include <boost/config/abi_suffix.hpp>
    181193
    182194#endif