Changeset 3960


Ignore:
Timestamp:
Aug 1, 2020, 6:17:31 AM (3 years ago)
Author:
Peter
Message:

closes #953. Since we are no longer using libboost_thread (or
underlying libbost_system), stop linking agaist them. Instead look for
needed compiler and extra LIBS needed for thread support.

Location:
trunk
Files:
1 added
2 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEWS

    r3938 r3960  
    77  - yat now requires GSL 1.13 or later (ticket #945)
    88  - Building against libbam is no longer supported (ticket #939)
     9  - libyat is no longer linked against libboost_system and
     10    libboost_thread (ticket #953)
     11  - macro YAT_HAVE_WORKING_BOOST_EXCEPTION_PTR is no longer #defined
     12    in yat/utility/config_public.h (ticket #953)
    913  - configure option --disable-cxx11 is no longer supported (ticket #949)
    1014  - configure option --without-samtools is no longer supported; use
  • trunk/configure.ac

    r3958 r3960  
    239239YAT_USE_LIBTOOL_PUSH
    240240
     241YAT_THREAD([
     242  CPPFLAGS="$CPPFLAGS $YAT_THREAD_CPPFLAGS"
     243  LIBS="$LIBS $YAT_THREAD_LIBS"
     244], [
     245  AC_MSG_FAILURE([$CXX does not work with std::thread])
     246])
     247
    241248# Checks for libraries.
    242249AC_MSG_NOTICE([checking for libraries])
     
    269276# skip boost link tests if boost is not wanted (--without-boost)
    270277AS_IF([test x"$want_boost" = x"yes"],[
    271   AX_BOOST_SYSTEM
    272   LIBS="$BOOST_SYSTEM_LIB $LIBS"
    273   AX_BOOST_THREAD
    274278  YAT_CPP_ADD_FLAG([CPPFLAGS], [$BOOST_CPPFLAGS])
    275279  YAT_LD_ADD_FLAG([LDFLAGS], [$BOOST_LDFLAGS])
    276   LIBS="$BOOST_THREAD_LIB $LIBS"
    277   # linking tests in AX_BOOST_SYSTEM occasionaly miss to detect
    278   # missing lib (see ticket #719), so link specifically here to catch
    279   # that case.
    280   AC_MSG_CHECKING([for boost::thread_specific_ptr])
    281   AC_LINK_IFELSE([AC_LANG_PROGRAM([@%:@include <boost/thread/tss.hpp>],
    282                                   [boost::thread_specific_ptr<int> x;
    283                                    x.reset(new int(1));])],
    284                  [AC_MSG_RESULT([yes])],
    285                  [AC_MSG_RESULT([no])
    286                   AC_MSG_FAILURE([Boost thread library not found.])
    287                  ])
    288   # Check if $BOOST_THREAD_LIB is appropriate for libyat.la
    289   YAT_CHECK_LA_LIBS([
    290     @%:@include <boost/thread.hpp>
    291     int my_func(void)
    292     { boost::mutex mutex_; return 0; }
    293   ], [$BOOST_THREAD_LIB $user_LIBS], [$BOOST_THREAD_LIB], [YAT_STATIC_LIBS])
    294   # Check if $BOOST_SYSTEM_LIB is appropriate for libyat.la
    295   YAT_CHECK_LA_LIBS([
    296     @%:@include <boost/system/error_code.hpp>
    297     int my_func(void)
    298     { boost::system::system_category; return 0; }
    299   ], [$BOOST_SYSTEM_LIB $user_LIBS], [$BOOST_SYSTEM_LIB], [YAT_STATIC_LIBS])
    300 
    301280  AX_BOOST_IOSTREAMS
    302281  LIBS="$BOOST_IOSTREAMS_LIB $LIBS"
     
    350329  [AC_MSG_RESULT([no])]
    351330)
    352 
    353 # Workaround problem that boost 1.41 does not work with certain versions of GCC
    354 # see ticket #762
    355 AC_MSG_CHECKING([if boost::mutex workaround is needed])
    356 AC_COMPILE_IFELSE(
    357   [AC_LANG_PROGRAM([@%:@include <boost/thread.hpp>],
    358                    [boost::mutex mutex;]
    359    )],
    360   [AC_MSG_RESULT([no])
    361    AC_DEFINE([YAT_HAVE_WORKING_BOOST_EXCEPTION_PTR], [1],
    362              [Define to 1 if boost::exception_ptr works])
    363   ],
    364   [AC_MSG_RESULT([yes])])
    365331
    366332# Check if boost::iterator_facade::operator-> works with a proxy class
Note: See TracChangeset for help on using the changeset viewer.