HaikuPorts
  • Login
  • Preferences
  • Help/Guide
  • Wiki
  • Timeline
  • Roadmap
  • View Tickets
  • Search
  • Port Log
  • Blog

Context Navigation

  • Back to Ticket #375

Ticket #375: boost-1.47.0.patch

File boost-1.47.0.patch, 11.8 KB (added by michaelvoliveira, 4 years ago)

Improved patch from 1.42 version. Don't need High Precision Clock hack anymore

  • boost/config/platform/haiku.hpp

    diff -Naur boost_1_47_0/boost/config/platform/haiku.cpp boost_1_47_0-haiku/boost/config/platform/haiku.cpp
    old new  
     1//  (C) Copyright John Maddock 2001.  
     2//  Use, modification and distribution are subject to the  
     3//  Boost Software License, Version 1.0. (See accompanying file  
     4//  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 
     5 
     6//  See http://www.boost.org for most recent version. 
     7 
     8//  Haiku specific config options: 
     9 
     10#define BOOST_PLATFORM "Haiku" 
     11 
     12#define BOOST_NO_INTRINSIC_WCHAR_T 
     13#define BOOST_HAS_UNISTD_H 
     14 
     15#define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS 
     16 
     17#define BOOST_HAS_THREADS 
     18 
     19// 
     20// thread API's not auto detected: 
     21// 
     22#define BOOST_HAS_SCHED_YIELD 
     23#define BOOST_HAS_NANOSLEEP 
     24#define BOOST_HAS_GETTIMEOFDAY 
     25#define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE 
     26#define BOOST_HAS_SIGACTION 
     27 
     28// boilerplate code: 
     29#include <boost/config/posix_features.hpp> 
  • boost/config/select_platform_config.hpp

    diff -Naur boost_1_47_0/boost/config/select_platform_config.hpp boost_1_47_0-haiku/boost/config/select_platform_config.hpp
    old new  
    4141// win32: 
    4242#  define BOOST_PLATFORM_CONFIG "boost/config/platform/win32.hpp" 
    4343 
     44#elif defined(__HAIKU__) 
     45// Haiku 
     46#  define BOOST_PLATFORM_CONFIG "boost/config/platform/haiku.hpp" 
     47 
    4448#elif defined(__BEOS__) 
    4549// BeOS 
    4650#  define BOOST_PLATFORM_CONFIG "boost/config/platform/beos.hpp" 
  • boost/config/stdlib/libstdcpp3.hpp

    diff -Naur boost_1_47_0/boost/config/stdlib/libstdcpp3.hpp boost_1_47_0-haiku/boost/config/stdlib/libstdcpp3.hpp
    old new  
    3333 
    3434#ifdef __GLIBCXX__ // gcc 3.4 and greater: 
    3535#  if defined(_GLIBCXX_HAVE_GTHR_DEFAULT) \ 
    36         || defined(_GLIBCXX__PTHREADS) 
     36        || defined(_GLIBCXX__PTHREADS) || defined(__HAIKU__) 
    3737      // 
    3838      // If the std lib has thread support turned on, then turn it on in Boost 
    3939      // as well.  We do this because some gcc-3.4 std lib headers define _REENTANT 
  • boost/interprocess/detail/workaround.hpp

    diff -Naur boost_1_47_0/boost/interprocess/detail/workaround.hpp boost_1_47_0-haiku/boost/interprocess/detail/workaround.hpp
    old new  
    6464   #endif 
    6565 
    6666   //Check for XSI shared memory objects. They are available in nearly all UNIX platforms 
    67    #if !defined(__QNXNTO__) 
     67   #if !defined(__QNXNTO__) || !defined(__HAIKU__) 
    6868   # define BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS 
    6969   #endif 
    7070 
  • boost/interprocess/mapped_region.hpp

    diff -Naur boost_1_47_0/boost/interprocess/mapped_region.hpp boost_1_47_0-haiku/boost/interprocess/mapped_region.hpp
    old new  
    3131#    include <unistd.h> 
    3232#    include <sys/stat.h> 
    3333#    include <sys/types.h> 
     34#  if !defined(__HAIKU__) 
    3435#    if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) 
    3536#      include <sys/shm.h>      //System V shared memory... 
    3637#    endif 
     38#  endif 
    3739#    include <boost/assert.hpp> 
    3840#  else 
    3941#    error Unknown platform 
    … …  
    396398   mapping_handle_t map_hnd = mapping.get_mapping_handle(); 
    397399 
    398400   //Some systems dont' support XSI shared memory 
     401   # if !defined(__HAIKU__) 
    399402   #ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS 
    400403   if(map_hnd.is_xsi){ 
    401404      //Get the size 
    … …  
    438441      return; 
    439442   } 
    440443   #endif   //ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS 
     444   #endif   //Haiku 
    441445   if(size == 0){ 
    442446      struct ::stat buf; 
    443447      if(0 != fstat(map_hnd.handle, &buf)){ 
    … …  
    547551inline void mapped_region::priv_close() 
    548552{ 
    549553   if(m_base != MAP_FAILED){ 
     554                # if !defined(__HAIKU__) 
    550555      #ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS 
    551556      if(m_is_xsi){ 
    552557         int ret = ::shmdt(m_base); 
    … …  
    555560         return; 
    556561      } 
    557562      #endif //#ifdef BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS 
     563        #endif //Haiku 
    558564      munmap(static_cast<char*>(m_base) - m_extra_offset, m_size + m_extra_offset); 
    559565      m_base = MAP_FAILED; 
    560566   } 
  • boost/math/tools/config.hpp

    diff -Naur boost_1_47_0/boost/math/tools/config.hpp boost_1_47_0-haiku/boost/math/tools/config.hpp
    old new  
    2424#include <boost/math/special_functions/detail/round_fwd.hpp> 
    2525 
    2626#if (defined(__CYGWIN__) || defined(__FreeBSD__) || defined(__NetBSD__) \ 
    27    || defined(__hppa) || defined(__NO_LONG_DOUBLE_MATH)) && !defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) 
     27    || defined(__HAIKU__) || defined(__hppa) || defined(__NO_LONG_DOUBLE_MATH)) && !defined(BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS) 
    2828#  define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS 
    2929#endif 
    3030#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x582)) 
  • boost/thread/detail/platform.hpp

    diff -Naur boost_1_47_0/boost/thread/detail/platform.hpp boost_1_47_0-haiku/boost/thread/detail/platform.hpp
    old new  
    3131#  define BOOST_THREAD_CYGWIN 
    3232#elif (defined(_WIN32) || defined(__WIN32__) || defined(WIN32)) && !defined(BOOST_DISABLE_WIN32) 
    3333#  define BOOST_THREAD_WIN32 
     34#elif defined(__HAIKU__) 
     35#  define BOOST_THREAD_HAIKU 
    3436#elif defined(__BEOS__) 
    3537#  define BOOST_THREAD_BEOS 
    3638#elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__) 
  • tools/build/v2/engine/boehm_gc/include/private/gcconfig.h

    diff -Naur boost_1_47_0/tools/build/v2/engine/boehm_gc/include/private/gcconfig.h boost_1_47_0-haiku/tools/build/v2/engine/boehm_gc/include/private/gcconfig.h
    old new  
    210210#   endif 
    211211#   define mach_type_known 
    212212# endif 
     213# if defined(__HAIKU__) && defined(_X86_) 
     214#    define I386 
     215#    define HAIKU 
     216#    define mach_type_known 
     217# endif 
    213218# if defined(__BEOS__) && defined(_X86_) 
    214219#    define I386 
    215220#    define BEOS 
    … …  
    10071012#       define DATASTART ((ptr_t)((((word) (etext)) + 0xfff) & ~0xfff)) 
    10081013#       define STACKBOTTOM ((ptr_t) 0x3ffff000)  
    10091014#   endif 
     1015#   ifdef HAIKU 
     1016#     define OS_TYPE "HAIKU" 
     1017#     include <OS.h> 
     1018#     define GETPAGESIZE() B_PAGE_SIZE 
     1019      extern int etext[]; 
     1020#     define DATASTART ((ptr_t)((((word) (etext)) + 0xfff) & ~0xfff)) 
     1021#   endif 
    10101022#   ifdef BEOS 
    10111023#     define OS_TYPE "BEOS" 
    10121024#     include <OS.h> 
  • tools/build/v2/engine/fileunix.c

    diff -Naur boost_1_47_0/tools/build/v2/engine/fileunix.c boost_1_47_0-haiku/tools/build/v2/engine/fileunix.c
    old new  
    8080# endif 
    8181 
    8282# if defined( OS_QNX ) || \ 
     83         defined( OS_HAIKU ) || \ 
    8384     defined( OS_BEOS ) || \ 
    8485     defined( OS_MPEIX ) 
    8586# define NO_AR 
  • tools/build/v2/engine/jam.h

    diff -Naur boost_1_47_0/tools/build/v2/engine/jam.h boost_1_47_0-haiku/tools/build/v2/engine/jam.h
    old new  
    228228    #define OSMINOR "OS=AMIGA" 
    229229    #define OS_AMIGA 
    230230#endif 
     231#ifdef __HAIKU__ 
     232   #define unix 
     233   #define OSMINOR "OS=HAIKU" 
     234   #define OS_HAIKU 
     235#endif 
    231236#ifdef __BEOS__ 
    232237    #define unix 
    233238    #define OSMINOR "OS=BEOS" 
  • tools/build/v2/engine/Jambase

    diff -Naur boost_1_47_0/tools/build/v2/engine/Jambase boost_1_47_0-haiku/tools/build/v2/engine/Jambase
    old new  
    827827    SUFLIB      ?= .lib ; 
    828828    SUFOBJ      ?= .o ; 
    829829} 
     830else if $(OS) = HAIKU 
     831{ 
     832    BINDIR      ?= /boot/common/bin ; 
     833    CC          ?= gcc ; 
     834    C++         ?= $(CC) ; 
     835    FORTRAN     ?= "" ; 
     836    LIBDIR      ?= /boot/develop/lib/x86 ; 
     837    LINK        ?= gcc ; 
     838    LINKLIBS    ?= -lnetwork ; 
     839    NOARSCAN    ?= true ; 
     840    STDHDRS     ?= /boot/develop/headers/posix ; 
     841} 
     842 
    830843else if $(OS) = BEOS && $(METROWERKS) 
    831844{ 
    832845    AR          ?= mwld -xml -o ; 
  • tools/build/v2/engine/jambase.c

    diff -Naur boost_1_47_0/tools/build/v2/engine/jambase.c boost_1_47_0-haiku/tools/build/v2/engine/jambase.c
    old new  
    548548"NOARSCAN    ?= true ;\n", 
    549549"STDHDRS     ?= /boot/develop/headers/posix ;\n", 
    550550"}\n", 
     551"else if $(OS) = HAIKU\n", 
     552"{\n", 
     553"BINDIR      ?= /boot/common/bin ;\n", 
     554"CC          ?= gcc ;\n", 
     555"C++         ?= $(CC) ;\n", 
     556"FORTRAN     ?= \"\" ;\n", 
     557"LIBDIR      ?= /boot/develop/lib/x86 ;\n", 
     558"LINK        ?= gcc ;\n", 
     559"LINKLIBS    ?= -lnetwork ;\n", 
     560"NOARSCAN    ?= true ;\n", 
     561"STDHDRS     ?= /boot/develop/headers/posix ;\n", 
     562"}\n", 
     563 
    551564"else if $(OS) = BEOS\n", 
    552565"{\n", 
    553566"BINDIR      ?= /boot/apps ;\n", 
  • tools/build/v2/tools/builtin.jam

    diff -Naur boost_1_47_0/tools/build/v2/tools/builtin.jam boost_1_47_0-haiku/tools/build/v2/tools/builtin.jam
    old new  
    4040 
    4141 
    4242.os-names = aix bsd cygwin darwin freebsd hpux iphone linux netbsd 
    43     openbsd osf qnx qnxnto sgi solaris unix unixware windows  
     43    openbsd osf qnx qnxnto sgi solaris unix unixware windows haiku 
    4444    elf # Not actually an OS -- used for targeting bare metal where 
    4545        # object format is ELF.  This catches both -elf and -eabi gcc 
    4646        # targets and well as other compilers targeting ELF. It is not 
    … …  
    7878            case MACOSX       : host-os = darwin  ; 
    7979            case KFREEBSD     : host-os = freebsd ; 
    8080            case LINUX        : host-os = linux   ; 
     81            case HAIKU        : host-os = haiku   ; 
    8182            case SUNOS        :  
    8283              ECHO "SunOS is not a supported operating system." ; 
    8384              ECHO "We believe last version of SunOS was released in 1992, " ; 
  • tools/build/v2/tools/gcc.jam

    diff -Naur boost_1_47_0/tools/build/v2/tools/gcc.jam boost_1_47_0-haiku/tools/build/v2/tools/gcc.jam
    old new  
    951951 
    952952actions link bind LIBRARIES 
    953953{ 
    954     "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,$(RPATH) -Wl,-rpath-link$(SPACE)-Wl,"$(RPATH_LINK)" -o "$(<)" $(START-GROUP) "$(>)" "$(LIBRARIES)" $(FINDLIBS-ST-PFX) -l$(FINDLIBS-ST) $(FINDLIBS-SA-PFX) -l$(FINDLIBS-SA) $(END-GROUP) $(OPTIONS) $(USER_OPTIONS) 
     954    "$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" "$(.IMPLIB-COMMAND)$(<[1])" -o "$(<[-1])" $(HAVE_SONAME)-Wl,$(SONAME_OPTION)$(SPACE)-Wl,$(<[-1]:D=) -nostart -Wl,-shared $(START-GROUP) "$(>)" "$(LIBRARIES)" $(FINDLIBS-ST-PFX) -l$(FINDLIBS-ST) $(FINDLIBS-SA-PFX) -l$(FINDLIBS-SA) $(END-GROUP) $(OPTIONS) $(USER_OPTIONS) 
    955955 
    956956} 
    957957 
    … …  
    10431043                option = -pthreads ; 
    10441044                libs = rt ; 
    10451045            } 
     1046            case haiku : 
     1047            { 
     1048                # pthread 
     1049            } 
    10461050            case beos : 
    10471051            {             
    10481052                # BeOS has no threading options, so do not set anything here. 

Download in other formats:

  • Original Format

Trac Powered

Powered by Trac 0.13dev-r10686
By Edgewall Software.

Visit the Trac open source project at
http://trac.edgewall.org/