Import of pkgsrc-2013Q2

This commit is contained in:
2013-09-26 17:14:40 +02:00
commit 785076ae39
74991 changed files with 4380255 additions and 0 deletions

4
meta-pkgs/boost/DESCR Normal file
View File

@@ -0,0 +1,4 @@
Boost is a set of free, peer-reviewed, C++ libraries. The emphasis is on
portable libraries which work well with the ISO C++ Standard Library.
This is a meta package that depends on all other components of Boost.

27
meta-pkgs/boost/Makefile Normal file
View File

@@ -0,0 +1,27 @@
# $NetBSD: Makefile,v 1.13 2010/08/26 17:40:59 adam Exp $
BOOST_PACKAGE= meta-pkg
BOOST_COMMENT= (meta package)
META_PACKAGE= yes
.include "Makefile.common"
BOOST_DEPENDS_VERSION= ${BOOST_SHORT_VERSION:S/_/./}{,nb*,.*}
CATEGORIES+= meta-pkgs
MASTER_SITES= # empty
DISTFILES= # empty
MAINTAINER= jmmv@NetBSD.org
HOMEPAGE= http://www.boost.org/
COMMENT= Free, peer-reviewed portable C++ source libraries
DEPENDS+= boost-build-${BOOST_DEPENDS_VERSION}:../../devel/boost-build
DEPENDS+= boost-docs-${BOOST_DEPENDS_VERSION}:../../devel/boost-docs
DEPENDS+= boost-headers-${BOOST_DEPENDS_VERSION}:../../devel/boost-headers
DEPENDS+= boost-jam-${BOOST_DEPENDS_VERSION}:../../devel/boost-jam
DEPENDS+= boost-libs-${BOOST_DEPENDS_VERSION}:../../devel/boost-libs
DEPENDS+= boost-python-${BOOST_DEPENDS_VERSION}:../../devel/boost-python
.include "../../mk/bsd.pkg.mk"

View File

@@ -0,0 +1,96 @@
# $NetBSD: Makefile.common,v 1.40 2013/02/12 21:07:22 adam Exp $
#
# used by devel/boost-build/Makefile
# used by devel/boost-docs/Makefile
# used by devel/boost-jam/Makefile
# used by devel/boost-headers/Makefile
# used by devel/boost-libs/Makefile
# used by devel/boost-python/Makefile
BOOST_PACKAGE?= undefined
BOOST_COMMENT?= undefined
BOOST_VERSION= 1.53.0
BOOST_SHORT_VERSION= ${BOOST_VERSION:S/./_/:C/\..*$//}
DISTNAME= boost_${BOOST_VERSION:S/./_/g}
CATEGORIES= devel
.if ${BOOST_PACKAGE} == "meta-pkg"
PKGNAME= boost-${BOOST_VERSION}
.else # ${BOOST_PACKAGE} != "meta-pkg"
PKGNAME= boost-${BOOST_PACKAGE}-${BOOST_VERSION}
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=boost/}
EXTRACT_SUFX= .tar.bz2
MAINTAINER= jmmv@NetBSD.org
HOMEPAGE= http://www.boost.org/
COMMENT= Free, peer-reviewed portable C++ source libraries ${BOOST_COMMENT}
LICENSE= boost-license
CONFLICTS+= boost<1.36.0
DISTINFO_FILE= ${.CURDIR}/../../meta-pkgs/boost/distinfo
PATCHDIR= ${.CURDIR}/../../meta-pkgs/boost/patches
USE_TOOLS+= pax
USE_LANGUAGES= c c++
GCC_REQD+= 3.2 # if using gcc; ignored otherwise
PLIST_SUBST+= BOOST_VERSION="${BOOST_VERSION}"
SUBST_CLASSES+= prefix
SUBST_STAGE.prefix= pre-configure
SUBST_MESSAGE.prefix= Fixing prefix.
SUBST_FILES.prefix= boostcpp.jam
SUBST_VARS.prefix= PREFIX
SUBST_CLASSES+= darwin
SUBST_STAGE.darwin= pre-configure
SUBST_MESSAGE.darwin= Fixing install_name for Darwin.
SUBST_FILES.darwin= tools/build/v2/tools/*darwin.jam
SUBST_SED.darwin= -e 's,-install_name ",-install_name "${PREFIX}/lib/,g'
.include "../../mk/bsd.prefs.mk"
# On SunOS, extract using pkgsrc nbtar to avoid warnings from native gtar.
.if ${OPSYS} == "SunOS"
TOOLS_PLATFORM.tar= #empty
.endif
.if ${OPSYS} == "Darwin"
# Prevent using a pkgsrc libtool in OS X because the darwin toolset needs
# the native libtool from /Developer/usr/bin or /usr/bin.
post-wrapper:
. if exists(/Developer/usr/bin/libtool)
ln -s /Developer/usr/bin/libtool ${WRAPPER_BINDIR}/libtool
. else
ln -s /usr/bin/libtool ${WRAPPER_BINDIR}/libtool
. endif
.endif
# We can't do this at post-extract because the extract cookie will get a future
# timestamp than the sources. If this happens, print-PLIST does not work.
pre-configure:
cd ${WRKSRC} && ${FIND} . -type f -print | ${XARGS} ${TOUCH}
# Generate a new user.hpp or use the installed one, depending on the package
# we are building.
.if ${BOOST_CONFIG} == "installed"
. include "../../devel/boost-headers/buildlink3.mk"
do-configure:
${CP} -f \
${BUILDLINK_PREFIX.boost-headers}/include/boost/config/user.hpp \
${WRKSRC}/boost/config/user.hpp
.elif ${BOOST_CONFIG} == "generate"
do-configure:
cd ${WRKSRC}/libs/config && \
${SETENV} ${CONFIGURE_ENV} ${SH} ./configure
${CP} -f ${WRKSRC}/libs/config/user.hpp ${WRKSRC}/boost/config/user.hpp
.endif
boost-install-libs:
${INSTALL_LIB_DIR} ${DESTDIR}${PREFIX}/lib
cd ${WRKSRC}/stage/lib && pax -rw -p p libboost* ${DESTDIR}${PREFIX}/lib
.endif # ${BOOST_PACKAGE} == "meta-pkg"

28
meta-pkgs/boost/distinfo Normal file
View File

@@ -0,0 +1,28 @@
$NetBSD: distinfo,v 1.58 2013/04/12 13:34:42 joerg Exp $
SHA1 (boost_1_53_0.tar.bz2) = e6dd1b62ceed0a51add3dda6f3fc3ce0f636a7f3
RMD160 (boost_1_53_0.tar.bz2) = 441435fca62365ddb822ab582594ae92c30cbc92
Size (boost_1_53_0.tar.bz2) = 55765258 bytes
SHA1 (patch-aa) = 408a63a807aaa491130db018cd89bca6a427090d
SHA1 (patch-ab) = f1c95ae229465a4d2da76ce6ff88d76ace52fdd8
SHA1 (patch-ac) = 32d14b50682dae1950ed927ecb9318ad6b07687a
SHA1 (patch-ad) = 0e5dc31c3425de94444f97a9b7dec97ed5967733
SHA1 (patch-ae) = 2fb49c90bbb3fd797ccdfaaf44c93494a5988f52
SHA1 (patch-ag) = c406e9beb9260db7861b13a6eb4c386f23346eb1
SHA1 (patch-ai) = 231db48819aa563b2082d95bb91d662b5d6cf779
SHA1 (patch-aq) = e5c7b72ffa2942ce401f3d9bf05498fd761df17a
SHA1 (patch-ar) = 2fec2c51272cc4ee376e6538d8f1fd8561a7f0a3
SHA1 (patch-boost_context_detail_fcontext__sparc.hpp) = 1f9cd1292669c13a8560817dec9632f21e6760e3
SHA1 (patch-boost_context_fcontext.hpp) = e7b79c6ad0397c3ba3be93a295e704b8e07bac9d
SHA1 (patch-boost_detail_endian.hpp) = ebd8d512ded732bfbf1f6ddd328612e95839f381
SHA1 (patch-boost_foreach.hpp) = 7cd26c4983873bcac284ad400950e341c559f9a8
SHA1 (patch-boost_foreach_fwd.hpp) = 5accd68d559213a9677f7d1204e72dd082a42a41
SHA1 (patch-libs_config_configure) = e2f204d4fa4f1bd9b4131d28f9be0a1ac22bf711
SHA1 (patch-libs_context_build_Jamfile.v2) = f695fe322e2cc4ea8174822e8582c5713e5c59fa
SHA1 (patch-libs_context_build_architecture.jam) = 878332ce8a71c1f13715c8e40a8a493abbdddfa2
SHA1 (patch-libs_context_config_Jamfile.jam) = f928575d5b93e86bbcd00bb25cf3e844de3361d1
SHA1 (patch-libs_context_config_sparc.cpp) = ec59ad331d3e5a71a1c1a9ec894e52e837ed3d51
SHA1 (patch-libs_context_src_asm_jump__sparc__sysv__elf__gas.S) = 4a417315198442dd4a013bb236b5666d7c547d49
SHA1 (patch-libs_context_src_asm_make__sparc__sysv__elf__gas.S) = 50dcd855f7b7d0ffc6ede794e04f5233bf664f54
SHA1 (patch-libs_filesystem_src_unique_path.cpp) = 4693ea11cf464d82168cecaa143b48affa94563b
SHA1 (patch-tools_build_v2_engine_hash.c) = 1137006f34eb8df3d7b1f5c29236300f8c6c1ef4

View File

@@ -0,0 +1,21 @@
# $NetBSD: options.mk,v 1.1 2009/03/03 08:57:58 jmmv Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.boost
PKG_SUPPORTED_OPTIONS= debug expat icu
.include "../../mk/bsd.options.mk"
.if ${BOOST_PACKAGE} == "libs"
.if !empty(PKG_OPTIONS:Mexpat)
MAKE_ENV+= EXPAT_INCLUDE=${PREFIX}/include
MAKE_ENV+= EXPAT_LIBPATH=${PREFIX}/lib
. include "../../textproc/expat/buildlink3.mk"
.endif
.if !empty(PKG_OPTIONS:Micu)
MAKE_ENV+= ICU_PATH=${PREFIX}
. include "../../textproc/icu/buildlink3.mk"
.endif
.endif # ${BOOST_PACKAGE} == "libs"

View File

@@ -0,0 +1,23 @@
$NetBSD: patch-aa,v 1.10 2012/08/27 08:49:09 adam Exp $
--- boostcpp.jam.orig 2012-07-27 18:15:55.000000000 +0000
+++ boostcpp.jam
@@ -249,6 +249,7 @@ rule declare_install_and_stage_proper_ta
: <location>$(stage-locate)/lib
<install-dependencies>on <install-type>LIB
<install-no-version-symlinks>on
+ <dll-path>@PREFIX@/lib
;
$(p).mark-target-as-explicit stage-proper ;
@@ -509,6 +510,10 @@ rule libraries-to-install ( existing-lib
{
EXIT error: both --with-<library> and --without-<library> specified ;
}
+ if $(without-parameter) && $(without-parameter) = "*"
+ {
+ without-parameter = $(existing-libs) ;
+ }
local wrong = [ set.difference $(with-parameter) : $(existing-libs) ] ;
if $(wrong)

View File

@@ -0,0 +1,22 @@
$NetBSD: patch-ab,v 1.5 2011/10/02 21:23:50 sbd Exp $
--- boost/config/platform/bsd.hpp.orig 2011-03-07 13:07:30.000000000 +0000
+++ boost/config/platform/bsd.hpp
@@ -37,7 +37,7 @@
// and not in <unistd.h>
//
#if (defined(__FreeBSD__) && (__FreeBSD__ <= 3))\
- || defined(__OpenBSD__) || defined(__DragonFly__)
+ || defined(__OpenBSD__) || defined(__DragonFly__) || defined(__NetBSD__)
# define BOOST_HAS_PTHREADS
#endif
@@ -62,7 +62,7 @@
//
// The BSD <ctype.h> has macros only, no functions:
//
-#if !defined(__OpenBSD__) || defined(__DragonFly__)
+#if !defined(__OpenBSD__) && !defined(__DragonFly__)
# define BOOST_NO_CTYPE_FUNCTIONS
#endif

View File

@@ -0,0 +1,13 @@
$NetBSD: patch-ac,v 1.8 2013/02/12 21:07:22 adam Exp $
--- boost/config/suffix.hpp.orig 2010-10-01 09:19:44.000000000 +0000
+++ boost/config/suffix.hpp
@@ -248,7 +248,7 @@
//
#if (defined(__MT__) || defined(_MT) || defined(_REENTRANT) \
|| defined(_PTHREADS) || defined(__APPLE__) || defined(__DragonFly__)) \
- && !defined(BOOST_HAS_THREADS)
+ || defined(__NetBSD__) && !defined(BOOST_HAS_THREADS)
# define BOOST_HAS_THREADS
#endif

View File

@@ -0,0 +1,22 @@
$NetBSD: patch-ad,v 1.12 2012/08/27 08:49:09 adam Exp $
--- boost/archive/basic_archive.hpp.orig 2012-08-27 07:38:03.000000000 +0000
+++ boost/archive/basic_archive.hpp
@@ -115,7 +115,7 @@ public:
explicit class_id_type(const int t_) : t(t_){
BOOST_ASSERT(t_ <= boost::integer_traits<base_type>::const_max);
}
- explicit class_id_type(const std::size_t t_) : t(t_){
+ explicit class_id_type(const size_t t_) : t(t_){
// BOOST_ASSERT(t_ <= boost::integer_traits<base_type>::const_max);
}
class_id_type(const class_id_type & t_) :
@@ -151,7 +151,7 @@ private:
public:
object_id_type(): t(0) {};
// note: presumes that size_t >= unsigned int.
- explicit object_id_type(const std::size_t & t_) : t(t_){
+ explicit object_id_type(const size_t & t_) : t(t_){
BOOST_ASSERT(t_ <= boost::integer_traits<base_type>::const_max);
}
object_id_type(const object_id_type & t_) :

View File

@@ -0,0 +1,14 @@
$NetBSD: patch-ae,v 1.7 2011/10/11 10:02:08 adam Exp $
Pass CFLAGS to the compiler.
--- tools/build/v2/engine/build.sh.orig 2011-02-24 08:42:55.000000000 +0000
+++ tools/build/v2/engine/build.sh
@@ -237,6 +237,7 @@ case $BOOST_JAM_TOOLSET in
error_exit "Unknown toolset: $BOOST_JAM_TOOLSET"
;;
esac
+BOOST_JAM_CC="${BOOST_JAM_CC} ${CFLAGS}"
echo "###"
echo "### Using '$BOOST_JAM_TOOLSET' toolset."

View File

@@ -0,0 +1,15 @@
$NetBSD: patch-ag,v 1.7 2012/07/02 07:02:26 adam Exp $
Pass CFLAGS to the compiler.
--- tools/build/v2/engine/build.jam.orig 2011-02-24 08:50:34.000000000 +0000
+++ tools/build/v2/engine/build.jam
@@ -192,7 +192,7 @@ toolset como como : "-o " : -D
: -L$(--python-lib[1]) -l$(--python-lib[2]) ;
## Clang Linux 2.8+
toolset clang clang : "-o " : -D
- : -Wno-unused -Wno-format
+ : $(CFLAGS) -Wno-unused -Wno-format
[ opt --release : -Os ]
[ opt --debug : -g -O0 -fno-inline ]
[ opt --profile : -finline-functions -g ]

View File

@@ -0,0 +1,30 @@
$NetBSD: patch-ai,v 1.5 2012/07/02 07:02:26 adam Exp $
https://svn.boost.org/trac/boost/ticket/6098
--- boost/asio/detail/impl/kqueue_reactor.ipp.orig 2011-11-06 17:01:14.000000000 +0000
+++ boost/asio/detail/impl/kqueue_reactor.ipp
@@ -290,9 +290,9 @@ void kqueue_reactor::deregister_descript
{
struct kevent events[2];
BOOST_ASIO_KQUEUE_EV_SET(&events[0], descriptor,
- EVFILT_READ, EV_DELETE, 0, 0, 0);
+ EVFILT_READ, EV_DELETE, 0, 0, (void*)0);
BOOST_ASIO_KQUEUE_EV_SET(&events[1], descriptor,
- EVFILT_WRITE, EV_DELETE, 0, 0, 0);
+ EVFILT_WRITE, EV_DELETE, 0, 0, (void*)0);
::kevent(kqueue_fd_, events, 2, 0, 0, 0);
}
@@ -331,9 +331,9 @@ void kqueue_reactor::deregister_internal
{
struct kevent events[2];
BOOST_ASIO_KQUEUE_EV_SET(&events[0], descriptor,
- EVFILT_READ, EV_DELETE, 0, 0, 0);
+ EVFILT_READ, EV_DELETE, 0, 0, (void*)0);
BOOST_ASIO_KQUEUE_EV_SET(&events[1], descriptor,
- EVFILT_WRITE, EV_DELETE, 0, 0, 0);
+ EVFILT_WRITE, EV_DELETE, 0, 0, (void*)0);
::kevent(kqueue_fd_, events, 2, 0, 0, 0);
op_queue<operation> ops;

View File

@@ -0,0 +1,30 @@
$NetBSD: patch-aq,v 1.6 2010/11/26 20:47:01 adam Exp $
--- boost/test/impl/execution_monitor.ipp.orig 2009-11-28 09:19:18.000000000 +0000
+++ boost/test/impl/execution_monitor.ipp
@@ -180,7 +180,8 @@ namespace { void _set_se_translator( voi
# if defined(SIGPOLL) && !defined(__CYGWIN__) && \
!(defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)) && \
!defined(__NetBSD__) && \
- !defined(__QNXNTO__)
+ !defined(__QNXNTO__) && \
+ !defined(__DragonFly__)
# define BOOST_TEST_CATCH_SIGPOLL
# endif
@@ -327,6 +328,7 @@ system_signal_exception::report() const
if( !m_sig_info )
return; // no error actually occur?
+#if !defined(__DragonFly__)
switch( m_sig_info->si_code ) {
case SI_USER:
report_error( execution_exception::system_error,
@@ -608,6 +610,7 @@ system_signal_exception::report() const
default:
report_error( execution_exception::system_error, "unrecognized signal" );
}
+#endif /* !__DragonFly__ */
}
//____________________________________________________________________________//

View File

@@ -0,0 +1,22 @@
$NetBSD: patch-ar,v 1.3 2012/07/02 07:02:26 adam Exp $
--- boost/property_tree/detail/xml_parser_read_rapidxml.hpp.orig 2010-10-15 12:40:04.000000000 +0000
+++ boost/property_tree/detail/xml_parser_read_rapidxml.hpp
@@ -106,13 +106,13 @@ namespace boost { namespace property_tre
try {
// Parse using appropriate flags
- const int f_tws = parse_normalize_whitespace
- | parse_trim_whitespace;
+ const int f_tws = (parse_normalize_whitespace
+ | parse_trim_whitespace);
const int f_c = parse_comment_nodes;
// Some compilers don't like the bitwise or in the template arg.
- const int f_tws_c = parse_normalize_whitespace
+ const int f_tws_c = (parse_normalize_whitespace
| parse_trim_whitespace
- | parse_comment_nodes;
+ | parse_comment_nodes);
xml_document<Ch> doc;
if (flags & no_comments) {
if (flags & trim_whitespace)

View File

@@ -0,0 +1,97 @@
$NetBSD: patch-boost_context_detail_fcontext__sparc.hpp,v 1.1 2013/01/20 09:06:59 martin Exp $
# Implementation details for sparc
--- /dev/null 2013-01-19 12:02:03.000000000 +0100
+++ boost/context/detail/fcontext_sparc.hpp 2013-01-19 19:21:19.000000000 +0100
@@ -0,0 +1,90 @@
+// Copyright Martin Husemann 2012
+// Distributed under the Boost Software License, Version 1.0.
+// (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+#ifndef BOOST_CTX_DETAIL_FCONTEXT_SPARC_H
+#define BOOST_CTX_DETAIL_FCONTEXT_SPARC_H
+
+#include <cstddef>
+
+#include <boost/config.hpp>
+#include <boost/cstdint.hpp>
+
+#include <boost/context/detail/config.hpp>
+
+#ifdef BOOST_HAS_ABI_HEADERS
+# include BOOST_ABI_PREFIX
+#endif
+
+namespace boost {
+namespace context {
+
+extern "C" {
+
+#define BOOST_CONTEXT_CALLDECL
+
+// if defined(_LP64) we are compiling for sparc64, otherwise it is 32 bit
+// sparc.
+
+
+struct stack_t
+{
+ void * sp;
+ std::size_t size;
+
+ stack_t() :
+ sp( 0), size( 0)
+ {}
+};
+
+struct fp_t
+{
+#ifdef _LP64
+ boost::uint64_t fp_freg[32];
+ boost::uint64_t fp_fprs, fp_fsr;
+#else
+ boost::uint64_t fp_freg[16];
+ boost::uint32_t fp_fsr;
+#endif
+
+ fp_t() :
+ fp_freg(),
+#ifdef _LP64
+ fp_fprs(),
+#endif
+ fp_fsr()
+ {}
+}
+#ifdef _LP64
+ __attribute__((__aligned__(64))) // allow VIS instructions to be used
+#endif
+;
+
+struct fcontext_t
+{
+ fp_t fc_fp; // fpu stuff first, for easier alignement
+#ifdef _LP64
+ boost::uint64_t
+#else
+ boost::uint32_t
+#endif
+ fc_greg[8];
+ stack_t fc_stack;
+
+ fcontext_t() :
+ fc_fp(),
+ fc_greg(),
+ fc_stack()
+ {}
+};
+
+}
+
+}}
+
+#ifdef BOOST_HAS_ABI_HEADERS
+# include BOOST_ABI_SUFFIX
+#endif
+
+#endif // BOOST_CTX_DETAIL_FCONTEXT_SPARC_H

View File

@@ -0,0 +1,16 @@
$NetBSD: patch-boost_context_fcontext.hpp,v 1.2 2013/02/12 21:07:22 adam Exp $
Add support for SPARC.
--- boost/context/fcontext.hpp.orig 2012-10-31 11:07:06.000000000 +0100
+++ boost/context/fcontext.hpp 2012-10-31 13:31:48.000000000 +0100
@@ -59,6 +59,9 @@
|| defined(__ppc__) || defined(_ARCH_PPC) || defined(__POWERPC__) \
|| defined(__PPCGECKO__) || defined(__PPCBROADWAY) || defined(_XENON)
# include <boost/context/detail/fcontext_ppc.hpp>
+#elif defined(__sparc__)
+// sparc or sparc64
+# include <boost/context/detail/fcontext_sparc.hpp>
#else
# error "platform not supported"
#endif

View File

@@ -0,0 +1,28 @@
$NetBSD: patch-boost_detail_endian.hpp,v 1.1 2013/01/24 22:54:49 riz Exp $
--- boost/detail/endian.hpp.orig 2011-03-29 14:58:48.000000000 -0700
+++ boost/detail/endian.hpp 2013-01-24 14:24:28.000000000 -0800
@@ -43,6 +43,23 @@
# error Unknown machine endianness detected.
# endif
# define BOOST_BYTE_ORDER __BYTE_ORDER
+#elif defined(__NetBSD__) || defined(__FreeBSD__) || \
+ defined(__OpenBSD__) || (__DragonFly__)
+# if defined(__OpenBSD__)
+# include <machine/endian.h>
+# else
+# include <sys/endian.h>
+# endif
+# if (_BYTE_ORDER == _LITTLE_ENDIAN)
+# define BOOST_LITTLE_ENDIAN
+# elif (_BYTE_ORDER == _BIG_ENDIAN)
+# define BOOST_BIG_ENDIAN
+# elif (_BYTE_ORDER == _PDP_ENDIAN)
+# define BOOST_PDP_ENDIAN
+# else
+# error Unknown machine endianness detected.
+# endif
+# define BOOST_BYTE_ORDER __BYTE_ORDER
#elif defined(_BIG_ENDIAN) && !defined(_LITTLE_ENDIAN) || \
defined(__BIG_ENDIAN__) && !defined(__LITTLE_ENDIAN__) || \
defined(_STLP_BIG_ENDIAN) && !defined(_STLP_LITTLE_ENDIAN)

View File

@@ -0,0 +1,24 @@
$NetBSD: patch-boost_foreach.hpp,v 1.3 2012/07/03 19:46:30 adam Exp $
https://svn.boost.org/trac/boost/ticket/6131
--- boost/foreach.hpp.orig 2012-01-09 15:55:10.000000000 +0000
+++ boost/foreach.hpp
@@ -165,7 +165,7 @@ namespace foreach
// this one works on legacy compilers. Overload boost_foreach_is_lightweight_proxy
// at the global namespace for your type.
template<typename T>
-inline boost::foreach::is_lightweight_proxy<T> *
+inline boost::BOOST_FOREACH::is_lightweight_proxy<T> *
boost_foreach_is_lightweight_proxy(T *&, BOOST_FOREACH_TAG_DEFAULT) { return 0; }
template<typename T>
@@ -190,7 +190,7 @@ boost_foreach_is_lightweight_proxy(T **&
// this one works on legacy compilers. Overload boost_foreach_is_noncopyable
// at the global namespace for your type.
template<typename T>
-inline boost::foreach::is_noncopyable<T> *
+inline boost::BOOST_FOREACH::is_noncopyable<T> *
boost_foreach_is_noncopyable(T *&, BOOST_FOREACH_TAG_DEFAULT) { return 0; }
namespace boost

View File

@@ -0,0 +1,48 @@
$NetBSD: patch-boost_foreach_fwd.hpp,v 1.3 2012/07/03 19:46:30 adam Exp $
https://svn.boost.org/trac/boost/ticket/6131
--- boost/foreach_fwd.hpp.orig 2012-01-09 15:58:44.000000000 +0000
+++ boost/foreach_fwd.hpp
@@ -14,6 +14,8 @@
#ifndef BOOST_FOREACH_FWD_HPP
#define BOOST_FOREACH_FWD_HPP
+#include <utility> // for std::pair
+
// This must be at global scope, hence the uglified name
enum boost_foreach_argument_dependent_lookup_hack
{
@@ -25,6 +27,9 @@ namespace boost
namespace foreach
{
+ template<typename T>
+ std::pair<T, T> in_range(T begin, T end);
+
///////////////////////////////////////////////////////////////////////////////
// boost::foreach::tag
//
@@ -46,6 +51,22 @@ namespace foreach
} // namespace foreach
+namespace BOOST_FOREACH
+{
+ using foreach::in_range;
+ using foreach::tag;
+
+ template<typename T>
+ struct is_lightweight_proxy
+ : foreach::is_lightweight_proxy<T>
+ {};
+
+ template<typename T>
+ struct is_noncopyable
+ : foreach::is_noncopyable<T>
+ {};
+} // namespace BOOST_FOREACH
+
} // namespace boost
#endif

View File

@@ -0,0 +1,16 @@
$NetBSD: patch-libs_config_configure,v 1.1 2013/04/12 13:34:42 joerg Exp $
--- libs/config/configure.orig 2013-03-30 16:16:50.000000000 +0000
+++ libs/config/configure
@@ -3050,10 +3050,7 @@ cat > user.hpp << EOF
// setup is fully ISO complient, and has no
// useful extentions, or for autoconf generated
// setups:
-#ifndef BOOST_NO_CONFIG
-# define BOOST_NO_CONFIG
-#endif
-
+// #define BOOST_NO_CONFIG
// define if you want to disable threading support, even
// when available:

View File

@@ -0,0 +1,33 @@
$NetBSD: patch-libs_context_build_Jamfile.v2,v 1.3 2013/02/12 21:07:22 adam Exp $
Add support for SPARC.
--- libs/context/build/Jamfile.v2.orig 2013-01-27 00:25:34.000000000 +0000
+++ libs/context/build/Jamfile.v2
@@ -17,8 +17,7 @@ import architecture ;
project boost/context
: source-location ../src
: requirements
- <os>SOLARIS:<define>_XOPEN_SOURCE=1
- <os>SOLARIS:<define>_XOPEN_SOURCE_EXTENDED=1
+ <os>SOLARIS:<define>_XOPEN_SOURCE=600
: usage-requirements
<link>shared:<define>BOOST_CONTEXT_DYN_LINK=1
;
@@ -414,6 +413,16 @@ alias asm_context_sources
: unsupported.cpp
;
+# SPARC
+alias asm_context_sources
+ : asm/make_sparc_sysv_elf_gas.S
+ asm/jump_sparc_sysv_elf_gas.S
+ : <abi>sysv
+ <architecture>sparc
+ <binary-format>elf
+ <toolset>gcc
+ ;
+
explicit asm_context_sources ;
alias select_asm_context_sources

View File

@@ -0,0 +1,17 @@
$NetBSD: patch-libs_context_build_architecture.jam,v 1.2 2013/02/12 21:07:22 adam Exp $
Add support for SPARC.
--- libs/context/build/architecture.jam.orig 2012-11-04 15:21:27.000000000 +0100
+++ libs/context/build/architecture.jam 2012-11-04 18:53:45.000000000 +0100
@@ -63,6 +63,10 @@
{
return <architecture>arm ;
}
+ else if [ configure.builds /boost/architecture//sparc : $(properties) : sparc ]
+ {
+ return <architecture>sparc ;
+ }
else if [ configure.builds /boost/architecture//mips1 : $(properties) : mips1 ]
{
return <architecture>mips1 ;

View File

@@ -0,0 +1,11 @@
$NetBSD: patch-libs_context_config_Jamfile.jam,v 1.2 2013/02/12 21:07:22 adam Exp $
New build test for SPARC.
--- libs/context/config/Jamfile.jam.orig 2012-11-04 18:56:00.000000000 +0100
+++ libs/context/config/Jamfile.jam 2012-11-04 18:56:19.000000000 +0100
@@ -15,3 +15,4 @@
obj x86 : x86.cpp ;
obj mips1 : mips1.cpp ;
obj arm : arm.cpp ;
+obj sparc : sparc.cpp ;

View File

@@ -0,0 +1,18 @@
$NetBSD: patch-libs_context_config_sparc.cpp,v 1.2 2013/02/12 21:07:22 adam Exp $
Add support for SPARC.
--- /dev/null 2012-11-04 15:17:53.000000000 +0100
+++ libs/context/config/sparc.cpp 2012-11-04 18:56:51.000000000 +0100
@@ -0,0 +1,11 @@
+// power.cpp
+//
+// Copyright (c) 2012 Steven Watanabe
+//
+// Distributed under the Boost Software License Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+#if !defined(__sparc)
+#error "Not SPARC"
+#endif

View File

@@ -0,0 +1,194 @@
$NetBSD: patch-libs_context_src_asm_jump__sparc__sysv__elf__gas.S,v 1.2 2013/02/12 21:07:22 adam Exp $
Implementation for jump_fcontext for SPARC.
--- /dev/null 2013-01-19 12:02:03.000000000 +0100
+++ libs/context/src/asm/jump_sparc_sysv_elf_gas.S 2013-01-19 18:41:04.000000000 +0100
@@ -0,0 +1,187 @@
+/*
+ Copyright Martin Husemann 2013.
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+*/
+
+/*******************************************************************
+ * *
+ * ------------------------------------------------------------- *
+ * | Offset (in 4 or 8 byte units) | Content | *
+ * ------------------------------------------------------------- *
+ * | 0 | %sp | *
+ * ------------------------------------------------------------- *
+ * | 1 | %pc | *
+ * ------------------------------------------------------------- *
+ * | 2 | %i7 (return address) | *
+ * ------------------------------------------------------------- *
+ * | 3 | %g1 | *
+ * ------------------------------------------------------------- *
+ * | 4 | %g2 | *
+ * ------------------------------------------------------------- *
+ * | 5 | %g3 | *
+ * ------------------------------------------------------------- *
+ * | 6 | %g6 | *
+ * ------------------------------------------------------------- *
+ * | 7 | %g7 | *
+ * ------------------------------------------------------------- *
+ * The local and in registers are stored on the stack. *
+ *******************************************************************/
+
+#ifdef _LP64
+#define ST stx
+#define LD ldx
+#define OFF(N) (8*(N))
+#define CCFSZ 176 // C Compiler Frame Size
+#define BIAS (2048-1) // Stack offset for 64 bit programs
+#define FC_SZ 448 // sizeof(fcontext_t)
+#define FC_STK 384 // offsetof(fcontext_t, fc_stack)
+#define FC_FPU 0 // offsetof(fcontext_t, fc_fp)
+#define FC_FSR 264 // offsetof(fcontext_t, fc_fp.fp_fsr)
+#define FC_FPRS 256 // offsetof(fcontext_t, fc_fp.fp_fprs)
+#define FC_GREG 320 // offsetof(fcontext_t, fc_greg)
+#define BLOCK_SIZE 64
+#define FLUSHW flushw
+
+ .register %g2,#ignore
+ .register %g3,#ignore
+ .register %g6,#ignore
+
+#else
+#define ST st
+#define LD ld
+#define OFF(N) (4*(N))
+#define CCFSZ 96
+#define BIAS 0
+#define FC_SZ 176
+#define FC_STK 168 // offsetof(fcontext_t, fc_stack)
+#define FC_FPU 0 // offsetof(fcontext_t, fc_fp)
+#define FC_FSR 128 // offsetof(fcontext_t, fc_fp.fp_fsr)
+#define FC_GREG 136 // offsetof(fcontext_t, fc_greg)
+#define BLOCK_SIZE 8
+#ifdef __NetBSD__
+#define FLUSHW t 0x83; nop // T_FLUSHWIN
+#endif
+#endif
+
+.text
+.globl jump_fcontext
+.align 4
+.type jump_fcontext,@function
+// intptr_t
+// jump_fcontext( fcontext_t * ofc, fcontext_t const* nfc, intptr_t vp,
+// bool preserve_fpu = true);
+jump_fcontext:
+ // %o0 = pointer to old fcontext, save current state here
+ // %o1 = new context to jump to
+ // %o2 = new return value in context %o0
+ // %o3 = preserve fpu registers
+ // Save current state in %o0 fcontext, then activate %o1.
+ // If %o3, include fpu registers.
+
+ FLUSHW // make sure all shadow registers are up to date in the current stack
+
+ // save current state to fcontext_t at %o0
+ ST %sp, [%o0 + FC_GREG + OFF(0)] // current stack pointer
+ add %o7, 8, %o4 // calculate next instruction past call
+ ST %o4, [%o0 + FC_GREG + OFF(1)] // and store it as %pc in save context
+ ST %o7, [%o0 + FC_GREG + OFF(2)]
+ ST %g1, [%o0 + FC_GREG + OFF(3)]
+ ST %g2, [%o0 + FC_GREG + OFF(4)]
+ ST %g3, [%o0 + FC_GREG + OFF(5)]
+ ST %g6, [%o0 + FC_GREG + OFF(6)]
+ ST %g7, [%o0 + FC_GREG + OFF(7)]
+
+ // do we need to handle fpu?
+#ifdef _LP64
+ brz %o3, Lno_fpu
+ nop
+#else
+ cmp %o3, 0
+ bz Lno_fpu
+ nop
+#endif
+
+ add %o0, FC_FPU, %o5
+#ifdef _LP64
+ stda %f0, [%o5] 0xf0 /* ASI_BLOCK_PRIMARY */
+ add %o5, BLOCK_SIZE, %o5
+ stda %f16, [%o5] 0xf0
+ add %o5, BLOCK_SIZE, %o5
+ stda %f32, [%o5] 0xf0
+ add %o5, BLOCK_SIZE, %o5
+ stda %f48, [%o5] 0xf0
+ stx %fsr, [%o0+FC_FSR]
+ rd %fprs, %o4
+ stx %o4, [%o0+FC_FPRS]
+#else
+ std %f0, [%o5]
+ std %f2, [%o5+0x08]
+ std %f4, [%o5+0x10]
+ std %f6, [%o5+0x18]
+ std %f8, [%o5+0x20]
+ std %f10, [%o5+0x28]
+ std %f12, [%o5+0x30]
+ std %f14, [%o5+0x38]
+ st %fsr, [%o0+FC_FSR]
+#endif
+
+ add %o1, FC_FPU, %o5
+#ifdef _LP64
+ ldda [%o5] 0xf0 /* ASI_BLOCK_PRIMARY */, %f0
+ add %o5, BLOCK_SIZE, %o5
+ ldda [%o5] 0xf0, %f16
+ add %o5, BLOCK_SIZE, %o5
+ ldda [%o5] 0xf0, %f32
+ add %o5, BLOCK_SIZE, %o5
+ ldda [%o5] 0xf0, %f48
+ ldx [%o1+FC_FSR], %fsr
+ ldx [%o1+FC_FPRS], %o4
+ wr %o4,0,%fprs
+#else
+ ldd [%o5], %f0
+ ldd [%o5+0x08], %f2
+ ldd [%o5+0x10], %f4
+ ldd [%o5+0x18], %f6
+ ldd [%o5+0x20], %f8
+ ldd [%o5+0x28], %f10
+ ldd [%o5+0x30], %f12
+ ldd [%o5+0x38], %f14
+ ld [%o1+FC_FSR], %fsr
+#endif
+
+Lno_fpu:
+ // load new state from %o1
+ LD [%o1 + FC_GREG + OFF(1)], %o4
+ LD [%o1 + FC_GREG + OFF(2)], %o7
+ LD [%o1 + FC_GREG + OFF(3)], %g1
+ LD [%o1 + FC_GREG + OFF(4)], %g2
+ LD [%o1 + FC_GREG + OFF(5)], %g3
+ LD [%o1 + FC_GREG + OFF(6)], %g6
+ LD [%o1 + FC_GREG + OFF(7)], %g7
+ // switch to new stack
+ LD [%o1 + FC_GREG + OFF(0)], %sp
+ // and now reload from this stack the shadow regist bank contents
+ LD [%sp + BIAS + OFF(0)], %l0
+ LD [%sp + BIAS + OFF(1)], %l1
+ LD [%sp + BIAS + OFF(2)], %l2
+ LD [%sp + BIAS + OFF(3)], %l3
+ LD [%sp + BIAS + OFF(4)], %l4
+ LD [%sp + BIAS + OFF(5)], %l5
+ LD [%sp + BIAS + OFF(6)], %l6
+ LD [%sp + BIAS + OFF(7)], %l7
+ LD [%sp + BIAS + OFF(8)], %i0
+ LD [%sp + BIAS + OFF(9)], %i1
+ LD [%sp + BIAS + OFF(10)], %i2
+ LD [%sp + BIAS + OFF(11)], %i3
+ LD [%sp + BIAS + OFF(12)], %i4
+ LD [%sp + BIAS + OFF(13)], %i5
+ LD [%sp + BIAS + OFF(14)], %i6
+ LD [%sp + BIAS + OFF(15)], %i7
+
+ // finally continue execution in new context
+ jmp %o4
+ mov %o2, %o0 // return arg as result
+
+.size jump_fcontext,.-jump_fcontext

View File

@@ -0,0 +1,115 @@
$NetBSD: patch-libs_context_src_asm_make__sparc__sysv__elf__gas.S,v 1.2 2013/02/12 21:07:22 adam Exp $
Implementation of make_fcontext for SPARC.
--- /dev/null 2013-01-19 12:02:03.000000000 +0100
+++ libs/context/src/asm/make_sparc_sysv_elf_gas.S 2013-01-19 19:29:27.000000000 +0100
@@ -0,0 +1,108 @@
+/*
+ Copyright Martin Husemann 2013.
+ Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+*/
+
+/*******************************************************************
+ * *
+ * ------------------------------------------------------------- *
+ * | Offset (in 4 or 8 byte units) | Content | *
+ * ------------------------------------------------------------- *
+ * | 0 | %sp | *
+ * ------------------------------------------------------------- *
+ * | 1 | %pc | *
+ * ------------------------------------------------------------- *
+ * | 2 | %i7 (return address) | *
+ * ------------------------------------------------------------- *
+ * | 3 | %g1 | *
+ * ------------------------------------------------------------- *
+ * | 4 | %g2 | *
+ * ------------------------------------------------------------- *
+ * | 5 | %g3 | *
+ * ------------------------------------------------------------- *
+ * | 6 | %g6 | *
+ * ------------------------------------------------------------- *
+ * | 7 | %g7 | *
+ * ------------------------------------------------------------- *
+ * The local and in registers are stored on the stack. *
+ *******************************************************************/
+
+#ifdef _LP64
+#define ST stx
+#define LD ldx
+#define OFF(N) (8*(N))
+#define CCFSZ 176 // C Compiler Frame Size
+#define BIAS (2048-1) // Stack offset for 64 bit programs
+#define FC_SZ 448 // sizeof(fcontext_t)
+#define FC_STK 384 // offsetof(fcontext_t, fc_stack)
+#define FC_FPU 0 // offsetof(fcontext_t, fc_fp)
+#define FC_FSR 264 // offsetof(fcontext_t, fc_fp.fp_fsr)
+#define FC_FPRS 256 // offsetof(fcontext_t, fc_fp.fp_fprs)
+#define FC_GREG 320 // offsetof(fcontext_t, fc_greg)
+#define BLOCK_SIZE 64
+#define FLUSHW flushw
+
+ .register %g2,#ignore
+ .register %g3,#ignore
+ .register %g6,#ignore
+
+#else
+#define ST st
+#define LD ld
+#define OFF(N) (4*(N))
+#define CCFSZ 96
+#define BIAS 0
+#define FC_SZ 176
+#define FC_STK 168 // offsetof(fcontext_t, fc_stack)
+#define FC_FPU 0 // offsetof(fcontext_t, fc_fp)
+#define FC_FSR 128 // offsetof(fcontext_t, fc_fp.fp_fsr)
+#define FC_GREG 136 // offsetof(fcontext_t, fc_greg)
+#define BLOCK_SIZE 8
+#endif
+
+.text
+.globl make_fcontext
+.align 4
+.type make_fcontext,@function
+// fcontext_t *
+// make_fcontext( void * sp, std::size_t size, void (* fn)( intptr_t) )
+make_fcontext:
+ save %sp, -CCFSZ, %sp
+ // %i0 initial stack pointer
+ // %i1 stack size limit
+ // %i2 function pointer for context start function
+
+ sub %i0, FC_SZ, %i4 // allocate fcontext_t at on the new stack and keep pointer as return value
+ andn %i4, BLOCK_SIZE-1, %i5 // force block ops usable alignement and keep pointer to fcontext in %i5
+
+ ST %i0, [%i5+FC_STK+OFF(0)] // save fs_stack.sp
+ ST %i1, [%i5+FC_STK+OFF(1)] // save fs_stack.size
+ sub %i5, CCFSZ+BIAS, %o1 // leave space for one register window (and offset stack for 64bit)
+ ST %o1, [%i5+FC_GREG+OFF(0)] // save new stack pointer
+ ST %i2, [%i5+FC_GREG+OFF(1)] // save new %pc (function pointer)
+ ST %g1, [%i5+FC_GREG+OFF(3)]
+ ST %g2, [%i5+FC_GREG+OFF(4)]
+ ST %g3, [%i5+FC_GREG+OFF(5)]
+ ST %g6, [%i5+FC_GREG+OFF(6)]
+ ST %g7, [%i5+FC_GREG+OFF(7)]
+
+ // synthesize "return address": jump to finish
+#ifdef _LP64
+1: rd %pc, %i4
+ add %i4, finish-1b-8, %i4
+#else
+ set finish-8, %i4
+#endif
+ ST %i4, [%i5+FC_GREG+OFF(2)]
+
+ ret
+ restore %g0, %i5, %o0 // return fcontext_t
+
+finish:
+ mov %g0, %o0
+ call _exit
+ nop
+
+.size make_fcontext,.-make_fcontext

View File

@@ -0,0 +1,14 @@
$NetBSD: patch-libs_filesystem_src_unique_path.cpp,v 1.2 2013/02/12 21:07:22 adam Exp $
Include unistd.h for read() and close().
--- libs/filesystem/src/unique_path.cpp.orig Thu Aug 2 12:04:47 2012
+++ libs/filesystem/src/unique_path.cpp Thu Aug 2 12:04:55 2012
@@ -21,6 +21,7 @@
# ifdef BOOST_POSIX_API
# include <fcntl.h>
+# include <unistd.h>
# else // BOOST_WINDOWS_API
# include <windows.h>
# include <wincrypt.h>

View File

@@ -0,0 +1,71 @@
$NetBSD: patch-tools_build_v2_engine_hash.c,v 1.3 2013/02/12 21:07:22 adam Exp $
Fix alignement for 32bit platforms with alignment restrictions.
A time_t requires greater alignement than a void*.
--- tools/build/v2/engine/hash.c.orig 2013-01-16 16:21:53.000000000 +0100
+++ tools/build/v2/engine/hash.c 2013-01-17 12:36:56.000000000 +0100
@@ -34,7 +34,17 @@
struct hashhdr
{
- struct item * next;
+ union {
+ struct item * next;
+ /*
+ * Some architectures have 32bit pointers but 64bit time_t (as used
+ * in file_info_t), and require natural alignement of data.
+ * Since we offset an aligned pointer by sizeof(hashhdr) in
+ * hash_item_data(item), we may cause misalignement if we do not
+ * make sure that sizeof(hashhdr) is properly aligned.
+ */
+ time_t aligner; /* unused dummy for alignement */
+ } h;
};
typedef struct item
@@ -106,7 +116,7 @@ static ITEM * hash_search(
ITEM * i = *hash_bucket(hp,keyval);
ITEM * p = 0;
- for ( ; i; i = i->hdr.next )
+ for ( ; i; i = i->hdr.h.next )
{
if ( object_equal( hash_item_key( i ), keydata ) )
{
@@ -153,7 +163,7 @@ HASHDATA * hash_insert( struct hash * hp
if ( hp->items.free )
{
i = hp->items.free;
- hp->items.free = i->hdr.next;
+ hp->items.free = i->hdr.h.next;
assert( hash_item_key( i ) == 0 );
}
else
@@ -162,7 +172,7 @@ HASHDATA * hash_insert( struct hash * hp
hp->items.next += hp->items.size;
}
hp->items.more--;
- i->hdr.next = *base;
+ i->hdr.h.next = *base;
*base = i;
*found = 0;
}
@@ -251,7 +261,7 @@ static void hashrehash( register struct
/* code currently assumes rehashing only when there are no free items */
assert( hash_item_key( i ) != 0 );
- i->hdr.next = *ip;
+ i->hdr.h.next = *ip;
*ip = i;
}
}
@@ -367,7 +377,7 @@ void hashstats_add( struct hashstats * s
{
ITEM * item;
int here = 0;
- for ( item = tab[ i ]; item != 0; item = item->hdr.next )
+ for ( item = tab[ i ]; item != 0; item = item->hdr.h.next )
++here;
count += here;