Project import
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..0eaf165 --- /dev/null +++ b/Makefile
@@ -0,0 +1,147 @@ +# +# Copyright (c) 2010-2012 Nest Labs, Inc. +# All rights reserved. +# +# This document is the property of Nest. It is considered +# confidential and proprietary information. +# +# This document may not be reproduced or transmitted in any form, +# in whole or in part, without the express written permission of +# Nest. +# +# Description: +# This file is the makefile for Boost, a collection of open +# source libraries that extend the functionality of the C++ standard +# library. +# + + +include pre.mak + +PackageName := boost + +PackageExtension := tar.bz2 +PackageSeparator := _ + +PackagePatchArgs := -p1 + +PackageArchive := $(PackageName).$(PackageExtension) +PackageSourceDir := $(PackageName)$(PackageSeparator)$(PackageVersion) + +CleanPaths += $(PackageLicenseFile) + +# For the short-term, we are always building with GCC even though the +# actual tool chain may be some repackaged version of GCC. So, just +# specify that. + +BoostToolset := gcc + +# We do not want versioned headers and libraries, so specify the +# 'system' layout. Also, we do not want all the various combinations +# of shared/static, release/debug, stripped/unstripped and +# non-threaded/threaded libraries, so just specify 'minimal'. + +BoostJamConfig += --layout=system \ + --build-type=minimal \ + -sICU_PATH=$(IcuPrefixPath) \ + link=shared \ + $(if $(LinuxIncludePath), cxxflags="$(call ToolGenerateIncludeArgument,$(LinuxIncludePath))") \ + $(if $(PythonIncludePath), cxxflags="$(call ToolGenerateIncludeArgument,$(PythonIncludePath))") \ + $(NULL) + +# If ForceLibStdCPP is set, tell boost to use libstdc++ instead of +# the compiler default +ifeq ($(call IsYes,$(ForceLibStdCPP)),Y) +BoostJamConfig += dll-path=$(BoostLibraryPath) cxxflags="-stdlib=libstdc++" linkflags="-stdlib=libstdc++" +endif + + +BoostLibraries = filesystem \ + system \ + signals + +ifeq ($(BUILD_FEATURE_BOOST_PYTHON),1) +BoostLibraries += \ + python +endif + +BoostLibrariesList = $(subst $(Space),$(Comma),$(strip $(BoostLibraries))) + +BoostProjectConfig = $(call GenerateBuildPaths,project-config.jam) + +SOURCEDIRS = $(PackageSourceDir) +$(PackageSourceDir)_RULE_TARGET = $(BuildDirectory)/configure + +all: $(PackageDefaultGoal) + +# Generate the package license contents. + +$(PackageSourceDir)/LICENSE_1_0.txt: $(BuildDirectory)/source + +$(PackageLicenseFile): $(PackageSourceDir)/LICENSE_1_0.txt + $(copy-result) + +# Extract the source from the archive and apply patches, if any. + +$(PackageSourceDir): $(PackageArchive) $(PackagePatchPaths) + $(expand-and-patch-package) + +# Prepare the sources. + +$(BuildDirectory)/source: $(PackageSourceDir) | $(BuildDirectory) + $(Verbose)touch $(BuildDirectory)/source + +# Generate the package build makefile. + + +# Generate the build-specific makefile and user configuration. We have +# to post-process the generated user configuration since Boost's +# adominable build system has no other way to override the actual C++ +# compiler executable used (see http://goodliffe.blogspot.com/2008/05/ +# cross-compiling-boost.html and boost/docs/html/bbv2/ +# tasks.html#bbv2.tasks.crosscompile). + +# Configure the source for building. +.PHONY: configure +configure: $(BuildDirectory)/configure +$(BuildDirectory)/configure: $(BuildDirectory)/source | $(PackageSourceDir) $(BuildDirectory) + $(call create-links,$(CURDIR)/$(PackageSourceDir),$(BuildDirectory)) + $(Verbose)cd $(BuildDirectory) && \ + ./bootstrap.sh \ + --prefix=$(ResultDirectory) \ + --with-toolset=$(BoostToolset) \ + --with-icu=$(IcuPrefixPath) \ + --with-libraries=$(BoostLibrariesList) \ + --with-python-root=$(PythonResultsPath) + $(Verbose)$(SED) -e "s#^\([[:space:]]*using\)[[:space:]]\{1,\}\($(BoostToolset)\)[[:space:]]\{1,\};#\1 \2 : $(TargetProcArch) : $(CXX) $(CPPOPTFLAGS) ;#g" \ + < $(BoostProjectConfig) > $(BoostProjectConfig).N || $(RM) -f $(BoostProjectConfig) + $(Verbose)mv -f $(BoostProjectConfig) $(BoostProjectConfig).O + $(Verbose)mv -f $(BoostProjectConfig).N $(BoostProjectConfig) + $(Verbose)touch $(BuildDirectory)/configure + +# Build the source. + +$(BuildDirectory)/build: $(BuildDirectory)/configure + $(Verbose)cd $(BuildDirectory) && \ + ./bjam $(JOBSFLAG) $(BoostJamConfig) + $(Verbose)touch $(BuildDirectory)/build + +# Stage the build to a temporary installation area. + +$(BuildDirectory)/stage: $(BuildDirectory)/build | $(ResultDirectory) + $(Verbose)cd $(BuildDirectory) && \ + INSTALL="$(INSTALL) $(INSTALLFLAGS)" && \ + ./bjam $(JOBSFLAG) $(BoostJamConfig) \ + install --prefix=$(ResultDirectory) + $(Verbose)touch $(BuildDirectory)/stage + +.PHONY: stage +stage: $(BuildDirectory)/stage + +clean: + $(Verbose)$(RM) $(RMFLAGS) -r $(PackageSourceDir) + $(Verbose)$(RM) $(RMFLAGS) -r $(BuildDirectory) + $(Verbose)$(RM) $(RMFLAGS) -r $(ResultDirectory) + $(Verbose)$(RM) $(RMFLAGS) -r $(PackageSourceDir).mk.d + +include post.mak
diff --git a/boost.patches/boost-00.description b/boost.patches/boost-00.description new file mode 100644 index 0000000..40cbf45 --- /dev/null +++ b/boost.patches/boost-00.description
@@ -0,0 +1 @@ +This patch fixes https://svn.boost.org/trac/boost/ticket/4688
diff --git a/boost.patches/boost-00.patch b/boost.patches/boost-00.patch new file mode 100644 index 0000000..85362e4 --- /dev/null +++ b/boost.patches/boost-00.patch
@@ -0,0 +1,26 @@ +diff --git a/libs/filesystem/v2/src/v2_path.cpp b/libs/filesystem/v2/src/v2_path.cpp +index 7adeaff..027b299 100644 +--- a/libs/filesystem/v2/src/v2_path.cpp ++++ b/libs/filesystem/v2/src/v2_path.cpp +@@ -45,7 +45,7 @@ namespace + { + #if !defined(macintosh) && !defined(__APPLE__) && !defined(__APPLE_CC__) + // ISO C calls this "the locale-specific native environment": +- static std::locale lc(""); ++ static std::locale lc; + #else // Mac OS + // "All BSD system functions expect their string parameters to be in UTF-8 encoding + // and nothing else." +diff --git a/libs/filesystem/v3/src/path.cpp b/libs/filesystem/v3/src/path.cpp +index 7dc0b53..213ca36 100644 +--- a/libs/filesystem/v3/src/path.cpp ++++ b/libs/filesystem/v3/src/path.cpp +@@ -760,7 +760,7 @@ namespace + + # else + // ISO C calls this "the locale-specific native environment": +- return std::locale(""); ++ return std::locale(); + + # endif + }
diff --git a/boost.patches/boost-00.url b/boost.patches/boost-00.url new file mode 100644 index 0000000..42f770e --- /dev/null +++ b/boost.patches/boost-00.url
@@ -0,0 +1 @@ +https://svn.boost.org/trac/boost/raw-attachment/ticket/4688/boost_filesystem.patch
diff --git a/boost.patches/boost-01.description b/boost.patches/boost-01.description new file mode 100644 index 0000000..cc99764 --- /dev/null +++ b/boost.patches/boost-01.description
@@ -0,0 +1,5 @@ +This patch addresses upstream issues 5331 +<https://svn.boost.org/trac/boost/attachment/ticket/5331> and 6692 +<https://svn.boost.org/trac/boost/attachment/ticket/6692> by removing +the use of the deprecated swp{b} instructions on ARMv6 and ARMv7 +architectures, replacing them with the newer {ld,st}rex.
diff --git a/boost.patches/boost-01.patch b/boost.patches/boost-01.patch new file mode 100644 index 0000000..e556c4e --- /dev/null +++ b/boost.patches/boost-01.patch
@@ -0,0 +1,88 @@ +--- a/boost/smart_ptr/detail/spinlock_gcc_arm.hpp 2009-03-02 08:22:16.000000000 -0800 ++++ b/boost/smart_ptr/detail/spinlock_gcc_arm.hpp 2012-06-28 16:39:55.000000000 -0700 +@@ -2,7 +2,7 @@ + #define BOOST_SMART_PTR_DETAIL_SPINLOCK_GCC_ARM_HPP_INCLUDED + + // +-// Copyright (c) 2008 Peter Dimov ++// Copyright (c) 2008, 2011 Peter Dimov + // + // Distributed under the Boost Software License, Version 1.0. + // See accompanying file LICENSE_1_0.txt or copy at +@@ -11,6 +11,20 @@ + + #include <boost/smart_ptr/detail/yield_k.hpp> + ++#if defined(__ARM_ARCH_7__) || defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__) || defined(__ARM_ARCH_7M__) || defined(__ARM_ARCH_7EM__) ++ ++# define BOOST_SP_ARM_BARRIER "dmb" ++ ++#elif defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) || defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_6Z__) || defined(__ARM_ARCH_6ZK__) || defined(__ARM_ARCH_6T2__) ++ ++# define BOOST_SP_ARM_BARRIER "mcr p15, 0, r0, c7, c10, 5" ++ ++#else ++ ++# define BOOST_SP_ARM_BARRIER "" ++ ++#endif ++ + namespace boost + { + +@@ -29,12 +43,38 @@ + { + int r; + ++#if defined(__ARM_ARCH_6__) \ ++ || defined(__ARM_ARCH_6J__) \ ++ || defined(__ARM_ARCH_6K__) \ ++ || defined(__ARM_ARCH_6Z__) \ ++ || defined(__ARM_ARCH_6ZK__) \ ++ || defined(__ARM_ARCH_6T2__) \ ++ || defined(__ARM_ARCH_7__) \ ++ || defined(__ARM_ARCH_7A__) \ ++ || defined(__ARM_ARCH_7R__) \ ++ || defined(__ARM_ARCH_7M__) \ ++ || defined(__ARM_ARCH_7EM__) ++ + __asm__ __volatile__( +- "swp %0, %1, [%2]": ++ "ldrex %0, [%2]; \n" ++ "cmp %0, %1; \n" ++ "strexne %0, %1, [%2]; \n" ++ BOOST_SP_ARM_BARRIER : + "=&r"( r ): // outputs + "r"( 1 ), "r"( &v_ ): // inputs + "memory", "cc" ); + ++#else ++ ++ __asm__ __volatile__( ++ "swp %0, %1, [%2];\n" ++ BOOST_SP_ARM_BARRIER : ++ "=&r"( r ): // outputs ++ "r"( 1 ), "r"( &v_ ): // inputs ++ "memory", "cc" ); ++ ++#endif ++ + return r == 0; + } + +@@ -48,7 +88,7 @@ + + void unlock() + { +- __asm__ __volatile__( "" ::: "memory" ); ++ __asm__ __volatile__( BOOST_SP_ARM_BARRIER ::: "memory" ); + *const_cast< int volatile* >( &v_ ) = 0; + } + +@@ -82,4 +122,6 @@ + + #define BOOST_DETAIL_SPINLOCK_INIT {0} + ++#undef BOOST_SP_ARM_BARRIER ++ + #endif // #ifndef BOOST_SMART_PTR_DETAIL_SPINLOCK_GCC_ARM_HPP_INCLUDED
diff --git a/boost.patches/boost-02.description b/boost.patches/boost-02.description new file mode 100644 index 0000000..32ef535 --- /dev/null +++ b/boost.patches/boost-02.description
@@ -0,0 +1,3 @@ +This patch fixes various compilation errors and warnings when compiling using gcc 4.8.2 + +
diff --git a/boost.patches/boost-02.patch b/boost.patches/boost-02.patch new file mode 100644 index 0000000..66f0979 --- /dev/null +++ b/boost.patches/boost-02.patch
@@ -0,0 +1,126 @@ +--- a/boost/config/stdlib/libstdcpp3.hpp 2010-10-01 02:19:44.000000000 -0700 ++++ b/boost/config/stdlib/libstdcpp3.hpp 2014-05-31 04:07:43.998193374 -0700 +@@ -31,7 +31,8 @@ + + #ifdef __GLIBCXX__ // gcc 3.4 and greater: + # if defined(_GLIBCXX_HAVE_GTHR_DEFAULT) \ +- || defined(_GLIBCXX__PTHREADS) ++ || defined(_GLIBCXX__PTHREADS) \ ++ || defined(_GLIBCXX_HAS_GTHREADS) + // + // If the std lib has thread support turned on, then turn it on in Boost + // as well. We do this because some gcc-3.4 std lib headers define _REENTANT +--- a/boost/thread/xtime.hpp 2008-06-18 06:01:08.000000000 -0700 ++++ b/boost/thread/xtime.hpp 2014-05-31 04:07:44.098193379 -0700 +@@ -20,7 +20,7 @@ + + enum xtime_clock_types + { +- TIME_UTC=1 ++ TIME_UTC_=1 + // TIME_TAI, + // TIME_MONOTONIC, + // TIME_PROCESS, +@@ -68,7 +68,7 @@ + + inline int xtime_get(struct xtime* xtp, int clock_type) + { +- if (clock_type == TIME_UTC) ++ if (clock_type == TIME_UTC_) + { + *xtp=get_xtime(get_system_time()); + return clock_type; +--- a/libs/thread/src/pthread/thread.cpp 2010-10-29 16:27:00.000000000 -0700 ++++ b/libs/thread/src/pthread/thread.cpp 2014-05-31 04:07:50.302193645 -0700 +@@ -350,7 +350,7 @@ + cond.timed_wait(lock, xt); + # endif + xtime cur; +- xtime_get(&cur, TIME_UTC); ++ xtime_get(&cur, TIME_UTC_); + if (xtime_cmp(xt, cur) <= 0) + return; + } +@@ -365,7 +365,7 @@ + BOOST_VERIFY(!pthread_yield()); + # else + xtime xt; +- xtime_get(&xt, TIME_UTC); ++ xtime_get(&xt, TIME_UTC_); + sleep(xt); + # endif + } +--- a/libs/thread/src/pthread/timeconv.inl 2010-04-01 08:04:15.000000000 -0700 ++++ b/libs/thread/src/pthread/timeconv.inl 2014-05-31 04:07:50.302193645 -0700 +@@ -20,8 +20,8 @@ + inline void to_time(int milliseconds, boost::xtime& xt) + { + int res = 0; +- res = boost::xtime_get(&xt, boost::TIME_UTC); +- BOOST_ASSERT(res == boost::TIME_UTC); ++ res = boost::xtime_get(&xt, boost::TIME_UTC_); ++ BOOST_ASSERT(res == boost::TIME_UTC_); + + xt.sec += (milliseconds / MILLISECONDS_PER_SECOND); + xt.nsec += ((milliseconds % MILLISECONDS_PER_SECOND) * +@@ -57,8 +57,8 @@ + { + boost::xtime cur; + int res = 0; +- res = boost::xtime_get(&cur, boost::TIME_UTC); +- BOOST_ASSERT(res == boost::TIME_UTC); ++ res = boost::xtime_get(&cur, boost::TIME_UTC_); ++ BOOST_ASSERT(res == boost::TIME_UTC_); + + if (boost::xtime_cmp(xt, cur) <= 0) + { +@@ -88,8 +88,8 @@ + { + boost::xtime cur; + int res = 0; +- res = boost::xtime_get(&cur, boost::TIME_UTC); +- BOOST_ASSERT(res == boost::TIME_UTC); ++ res = boost::xtime_get(&cur, boost::TIME_UTC_); ++ BOOST_ASSERT(res == boost::TIME_UTC_); + + if (boost::xtime_cmp(xt, cur) <= 0) + milliseconds = 0; +@@ -110,8 +110,8 @@ + { + boost::xtime cur; + int res = 0; +- res = boost::xtime_get(&cur, boost::TIME_UTC); +- BOOST_ASSERT(res == boost::TIME_UTC); ++ res = boost::xtime_get(&cur, boost::TIME_UTC_); ++ BOOST_ASSERT(res == boost::TIME_UTC_); + + if (boost::xtime_cmp(xt, cur) <= 0) + microseconds = 0; +--- a/boost/static_assert.hpp 2008-07-11 03:49:31.000000000 -0700 ++++ b/boost/static_assert.hpp 2014-06-07 07:32:29.365107458 -0700 +@@ -38,6 +38,15 @@ + # define BOOST_STATIC_ASSERT_BOOL_CAST(x) (bool)(x) + #endif + ++// ++// If the compiler warns about unused typedefs then enable this: ++// ++#if defined(__GNUC__) && ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 7))) ++# define BOOST_STATIC_ASSERT_UNUSED_ATTRIBUTE __attribute__((unused)) ++#else ++# define BOOST_STATIC_ASSERT_UNUSED_ATTRIBUTE ++#endif ++ + #ifdef BOOST_HAS_STATIC_ASSERT + # define BOOST_STATIC_ASSERT( B ) static_assert(B, #B) + #else +@@ -116,7 +125,7 @@ + #define BOOST_STATIC_ASSERT( B ) \ + typedef ::boost::static_assert_test<\ + sizeof(::boost::STATIC_ASSERTION_FAILURE< BOOST_STATIC_ASSERT_BOOL_CAST( B ) >)>\ +- BOOST_JOIN(boost_static_assert_typedef_, __LINE__) ++ BOOST_JOIN(boost_static_assert_typedef_, __LINE__) BOOST_STATIC_ASSERT_UNUSED_ATTRIBUTE + #endif + + #else +
diff --git a/boost.patches/boost-50.description b/boost.patches/boost-50.description new file mode 100644 index 0000000..b4de134 --- /dev/null +++ b/boost.patches/boost-50.description
@@ -0,0 +1 @@ +This patch resolves compiler errors / warnings regarding shadow variables.
diff --git a/boost.patches/boost-50.patch b/boost.patches/boost-50.patch new file mode 100644 index 0000000..474e31f --- /dev/null +++ b/boost.patches/boost-50.patch
@@ -0,0 +1,110 @@ +--- a/boost/concept_check.hpp ++++ b/boost/concept_check.hpp +@@ -1014,11 +1014,11 @@ + c.swap(c); + } + +- void const_constraints(const C& c) { +- ci = c.begin(); +- ci = c.end(); +- n = c.size(); +- b = c.empty(); ++ void const_constraints(const C& constraint) { ++ ci = constraint.begin(); ++ ci = constraint.end(); ++ n = constraint.size(); ++ b = constraint.empty(); + } + + private: +--- a/boost/filesystem/v3/path.hpp 2010-10-16 06:09:25.000000000 -0700 ++++ b/boost/filesystem/v3/path.hpp 2011-05-14 16:54:35.927910801 -0700 +@@ -142,23 +142,23 @@ + } + + template <class InputIterator> +- path(InputIterator begin, InputIterator end) ++ path(InputIterator first, InputIterator last) + { +- if (begin != end) ++ if (first != last) + { + std::basic_string<typename std::iterator_traits<InputIterator>::value_type> +- s(begin, end); ++ s(first, last); + path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, codecvt()); + } + } + + template <class InputIterator> +- path(InputIterator begin, InputIterator end, const codecvt_type& cvt) ++ path(InputIterator first, InputIterator last, const codecvt_type& cvt) + { +- if (begin != end) ++ if (first != last) + { + std::basic_string<typename std::iterator_traits<InputIterator>::value_type> +- s(begin, end); ++ s(first, last); + path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); + } + } +@@ -190,19 +190,19 @@ + } + + template <class InputIterator> +- path& assign(InputIterator begin, InputIterator end) ++ path& assign(InputIterator first, InputIterator last) + { +- return assign(begin, end, codecvt()); ++ return assign(first, last, codecvt()); + } + + template <class InputIterator> +- path& assign(InputIterator begin, InputIterator end, const codecvt_type& cvt) ++ path& assign(InputIterator first, InputIterator last, const codecvt_type& cvt) + { + m_pathname.clear(); +- if (begin != end) ++ if (first != last) + { + std::basic_string<typename std::iterator_traits<InputIterator>::value_type> +- s(begin, end); ++ s(first, last); + path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); + } + return *this; +@@ -227,13 +227,13 @@ + path& append(Source const& source, const codecvt_type& cvt); + + template <class InputIterator> +- path& append(InputIterator begin, InputIterator end) ++ path& append(InputIterator first, InputIterator last) + { +- return append(begin, end, codecvt()); ++ return append(first, last, codecvt()); + } + + template <class InputIterator> +- path& append(InputIterator begin, InputIterator end, const codecvt_type& cvt); ++ path& append(InputIterator first, InputIterator last, const codecvt_type& cvt); + + // ----- modifiers ----- + +@@ -612,13 +612,13 @@ + //--------------------------------------------------------------------------------------// + + template <class InputIterator> +- path& path::append(InputIterator begin, InputIterator end, const codecvt_type& cvt) ++ path& path::append(InputIterator first, InputIterator last, const codecvt_type& cvt) + { +- if (begin == end) ++ if (first == last) + return *this; + string_type::size_type sep_pos(m_append_separator_if_needed()); + std::basic_string<typename std::iterator_traits<InputIterator>::value_type> +- s(begin, end); ++ s(first, last); + path_traits::convert(s.c_str(), s.c_str()+s.size(), m_pathname, cvt); + if (sep_pos) + m_erase_redundant_separator(sep_pos);
diff --git a/boost.patches/boost-51.description b/boost.patches/boost-51.description new file mode 100644 index 0000000..ab896a1 --- /dev/null +++ b/boost.patches/boost-51.description
@@ -0,0 +1 @@ +This patch applies upstream change set 67067 <https://svn.boost.org/trac/boost/changeset/67067> for issue 4930 <https://svn.boost.org/trac/boost/ticket/4930>.
diff --git a/boost.patches/boost-51.patch b/boost.patches/boost-51.patch new file mode 100644 index 0000000..a7ffbec --- /dev/null +++ b/boost.patches/boost-51.patch
@@ -0,0 +1,28 @@ +--- a/libs/filesystem/v2/src/v2_operations.cpp 2010-08-10 13:00:09.000000000 -0700 ++++ b/libs/filesystem/v2/src/v2_operations.cpp 2011-06-16 17:28:00.000000000 -0700 +@@ -1215,8 +1214,9 @@ + if ( ::stat( from_file_ph.c_str(), &from_stat ) != 0 ) + { return error_code( errno, system_category() ); } + +- int oflag = O_CREAT | O_WRONLY; +- if ( fail_if_exists ) oflag |= O_EXCL; ++ int oflag = O_CREAT | O_WRONLY | O_TRUNC; ++ if ( fail_if_exists ) ++ oflag |= O_EXCL; + if ( (outfile = ::open( to_file_ph.c_str(), oflag, from_stat.st_mode )) < 0 ) + { + int open_errno = errno; +--- a/libs/filesystem/v3/src/operations.cpp 2010-10-16 06:09:25.000000000 -0700 ++++ b/libs/filesystem/v3/src/operations.cpp 2011-06-16 17:28:00.000000000 -0700 +@@ -426,8 +433,9 @@ + if (::stat(from_p.c_str(), &from_stat)!= 0) + { return false; } + +- int oflag = O_CREAT | O_WRONLY; +- if (fail_if_exists)oflag |= O_EXCL; ++ int oflag = O_CREAT | O_WRONLY | O_TRUNC; ++ if (fail_if_exists) ++ oflag |= O_EXCL; + if ((outfile = ::open(to_p.c_str(), oflag, from_stat.st_mode))< 0) + { + int open_errno = errno;
diff --git a/boost.patches/boost-52.description b/boost.patches/boost-52.description new file mode 100644 index 0000000..98582d2 --- /dev/null +++ b/boost.patches/boost-52.description
@@ -0,0 +1 @@ +This patch resolves compiler errors / warnings regarding shadow variables in boost::numeric::ublas.
diff --git a/boost.patches/boost-52.patch b/boost.patches/boost-52.patch new file mode 100644 index 0000000..aeae509 --- /dev/null +++ b/boost.patches/boost-52.patch
@@ -0,0 +1,1948 @@ +diff -aruN a/boost/archive/basic_archive.hpp b/boost/archive/basic_archive.hpp +--- a/boost/archive/basic_archive.hpp 2010-11-06 09:31:31.000000000 -0700 ++++ b/boost/archive/basic_archive.hpp 2012-02-07 15:25:24.619334954 -0800 +@@ -254,7 +254,7 @@ + #define BOOST_ARCHIVE_STRONG_TYPEDEF(T, D) \ + class D : public T { \ + public: \ +- explicit D(const T t) : T(t){} \ ++ explicit D(const T t) : T(type){} \ + }; \ + /**/ + +diff -aruN a/boost/numeric/ublas/banded.hpp b/boost/numeric/ublas/banded.hpp +--- a/boost/numeric/ublas/banded.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/banded.hpp 2012-02-07 15:25:24.623735807 -0800 +@@ -63,16 +63,16 @@ + size1_ (0), size2_ (0), + lower_ (0), upper_ (0), data_ (0) {} + BOOST_UBLAS_INLINE +- banded_matrix (size_type size1, size_type size2, size_type lower = 0, size_type upper = 0): ++ banded_matrix (size_type s1, size_type s2, size_type l = 0, size_type u = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), +- lower_ (lower), upper_ (upper), data_ ((std::max) (size1, size2) * (lower + 1 + upper)) { ++ size1_ (s1), size2_ (s2), ++ lower_ (l), upper_ (u), data_ ((std::max) (s1, s2) * (l + 1 + u)) { + } + BOOST_UBLAS_INLINE +- banded_matrix (size_type size1, size_type size2, size_type lower, size_type upper, const array_type &data): ++ banded_matrix (size_type s1, size_type s2, size_type l, size_type u, const array_type &d): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), +- lower_ (lower), upper_ (upper), data_ (data) {} ++ size1_ (s1), size2_ (s2), ++ lower_ (l), upper_ (u), data_ (d) {} + BOOST_UBLAS_INLINE + banded_matrix (const banded_matrix &m): + matrix_container<self_type> (), +@@ -80,10 +80,10 @@ + lower_ (m.lower_), upper_ (m.upper_), data_ (m.data_) {} + template<class AE> + BOOST_UBLAS_INLINE +- banded_matrix (const matrix_expression<AE> &ae, size_type lower = 0, size_type upper = 0): ++ banded_matrix (const matrix_expression<AE> &ae, size_type l = 0, size_type u = 0): + matrix_container<self_type> (), + size1_ (ae ().size1 ()), size2_ (ae ().size2 ()), +- lower_ (lower), upper_ (upper), ++ lower_ (l), upper_ (u), + data_ ((std::max) (size1_, size2_) * (lower_ + 1 + upper_)) { + matrix_assign<scalar_assign> (*this, ae); + } +@@ -118,27 +118,27 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, size_type lower = 0, size_type upper = 0, bool preserve = true) { ++ void resize (size_type s1, size_type s2, size_type l = 0, size_type u = 0, bool preserve = true) { + if (preserve) { +- self_type temporary (size1, size2, lower, upper); ++ self_type temporary (s1, s2, l, u); + detail::matrix_resize_preserve<layout_type> (*this, temporary); + } + else { +- data ().resize ((std::max) (size1, size2) * (lower + 1 + upper)); +- size1_ = size1; +- size2_ = size2; +- lower_ = lower; +- upper_ = upper; ++ data ().resize ((std::max) (s1, s2) * (l + 1 + u)); ++ size1_ = s1; ++ size2_ = s2; ++ lower_ = l; ++ upper_ = u; + } + } + + BOOST_UBLAS_INLINE +- void resize_packed_preserve (size_type size1, size_type size2, size_type lower = 0, size_type upper = 0) { +- size1_ = size1; +- size2_ = size2; +- lower_ = lower; +- upper_ = upper; +- data ().resize ((std::max) (size1, size2) * (lower + 1 + upper), value_type ()); ++ void resize_packed_preserve (size_type s1, size_type s2, size_type l = 0, size_type u = 0) { ++ size1_ = s1; ++ size2_ = s2; ++ lower_ = l; ++ upper_ = u; ++ data ().resize ((std::max) (size1, size2) * (l + 1 + u), value_type ()); + } + + // Element access +@@ -1082,9 +1082,9 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- banded_adaptor (matrix_type &data, size_type lower = 0, size_type upper = 0): ++ banded_adaptor (matrix_type &d, size_type l = 0, size_type u = 0): + matrix_expression<self_type> (), +- data_ (data), lower_ (lower), upper_ (upper) {} ++ data_ (d), lower_ (l), upper_ (u) {} + BOOST_UBLAS_INLINE + banded_adaptor (const banded_adaptor &m): + matrix_expression<self_type> (), +diff -aruN a/boost/numeric/ublas/detail/matrix_assign.hpp b/boost/numeric/ublas/detail/matrix_assign.hpp +--- a/boost/numeric/ublas/detail/matrix_assign.hpp 2010-10-19 00:01:35.000000000 -0700 ++++ b/boost/numeric/ublas/detail/matrix_assign.hpp 2012-02-07 15:25:24.623735807 -0800 +@@ -75,21 +75,21 @@ + if (it2 != it2_end && it2e != it2e_end) { + size_type it2_index = it2.index2 (), it2e_index = it2e.index2 (); + while (true) { +- difference_type compare = it2_index - it2e_index; +- if (compare == 0) { ++ difference_type compare2 = it2_index - it2e_index; ++ if (compare2 == 0) { + ++ it2, ++ it2e; + if (it2 != it2_end && it2e != it2e_end) { + it2_index = it2.index2 (); + it2e_index = it2e.index2 (); + } else + break; +- } else if (compare < 0) { +- increment (it2, it2_end, - compare); ++ } else if (compare2 < 0) { ++ increment (it2, it2_end, - compare2); + if (it2 != it2_end) + it2_index = it2.index2 (); + else + break; +- } else if (compare > 0) { ++ } else if (compare2 > 0) { + if (conformant_restrict_type::other (it2e.index1 (), it2e.index2 ())) + if (static_cast<value_type>(*it2e) != value_type/*zero*/()) + index.push_back (std::pair<size_type, size_type> (it2e.index1 (), it2e.index2 ())); +@@ -178,21 +178,21 @@ + if (it1 != it1_end && it1e != it1e_end) { + size_type it1_index = it1.index1 (), it1e_index = it1e.index1 (); + while (true) { +- difference_type compare = it1_index - it1e_index; +- if (compare == 0) { ++ difference_type compare2 = it1_index - it1e_index; ++ if (compare2 == 0) { + ++ it1, ++ it1e; + if (it1 != it1_end && it1e != it1e_end) { + it1_index = it1.index1 (); + it1e_index = it1e.index1 (); + } else + break; +- } else if (compare < 0) { +- increment (it1, it1_end, - compare); ++ } else if (compare2 < 0) { ++ increment (it1, it1_end, - compare2); + if (it1 != it1_end) + it1_index = it1.index1 (); + else + break; +- } else if (compare > 0) { ++ } else if (compare2 > 0) { + if (conformant_restrict_type::other (it1e.index1 (), it1e.index2 ())) + if (static_cast<value_type>(*it1e) != value_type/*zero*/()) + index.push_back (std::pair<size_type, size_type> (it1e.index1 (), it1e.index2 ())); +@@ -997,8 +997,8 @@ + if (it2 != it2_end && it2e != it2e_end) { + size_type it2_index = it2.index2 (), it2e_index = it2e.index2 (); + while (true) { +- difference_type compare = it2_index - it2e_index; +- if (compare == 0) { ++ difference_type compare2 = it2_index - it2e_index; ++ if (compare2 == 0) { + functor_type::apply (*it2, *it2e); + ++ it2, ++ it2e; + if (it2 != it2_end && it2e != it2e_end) { +@@ -1006,18 +1006,18 @@ + it2e_index = it2e.index2 (); + } else + break; +- } else if (compare < 0) { ++ } else if (compare2 < 0) { + if (!functor_type::computed) { + functor_type::apply (*it2, expr_value_type/*zero*/()); + ++ it2; + } else +- increment (it2, it2_end, - compare); ++ increment (it2, it2_end, - compare2); + if (it2 != it2_end) + it2_index = it2.index2 (); + else + break; +- } else if (compare > 0) { +- increment (it2e, it2e_end, compare); ++ } else if (compare2 > 0) { ++ increment (it2e, it2e_end, compare2); + if (it2e != it2e_end) + it2e_index = it2e.index2 (); + else +@@ -1118,8 +1118,8 @@ + if (it1 != it1_end && it1e != it1e_end) { + size_type it1_index = it1.index1 (), it1e_index = it1e.index1 (); + while (true) { +- difference_type compare = it1_index - it1e_index; +- if (compare == 0) { ++ difference_type compare2 = it1_index - it1e_index; ++ if (compare2 == 0) { + functor_type::apply (*it1, *it1e); + ++ it1, ++ it1e; + if (it1 != it1_end && it1e != it1e_end) { +@@ -1127,18 +1127,18 @@ + it1e_index = it1e.index1 (); + } else + break; +- } else if (compare < 0) { ++ } else if (compare2 < 0) { + if (!functor_type::computed) { + functor_type::apply (*it1, expr_value_type/*zero*/()); // zeroing + ++ it1; + } else +- increment (it1, it1_end, - compare); ++ increment (it1, it1_end, - compare2); + if (it1 != it1_end) + it1_index = it1.index1 (); + else + break; +- } else if (compare > 0) { +- increment (it1e, it1e_end, compare); ++ } else if (compare2 > 0) { ++ increment (it1e, it1e_end, compare2); + if (it1e != it1e_end) + it1e_index = it1e.index1 (); + else +@@ -1386,8 +1386,8 @@ + if (it2 != it2_end && it2e != it2e_end) { + size_type it2_index = it2.index2 (), it2e_index = it2e.index2 (); + while (true) { +- difference_type compare = it2_index - it2e_index; +- if (compare == 0) { ++ difference_type compare2 = it2_index - it2e_index; ++ if (compare2 == 0) { + functor_type::apply (*it2, *it2e); + ++ it2, ++ it2e; + if (it2 != it2_end && it2e != it2e_end) { +@@ -1395,14 +1395,14 @@ + it2e_index = it2e.index2 (); + } else + break; +- } else if (compare < 0) { +- increment (it2, it2_end, - compare); ++ } else if (compare2 < 0) { ++ increment (it2, it2_end, - compare2); + if (it2 != it2_end) + it2_index = it2.index2 (); + else + break; +- } else if (compare > 0) { +- increment (it2e, it2e_end, compare); ++ } else if (compare2 > 0) { ++ increment (it2e, it2e_end, compare2); + if (it2e != it2e_end) + it2e_index = it2e.index2 (); + else +@@ -1511,8 +1511,8 @@ + if (it1 != it1_end && it1e != it1e_end) { + size_type it1_index = it1.index1 (), it1e_index = it1e.index1 (); + while (true) { +- difference_type compare = it1_index - it1e_index; +- if (compare == 0) { ++ difference_type compare2 = it1_index - it1e_index; ++ if (compare2 == 0) { + functor_type::apply (*it1, *it1e); + ++ it1, ++ it1e; + if (it1 != it1_end && it1e != it1e_end) { +@@ -1520,14 +1520,14 @@ + it1e_index = it1e.index1 (); + } else + break; +- } else if (compare < 0) { +- increment (it1, it1_end, - compare); ++ } else if (compare2 < 0) { ++ increment (it1, it1_end, - compare2); + if (it1 != it1_end) + it1_index = it1.index1 (); + else + break; +- } else if (compare > 0) { +- increment (it1e, it1e_end, compare); ++ } else if (compare2 > 0) { ++ increment (it1e, it1e_end, compare2); + if (it1e != it1e_end) + it1e_index = it1e.index1 (); + else +diff -aruN a/boost/numeric/ublas/hermitian.hpp b/boost/numeric/ublas/hermitian.hpp +--- a/boost/numeric/ublas/hermitian.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/hermitian.hpp 2012-02-07 15:25:24.627228060 -0800 +@@ -284,14 +284,14 @@ + size_ (BOOST_UBLAS_SAME (size, size)), data_ (triangular_type::packed_size (layout_type (), size, size)) { + } + BOOST_UBLAS_INLINE +- hermitian_matrix (size_type size1, size_type size2): ++ hermitian_matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size_ (BOOST_UBLAS_SAME (size1, size2)), data_ (triangular_type::packed_size (layout_type (), size1, size2)) { ++ size_ (BOOST_UBLAS_SAME (s1, s2)), data_ (triangular_type::packed_size (layout_type (), s1, s2)) { + } + BOOST_UBLAS_INLINE +- hermitian_matrix (size_type size, const array_type &data): ++ hermitian_matrix (size_type s, const array_type &d): + matrix_container<self_type> (), +- size_ (size), data_ (data) {} ++ size_ (s), data_ (d) {} + BOOST_UBLAS_INLINE + hermitian_matrix (const hermitian_matrix &m): + matrix_container<self_type> (), +@@ -338,8 +338,8 @@ + } + } + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { +- resize (BOOST_UBLAS_SAME (size1, size2), preserve); ++ void resize (size_type s1, size_type s2, bool preserve = true) { ++ resize (BOOST_UBLAS_SAME (s1, s2), preserve); + } + BOOST_UBLAS_INLINE + void resize_packed_preserve (size_type size) { +@@ -1192,9 +1192,9 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- hermitian_adaptor (matrix_type &data): ++ hermitian_adaptor (matrix_type &d): + matrix_expression<self_type> (), +- data_ (data) { ++ data_ (d) { + BOOST_UBLAS_CHECK (data_.size1 () == data_.size2 (), bad_size ()); + } + BOOST_UBLAS_INLINE +@@ -1508,11 +1508,11 @@ + it1_begin_ (), it1_end_ (), it1_ (), + it2_begin_ (), it2_end_ (), it2_ () {} + BOOST_UBLAS_INLINE +- const_iterator1 (const self_type &m, int begin, int end, ++ const_iterator1 (const self_type &m, int b, int e, + const const_subiterator1_type &it1_begin, const const_subiterator1_type &it1_end, + const const_subiterator2_type &it2_begin, const const_subiterator2_type &it2_end): + container_const_reference<self_type> (m), +- begin_ (begin), end_ (end), current_ (begin), ++ begin_ (b), end_ (e), current_ (b), + it1_begin_ (it1_begin), it1_end_ (it1_end), it1_ (it1_begin_), + it2_begin_ (it2_begin), it2_end_ (it2_end), it2_ (it2_begin_) { + if (current_ == 0 && it1_ == it1_end_) +@@ -1962,11 +1962,11 @@ + it1_begin_ (), it1_end_ (), it1_ (), + it2_begin_ (), it2_end_ (), it2_ () {} + BOOST_UBLAS_INLINE +- const_iterator2 (const self_type &m, int begin, int end, ++ const_iterator2 (const self_type &m, int b, int e, + const const_subiterator1_type &it1_begin, const const_subiterator1_type &it1_end, + const const_subiterator2_type &it2_begin, const const_subiterator2_type &it2_end): + container_const_reference<self_type> (m), +- begin_ (begin), end_ (end), current_ (begin), ++ begin_ (b), end_ (e), current_ (b), + it1_begin_ (it1_begin), it1_end_ (it1_end), it1_ (it1_begin_), + it2_begin_ (it2_begin), it2_end_ (it2_end), it2_ (it2_begin_) { + if (current_ == 0 && it1_ == it1_end_) +diff -aruN a/boost/numeric/ublas/matrix_expression.hpp b/boost/numeric/ublas/matrix_expression.hpp +--- a/boost/numeric/ublas/matrix_expression.hpp 2009-10-06 16:31:22.000000000 -0700 ++++ b/boost/numeric/ublas/matrix_expression.hpp 2012-02-07 15:25:24.627228060 -0800 +@@ -1918,39 +1918,39 @@ + // Sparse specializations + BOOST_UBLAS_INLINE + void increment (sparse_bidirectional_iterator_tag) { +- size_type index1 = (*this) ().size1 (); ++ size_type temp_index1 = (*this) ().size1 (); + if (it1_ != it1_end_) { + if (it1_.index1 () <= i_) + ++ it1_; + if (it1_ != it1_end_) +- index1 = it1_.index1 (); ++ temp_index1 = it1_.index1 (); + } +- size_type index2 = (*this) ().size1 (); ++ size_type temp_index2 = (*this) ().size1 (); + if (it2_ != it2_end_) + if (it2_.index1 () <= i_) + ++ it2_; + if (it2_ != it2_end_) { +- index2 = it2_.index1 (); ++ temp_index2 = it2_.index1 (); + } +- i_ = (std::min) (index1, index2); ++ i_ = (std::min) (temp_index1, temp_index2); + } + BOOST_UBLAS_INLINE + void decrement (sparse_bidirectional_iterator_tag) { +- size_type index1 = (*this) ().size1 (); ++ size_type temp_index1 = (*this) ().size1 (); + if (it1_ != it1_end_) { + if (i_ <= it1_.index1 ()) + -- it1_; + if (it1_ != it1_end_) +- index1 = it1_.index1 (); ++ temp_index1 = it1_.index1 (); + } +- size_type index2 = (*this) ().size1 (); ++ size_type temp_index2 = (*this) ().size1 (); + if (it2_ != it2_end_) { + if (i_ <= it2_.index1 ()) + -- it2_; + if (it2_ != it2_end_) +- index2 = it2_.index1 (); ++ temp_index2 = it2_.index1 (); + } +- i_ = (std::max) (index1, index2); ++ i_ = (std::max) (temp_index1, temp_index2); + } + BOOST_UBLAS_INLINE + void increment (sparse_bidirectional_iterator_tag, difference_type n) { +@@ -2233,39 +2233,39 @@ + // Sparse specializations + BOOST_UBLAS_INLINE + void increment (sparse_bidirectional_iterator_tag) { +- size_type index1 = (*this) ().size2 (); ++ size_type temp_index1 = (*this) ().size2 (); + if (it1_ != it1_end_) { + if (it1_.index2 () <= j_) + ++ it1_; + if (it1_ != it1_end_) + index1 = it1_.index2 (); + } +- size_type index2 = (*this) ().size2 (); ++ size_type temp_index2 = (*this) ().size2 (); + if (it2_ != it2_end_) { + if (it2_.index2 () <= j_) + ++ it2_; + if (it2_ != it2_end_) + index2 = it2_.index2 (); + } +- j_ = (std::min) (index1, index2); ++ j_ = (std::min) (temp_index1, temp_index2); + } + BOOST_UBLAS_INLINE + void decrement (sparse_bidirectional_iterator_tag) { +- size_type index1 = (*this) ().size2 (); ++ size_type temp_index1 = (*this) ().size2 (); + if (it1_ != it1_end_) { + if (j_ <= it1_.index2 ()) + -- it1_; + if (it1_ != it1_end_) + index1 = it1_.index2 (); + } +- size_type index2 = (*this) ().size2 (); ++ size_type temp_index2 = (*this) ().size2 (); + if (it2_ != it2_end_) { + if (j_ <= it2_.index2 ()) + -- it2_; + if (it2_ != it2_end_) + index2 = it2_.index2 (); + } +- j_ = (std::max) (index1, index2); ++ j_ = (std::max) (temp_index1, temp_index2); + } + BOOST_UBLAS_INLINE + void increment (sparse_bidirectional_iterator_tag, difference_type n) { +diff -aruN a/boost/numeric/ublas/matrix.hpp b/boost/numeric/ublas/matrix.hpp +--- a/boost/numeric/ublas/matrix.hpp 2010-10-19 00:01:35.000000000 -0700 ++++ b/boost/numeric/ublas/matrix.hpp 2012-02-07 15:25:24.631348942 -0800 +@@ -126,9 +126,9 @@ + * \param size2 number of columns + */ + BOOST_UBLAS_INLINE +- matrix (size_type size1, size_type size2): ++ matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (layout_type::storage_size (size1, size2)) { ++ size1_ (s1), size2_ (s2), data_ (layout_type::storage_size (s1, s2)) { + } + + /** Dense matrix constructor with defined size a initial value for all the matrix elements +@@ -136,9 +136,9 @@ + * \param size2 number of columns + * \param init initial value assigned to all elements + */ +- matrix (size_type size1, size_type size2, const value_type &init): ++ matrix (size_type s1, size_type s2, const value_type &init): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (layout_type::storage_size (size1, size2), init) { ++ size1_ (s1), size2_ (s2), data_ (layout_type::storage_size (s1, s2), init) { + } + + /** Dense matrix constructor with defined size and an initial data array +@@ -147,9 +147,9 @@ + * \param data array to copy into the matrix. Must have the same dimension as the matrix + */ + BOOST_UBLAS_INLINE +- matrix (size_type size1, size_type size2, const array_type &data): ++ matrix (size_type s1, size_type s2, const array_type &d): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (data) {} ++ size1_ (s1), size2_ (s2), data_ (d) {} + + /** Copy-constructor of a dense matrix + * \param m is a dense matrix +@@ -212,15 +212,15 @@ + * \param preserve a boolean to say if one wants the data to be preserved during the resizing. Default is true. + */ + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + if (preserve) { +- self_type temporary (size1, size2); ++ self_type temporary (s1, s2); + detail::matrix_resize_preserve<layout_type> (*this, temporary); + } + else { +- data ().resize (layout_type::storage_size (size1, size2)); +- size1_ = size1; +- size2_ = size2; ++ data ().resize (layout_type::storage_size (s1, s2)); ++ size1_ = s1; ++ size2_ = s2; + } + } + +@@ -1186,10 +1186,10 @@ + matrix_container<self_type> (), + size1_ (0), size2_ (0), data_ (1) {} + BOOST_UBLAS_INLINE +- vector_of_vector (size_type size1, size_type size2): ++ vector_of_vector (size_type s1, size_type s2): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (1) { +- resize (size1, size2, true); ++ size1_ (s1), size2_ (s2), data_ (1) { ++ resize (s1, s2, true); + } + BOOST_UBLAS_INLINE + vector_of_vector (const vector_of_vector &m): +@@ -1227,18 +1227,18 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { +- size1_ = size1; +- size2_ = size2; ++ void resize (size_type s1, size_type s2, bool preserve = true) { ++ size1_ = s1; ++ size2_ = s2; + if (preserve) +- data ().resize (layout_type::size_M (size1, size2) + 1, typename array_type::value_type ()); ++ data ().resize (layout_type::size_M (s1, s2) + 1, typename array_type::value_type ()); + else +- data ().resize (layout_type::size_M (size1, size2) + 1); +- for (size_type k = 0; k < layout_type::size_M (size1, size2); ++ k) { ++ data ().resize (layout_type::size_M (s1, s2) + 1); ++ for (size_type k = 0; k < layout_type::size_M (s1, s2); ++ k) { + if (preserve) +- data () [k].resize (layout_type::size_m (size1, size2), value_type ()); ++ data () [k].resize (layout_type::size_m (s1, s2), value_type ()); + else +- data () [k].resize (layout_type::size_m (size1, size2)); ++ data () [k].resize (layout_type::size_m (s1, s2)); + } + } + +@@ -2171,9 +2171,9 @@ + matrix_container<self_type> (), + size1_ (size), size2_ (size) {} + BOOST_UBLAS_INLINE +- zero_matrix (size_type size1, size_type size2): ++ zero_matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2) {} ++ size1_ (s1), size2_ (s2) {} + BOOST_UBLAS_INLINE + zero_matrix (const zero_matrix &m): + matrix_container<self_type> (), +@@ -2196,9 +2196,9 @@ + size2_ = size; + } + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool /*preserve*/ = true) { +- size1_ = size1; +- size2_ = size2; ++ void resize (size_type s1, size_type s2, bool /*preserve*/ = true) { ++ size1_ = s1; ++ size2_ = s2; + } + + // Element access +@@ -2558,9 +2558,9 @@ + matrix_container<self_type> (), + size1_ (size), size2_ (size), size_common_ ((std::min) (size1_, size2_)) {} + BOOST_UBLAS_INLINE +- identity_matrix (size_type size1, size_type size2): ++ identity_matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), size_common_ ((std::min) (size1_, size2_)) {} ++ size1_ (s1), size2_ (s2), size_common_ ((std::min) (size1_, size2_)) {} + BOOST_UBLAS_INLINE + identity_matrix (const identity_matrix &m): + matrix_container<self_type> (), +@@ -2584,9 +2584,9 @@ + size_common_ = ((std::min)(size1_, size2_)); + } + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool /*preserve*/ = true) { +- size1_ = size1; +- size2_ = size2; ++ void resize (size_type s1, size_type s2, bool /*preserve*/ = true) { ++ size1_ = s1; ++ size2_ = s2; + size_common_ = ((std::min)(size1_, size2_)); + } + +@@ -2970,9 +2970,9 @@ + matrix_container<self_type> (), + size1_ (0), size2_ (0), value_ () {} + BOOST_UBLAS_INLINE +- scalar_matrix (size_type size1, size_type size2, const value_type &value = value_type(1)): ++ scalar_matrix (size_type s1, size_type s2, const value_type &value = value_type(1)): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), value_ (value) {} ++ size1_ (s1), size2_ (s2), value_ (value) {} + BOOST_UBLAS_INLINE + scalar_matrix (const scalar_matrix &m): + matrix_container<self_type> (), +@@ -2990,9 +2990,9 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool /*preserve*/ = true) { +- size1_ = size1; +- size2_ = size2; ++ void resize (size_type s1, size_type s2, bool /*preserve*/ = true) { ++ size1_ = s1; ++ size2_ = s2; + } + + // Element access +@@ -3446,8 +3446,8 @@ + size1_ (N), size2_ (M) /* , data_ () */ { + } + BOOST_UBLAS_INLINE +- c_matrix (size_type size1, size_type size2): +- size1_ (size1), size2_ (size2) /* , data_ () */ { ++ c_matrix (size_type s1, size_type s2): ++ size1_ (s1), size2_ (s2) /* , data_ () */ { + if (size1_ > N || size2_ > M) + bad_size ().raise (); + } +@@ -3487,14 +3487,14 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { +- if (size1 > N || size2 > M) ++ void resize (size_type s1, size_type s2, bool preserve = true) { ++ if (s1 > N || s2 > M) + bad_size ().raise (); + if (preserve) { +- self_type temporary (size1, size2); ++ self_type temporary (s1, s2); + // Common elements to preserve +- const size_type size1_min = (std::min) (size1, size1_); +- const size_type size2_min = (std::min) (size2, size2_); ++ const size_type size1_min = (std::min) (s1, size1_); ++ const size_type size2_min = (std::min) (s2, size2_); + for (size_type i = 0; i != size1_min; ++i) { // indexing copy over major + for (size_type j = 0; j != size2_min; ++j) { + temporary.data_[i][j] = data_[i][j]; +@@ -3503,8 +3503,8 @@ + assign_temporary (temporary); + } + else { +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + } + } + +diff -aruN a/boost/numeric/ublas/matrix_proxy.hpp b/boost/numeric/ublas/matrix_proxy.hpp +--- a/boost/numeric/ublas/matrix_proxy.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/matrix_proxy.hpp 2012-02-07 15:25:24.631348942 -0800 +@@ -51,8 +51,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_row (matrix_type &data, size_type i): +- data_ (data), i_ (i) { ++ matrix_row (matrix_type &d, size_type i): ++ data_ (d), i_ (i) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (i_ < data_.size1 (), bad_index ()); + } +@@ -508,8 +508,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_column (matrix_type &data, size_type j): +- data_ (data), j_ (j) { ++ matrix_column (matrix_type &d, size_type j): ++ data_ (d), j_ (j) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (j_ < data_.size2 (), bad_index ()); + } +@@ -965,8 +965,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_vector_range (matrix_type &data, const range_type &r1, const range_type &r2): +- data_ (data), r1_ (r1.preprocess (data.size1 ())), r2_ (r2.preprocess (data.size2 ())) { ++ matrix_vector_range (matrix_type &d, const range_type &r1, const range_type &r2): ++ data_ (d), r1_ (r1.preprocess (d.size1 ())), r2_ (r2.preprocess (d.size2 ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (r1_.start () <= data_.size1 () && + // r1_.start () + r1_.size () <= data_.size1 (), bad_index ()); +@@ -1421,8 +1421,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_vector_slice (matrix_type &data, const slice_type &s1, const slice_type &s2): +- data_ (data), s1_ (s1.preprocess (data.size1 ())), s2_ (s2.preprocess (data.size2 ())) { ++ matrix_vector_slice (matrix_type &d, const slice_type &s1, const slice_type &s2): ++ data_ (d), s1_ (s1.preprocess (d.size1 ())), s2_ (s2.preprocess (d.size2 ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (s1_.start () <= data_.size1 () && + // s1_.start () + s1_.stride () * (s1_.size () - (s1_.size () > 0)) <= data_.size1 (), bad_index ()); +@@ -1886,11 +1886,11 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_vector_indirect (matrix_type &data, size_type size): +- data_ (data), ia1_ (size), ia2_ (size) {} ++ matrix_vector_indirect (matrix_type &d, size_type s): ++ data_ (d), ia1_ (s), ia2_ (s) {} + BOOST_UBLAS_INLINE +- matrix_vector_indirect (matrix_type &data, const indirect_array_type &ia1, const indirect_array_type &ia2): +- data_ (data), ia1_ (ia1), ia2_ (ia2) { ++ matrix_vector_indirect (matrix_type &d, const indirect_array_type &ia1, const indirect_array_type &ia2): ++ data_ (d), ia1_ (ia1), ia2_ (ia2) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (ia1_.size () == ia2_.size (), bad_size ()); + } +@@ -2351,8 +2351,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_range (matrix_type &data, const range_type &r1, const range_type &r2): +- data_ (data), r1_ (r1.preprocess (data.size1 ())), r2_ (r2.preprocess (data.size2 ())) { ++ matrix_range (matrix_type &d, const range_type &r1, const range_type &r2): ++ data_ (d), r1_ (r1.preprocess (d.size1 ())), r2_ (r2.preprocess (d.size2 ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (r1_.start () <= data_.size1 () && + // r1_.start () + r1_.size () <= data_.size1 (), bad_index ()); +@@ -2360,8 +2360,8 @@ + // r2_.start () + r2_.size () <= data_.size2 (), bad_index ()); + } + BOOST_UBLAS_INLINE +- matrix_range (const matrix_closure_type &data, const range_type &r1, const range_type &r2, int): +- data_ (data), r1_ (r1.preprocess (data.size1 ())), r2_ (r2.preprocess (data.size2 ())) { ++ matrix_range (const matrix_closure_type &d, const range_type &r1, const range_type &r2, int): ++ data_ (d), r1_ (r1.preprocess (d.size1 ())), r2_ (r2.preprocess (d.size2 ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (r1_.start () <= data_.size1 () && + // r1_.start () + r1_.size () <= data_.size1 (), bad_index ()); +@@ -3255,8 +3255,8 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_slice (matrix_type &data, const slice_type &s1, const slice_type &s2): +- data_ (data), s1_ (s1.preprocess (data.size1 ())), s2_ (s2.preprocess (data.size2 ())) { ++ matrix_slice (matrix_type &d, const slice_type &s1, const slice_type &s2): ++ data_ (d), s1_ (s1.preprocess (d.size1 ())), s2_ (s2.preprocess (d.size2 ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (s1_.start () <= data_.size1 () && + // s1_.start () + s1_.stride () * (s1_.size () - (s1_.size () > 0)) <= data_.size1 (), bad_index ()); +@@ -3264,8 +3264,8 @@ + // s2_.start () + s2_.stride () * (s2_.size () - (s2_.size () > 0)) <= data_.size2 (), bad_index ()); + } + BOOST_UBLAS_INLINE +- matrix_slice (const matrix_closure_type &data, const slice_type &s1, const slice_type &s2, int): +- data_ (data), s1_ (s1.preprocess (data.size1 ())), s2_ (s2.preprocess (data.size2 ())) { ++ matrix_slice (const matrix_closure_type &d, const slice_type &s1, const slice_type &s2, int): ++ data_ (d), s1_ (s1.preprocess (d.size1 ())), s2_ (s2.preprocess (d.size2 ())) { + // Early checking of preconditions. + // BOOST_UBLAS_CHECK (s1_.start () <= data_.size1 () && + // s1_.start () + s1_.stride () * (s1_.size () - (s1_.size () > 0)) <= data_.size1 (), bad_index ()); +@@ -4213,14 +4213,14 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- matrix_indirect (matrix_type &data, size_type size1, size_type size2): +- data_ (data), ia1_ (size1), ia2_ (size2) {} ++ matrix_indirect (matrix_type &d, size_type s1, size_type s2): ++ data_ (d), ia1_ (s1), ia2_ (s2) {} + BOOST_UBLAS_INLINE +- matrix_indirect (matrix_type &data, const indirect_array_type &ia1, const indirect_array_type &ia2): +- data_ (data), ia1_ (ia1.preprocess (data.size1 ())), ia2_ (ia2.preprocess (data.size2 ())) {} ++ matrix_indirect (matrix_type &d, const indirect_array_type &ia1, const indirect_array_type &ia2): ++ data_ (d), ia1_ (ia1.preprocess (d.size1 ())), ia2_ (ia2.preprocess (d.size2 ())) {} + BOOST_UBLAS_INLINE +- matrix_indirect (const matrix_closure_type &data, const indirect_array_type &ia1, const indirect_array_type &ia2, int): +- data_ (data), ia1_ (ia1.preprocess (data.size1 ())), ia2_ (ia2.preprocess (data.size2 ())) {} ++ matrix_indirect (const matrix_closure_type &d, const indirect_array_type &ia1, const indirect_array_type &ia2, int): ++ data_ (d), ia1_ (ia1.preprocess (d.size1 ())), ia2_ (ia2.preprocess (d.size2 ())) {} + + // Accessors + BOOST_UBLAS_INLINE +diff -aruN a/boost/numeric/ublas/matrix_sparse.hpp b/boost/numeric/ublas/matrix_sparse.hpp +--- a/boost/numeric/ublas/matrix_sparse.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/matrix_sparse.hpp 2012-02-07 15:25:24.635307503 -0800 +@@ -300,9 +300,9 @@ + matrix_container<self_type> (), + size1_ (0), size2_ (0), data_ () {} + BOOST_UBLAS_INLINE +- mapped_matrix (size_type size1, size_type size2, size_type non_zeros = 0): ++ mapped_matrix (size_type s1, size_type s2, size_type non_zeros = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ () { ++ size1_ (s1), size2_ (s2), data_ () { + detail::map_reserve (data (), restrict_capacity (non_zeros)); + } + BOOST_UBLAS_INLINE +@@ -358,11 +358,11 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + // FIXME preserve unimplemented + BOOST_UBLAS_CHECK (!preserve, internal_logic ()); +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + data ().clear (); + } + +@@ -1373,9 +1373,9 @@ + data_ [layout_type::size_M (size1_, size2_)] = vector_data_value_type (); + } + BOOST_UBLAS_INLINE +- mapped_vector_of_mapped_vector (size_type size1, size_type size2, size_type non_zeros = 0): ++ mapped_vector_of_mapped_vector (size_type s1, size_type s2, size_type non_zeros = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ () { ++ size1_ (s1), size2_ (s2), data_ () { + data_ [layout_type::size_M (size1_, size2_)] = vector_data_value_type (); + } + BOOST_UBLAS_INLINE +@@ -1427,11 +1427,11 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + // FIXME preserve unimplemented + BOOST_UBLAS_CHECK (!preserve, internal_logic ()); +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + data ().clear (); + data () [layout_type::size_M (size1_, size2_)] = vector_data_value_type (); + } +@@ -2666,9 +2666,9 @@ + storage_invariants (); + } + BOOST_UBLAS_INLINE +- compressed_matrix (size_type size1, size_type size2, size_type non_zeros = 0): ++ compressed_matrix (size_type s1, size_type s2, size_type non_zeros = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), capacity_ (restrict_capacity (non_zeros)), ++ size1_ (s1), size2_ (s2), capacity_ (restrict_capacity (non_zeros)), + filled1_ (1), filled2_ (0), + index1_data_ (layout_type::size_M (size1_, size2_) + 1), index2_data_ (capacity_), value_data_ (capacity_) { + index1_data_ [filled1_ - 1] = k_based (filled2_); +@@ -2764,9 +2764,9 @@ + return value_data_; + } + BOOST_UBLAS_INLINE +- void set_filled (const array_size_type& filled1, const array_size_type& filled2) { +- filled1_ = filled1; +- filled2_ = filled2; ++ void set_filled (const array_size_type& f1, const array_size_type& f2) { ++ filled1_ = f1; ++ filled2_ = f2; + storage_invariants (); + } + BOOST_UBLAS_INLINE +@@ -2802,11 +2802,11 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + // FIXME preserve unimplemented + BOOST_UBLAS_CHECK (!preserve, internal_logic ()); +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + capacity_ = restrict_capacity (capacity_); + filled1_ = 1; + filled2_ = 0; +@@ -4045,9 +4045,9 @@ + storage_invariants (); + } + BOOST_UBLAS_INLINE +- coordinate_matrix (size_type size1, size_type size2, array_size_type non_zeros = 0): ++ coordinate_matrix (size_type s1, size_type s2, array_size_type non_zeros = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), capacity_ (restrict_capacity (non_zeros)), ++ size1_ (s1), size2_ (s2), capacity_ (restrict_capacity (non_zeros)), + filled_ (0), sorted_filled_ (filled_), sorted_ (true), + index1_data_ (capacity_), index2_data_ (capacity_), value_data_ (capacity_) { + storage_invariants (); +@@ -4111,13 +4111,13 @@ + return value_data_; + } + BOOST_UBLAS_INLINE +- void set_filled (const array_size_type &filled) { ++ void set_filled (const array_size_type &f) { + // Make sure that storage_invariants() succeeds +- if (sorted_ && filled < filled_) +- sorted_filled_ = filled; ++ if (sorted_ && f < filled_) ++ sorted_filled_ = f; + else +- sorted_ = (sorted_filled_ == filled); +- filled_ = filled; ++ sorted_ = (sorted_filled_ == f); ++ filled_ = f; + storage_invariants (); + } + BOOST_UBLAS_INLINE +@@ -4144,11 +4144,11 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + // FIXME preserve unimplemented + BOOST_UBLAS_CHECK (!preserve, internal_logic ()); +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + capacity_ = restrict_capacity (capacity_); + index1_data_.resize (capacity_); + index2_data_.resize (capacity_); +@@ -4403,21 +4403,21 @@ + std::inplace_merge (ita.begin (), iunsorted, ita.end ()); + + // sum duplicates with += and remove +- array_size_type filled = 0; ++ array_size_type f = 0; + for (array_size_type i = 1; i < filled_; ++ i) { +- if (index1_data_ [filled] != index1_data_ [i] || +- index2_data_ [filled] != index2_data_ [i]) { +- ++ filled; +- if (filled != i) { +- index1_data_ [filled] = index1_data_ [i]; +- index2_data_ [filled] = index2_data_ [i]; +- value_data_ [filled] = value_data_ [i]; ++ if (index1_data_ [f] != index1_data_ [i] || ++ index2_data_ [f] != index2_data_ [i]) { ++ ++ f; ++ if (f != i) { ++ index1_data_ [f] = index1_data_ [i]; ++ index2_data_ [f] = index2_data_ [i]; ++ value_data_ [f] = value_data_ [i]; + } + } else { +- value_data_ [filled] += value_data_ [i]; ++ value_data_ [f] += value_data_ [i]; + } + } +- filled_ = filled + 1; ++ filled_ = f + 1; + sorted_filled_ = filled_; + sorted_ = true; + storage_invariants (); +diff -aruN a/boost/numeric/ublas/storage.hpp b/boost/numeric/ublas/storage.hpp +--- a/boost/numeric/ublas/storage.hpp 2010-04-06 13:09:04.000000000 -0700 ++++ b/boost/numeric/ublas/storage.hpp 2012-02-07 15:25:24.635307503 -0800 +@@ -62,8 +62,8 @@ + data_ = 0; + } + explicit BOOST_UBLAS_INLINE +- unbounded_array (size_type size, const ALLOC &a = ALLOC()): +- alloc_(a), size_ (size) { ++ unbounded_array (size_type s, const ALLOC &a = ALLOC()): ++ alloc_(a), size_ (s) { + if (size_) { + data_ = alloc_.allocate (size_); + if (! detail::has_trivial_constructor<T>::value) { +@@ -76,8 +76,8 @@ + } + // No value initialised, but still be default constructed + BOOST_UBLAS_INLINE +- unbounded_array (size_type size, const value_type &init, const ALLOC &a = ALLOC()): +- alloc_ (a), size_ (size) { ++ unbounded_array (size_type s, const value_type &init, const ALLOC &a = ALLOC()): ++ alloc_ (a), size_ (s) { + if (size_) { + data_ = alloc_.allocate (size_); + std::uninitialized_fill (begin(), end(), init); +@@ -113,33 +113,33 @@ + // Resizing + private: + BOOST_UBLAS_INLINE +- void resize_internal (const size_type size, const value_type init, const bool preserve) { +- if (size != size_) { ++ void resize_internal (const size_type s, const value_type init, const bool preserve) { ++ if (s != size_) { + pointer p_data = data_; +- if (size) { +- data_ = alloc_.allocate (size); ++ if (s) { ++ data_ = alloc_.allocate (s); + if (preserve) { + pointer si = p_data; + pointer di = data_; +- if (size < size_) { +- for (; di != data_ + size; ++di) { ++ if (s < size_) { ++ for (; di != data_ + s; ++di) { + alloc_.construct (di, *si); + ++si; + } + } + else { +- for (pointer si = p_data; si != p_data + size_; ++si) { +- alloc_.construct (di, *si); ++ for (pointer si2 = p_data; si2 != p_data + size_; ++si) { ++ alloc_.construct (di, *si2); + ++di; + } +- for (; di != data_ + size; ++di) { ++ for (; di != data_ + s; ++di) { + alloc_.construct (di, init); + } + } + } + else { + if (! detail::has_trivial_constructor<T>::value) { +- for (pointer di = data_; di != data_ + size; ++di) ++ for (pointer di = data_; di != data_ + s; ++di) + alloc_.construct (di, value_type()); + } + } +@@ -153,19 +153,19 @@ + alloc_.deallocate (p_data, size_); + } + +- if (!size) ++ if (!s) + data_ = 0; +- size_ = size; ++ size_ = s; + } + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size) { +- resize_internal (size, value_type (), false); ++ void resize (size_type s) { ++ resize_internal (s, value_type (), false); + } + BOOST_UBLAS_INLINE +- void resize (size_type size, value_type init) { +- resize_internal (size, init, true); ++ void resize (size_type s, value_type init) { ++ resize_internal (s, init, true); + } + + // Random Access Container +@@ -318,14 +318,14 @@ + size_ (0) /*, data_ ()*/ { // size 0 - use bounded_vector to default construct with size N + } + explicit BOOST_UBLAS_INLINE +- bounded_array (size_type size): +- size_ (size) /*, data_ ()*/ { ++ bounded_array (size_type s): ++ size_ (s) /*, data_ ()*/ { + BOOST_UBLAS_CHECK (size_ <= N, bad_size ()); + // data_ (an array) elements are already default constructed + } + BOOST_UBLAS_INLINE +- bounded_array (size_type size, const value_type &init): +- size_ (size) /*, data_ ()*/ { ++ bounded_array (size_type s, const value_type &init): ++ size_ (s) /*, data_ ()*/ { + BOOST_UBLAS_CHECK (size_ <= N, bad_size ()); + // ISSUE elements should be value constructed here, but we must fill instead as already default constructed + std::fill (begin(), end(), init) ; +@@ -339,16 +339,16 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size) { +- BOOST_UBLAS_CHECK (size <= N, bad_size ()); +- size_ = size; ++ void resize (size_type s) { ++ BOOST_UBLAS_CHECK (s <= N, bad_size ()); ++ size_ = s; + } + BOOST_UBLAS_INLINE +- void resize (size_type size, value_type init) { +- BOOST_UBLAS_CHECK (size <= N, bad_size ()); +- if (size > size_) +- std::fill (data_ + size_, data_ + size, init); +- size_ = size; ++ void resize (size_type s, value_type init) { ++ BOOST_UBLAS_CHECK (s <= N, bad_size ()); ++ if (s > size_) ++ std::fill (data_ + size_, data_ + s, init); ++ size_ = s; + } + + // Random Access Container +@@ -489,17 +489,17 @@ + size_ (0), own_ (true), data_ (new value_type [0]) { + } + explicit BOOST_UBLAS_INLINE +- array_adaptor (size_type size): +- size_ (size), own_ (true), data_ (new value_type [size]) { ++ array_adaptor (size_type s): ++ size_ (s), own_ (true), data_ (new value_type [s]) { + } + BOOST_UBLAS_INLINE +- array_adaptor (size_type size, const value_type &init): +- size_ (size), own_ (true), data_ (new value_type [size]) { ++ array_adaptor (size_type s, const value_type &init): ++ size_ (s), own_ (true), data_ (new value_type [s]) { + std::fill (data_, data_ + size_, init); + } + BOOST_UBLAS_INLINE +- array_adaptor (size_type size, pointer data): +- size_ (size), own_ (false), data_ (data) {} ++ array_adaptor (size_type s, pointer d): ++ size_ (s), own_ (false), data_ (d) {} + BOOST_UBLAS_INLINE + array_adaptor (const array_adaptor &a): + storage_array<self_type> (), +@@ -516,26 +516,26 @@ + // Resizing + private: + BOOST_UBLAS_INLINE +- void resize_internal (size_type size, value_type init, bool preserve = true) { +- if (size != size_) { +- pointer data = new value_type [size]; ++ void resize_internal (size_type s, value_type init, bool preserve = true) { ++ if (s != size_) { ++ pointer data = new value_type [s]; + if (preserve) { +- std::copy (data_, data_ + (std::min) (size, size_), data); +- std::fill (data + (std::min) (size, size_), data + size, init); ++ std::copy (data_, data_ + (std::min) (s, size_), data); ++ std::fill (data + (std::min) (s, size_), data + s, init); + } + if (own_) + delete [] data_; +- size_ = size; ++ size_ = s; + own_ = true; + data_ = data; + } + } + BOOST_UBLAS_INLINE +- void resize_internal (size_type size, pointer data, value_type init, bool preserve = true) { ++ void resize_internal (size_type s, pointer data, value_type init, bool preserve = true) { + if (data != data_) { + if (preserve) { +- std::copy (data_, data_ + (std::min) (size, size_), data); +- std::fill (data + (std::min) (size, size_), data + size, init); ++ std::copy (data_, data_ + (std::min) (s, size_), data); ++ std::fill (data + (std::min) (s, size_), data + s, init); + } + if (own_) + delete [] data_; +@@ -543,26 +543,26 @@ + data_ = data; + } + else { +- std::fill (data + (std::min) (size, size_), data + size, init); ++ std::fill (data + (std::min) (s, size_), data + s, init); + } +- size_ = size; ++ size_ = s; + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size) { +- resize_internal (size, value_type (), false); ++ void resize (size_type s) { ++ resize_internal (s, value_type (), false); + } + BOOST_UBLAS_INLINE +- void resize (size_type size, value_type init) { +- resize_internal (size, init, true); ++ void resize (size_type s, value_type init) { ++ resize_internal (s, init, true); + } + BOOST_UBLAS_INLINE +- void resize (size_type size, pointer data) { +- resize_internal (size, data, value_type (), false); ++ void resize (size_type s, pointer data) { ++ resize_internal (s, data, value_type (), false); + } + BOOST_UBLAS_INLINE +- void resize (size_type size, pointer data, value_type init) { +- resize_internal (size, data, init, true); ++ void resize (size_type s, pointer data, value_type init) { ++ resize_internal (s, data, init, true); + } + + BOOST_UBLAS_INLINE +@@ -882,9 +882,9 @@ + basic_range (): + start_ (0), size_ (0) {} + BOOST_UBLAS_INLINE +- basic_range (size_type start, size_type stop): +- start_ (start), size_ (stop - start) { +- BOOST_UBLAS_CHECK (start_ <= stop, bad_index ()); ++ basic_range (size_type in_start, size_type in_stop): ++ start_ (in_start), size_ (in_stop - in_start) { ++ BOOST_UBLAS_CHECK (start_ <= in_stop, bad_index ()); + } + + BOOST_UBLAS_INLINE +@@ -1055,10 +1055,10 @@ + } + + BOOST_UBLAS_INLINE +- basic_range preprocess (size_type size) const { ++ basic_range preprocess (size_type s) const { + if (this != &all_) + return *this; +- return basic_range (0, size); ++ return basic_range (0, s); + } + static + BOOST_UBLAS_INLINE +@@ -1094,8 +1094,8 @@ + basic_slice (): + start_ (0), stride_ (0), size_ (0) {} + BOOST_UBLAS_INLINE +- basic_slice (size_type start, difference_type stride, size_type size): +- start_ (start), stride_ (stride), size_ (size) {} ++ basic_slice (size_type in_start, difference_type in_stride, size_type in_size): ++ start_ (in_start), stride_ (in_stride), size_ (in_size) {} + + BOOST_UBLAS_INLINE + size_type start () const { +@@ -1274,10 +1274,10 @@ + } + + BOOST_UBLAS_INLINE +- basic_slice preprocess (size_type size) const { ++ basic_slice preprocess (size_type s) const { + if (this != &all_) + return *this; +- return basic_slice (0, 1, size); ++ return basic_slice (0, 1, s); + } + static + BOOST_UBLAS_INLINE +@@ -1316,11 +1316,11 @@ + indirect_array (): + size_ (), data_ () {} + explicit BOOST_UBLAS_INLINE +- indirect_array (size_type size): +- size_ (size), data_ (size) {} ++ indirect_array (size_type s): ++ size_ (s), data_ (s) {} + BOOST_UBLAS_INLINE +- indirect_array (size_type size, const array_type &data): +- size_ (size), data_ (data) {} ++ indirect_array (size_type s, const array_type &d): ++ size_ (s), data_ (d) {} + BOOST_UBLAS_INLINE + indirect_array (pointer start, pointer stop): + size_ (stop - start), data_ (stop - start) { +@@ -1376,27 +1376,27 @@ + BOOST_UBLAS_INLINE + indirect_array compose (const basic_range<size_type, difference_type> &r) const { + BOOST_UBLAS_CHECK (r.start () + r.size () <= size_, bad_size ()); +- array_type data (r.size ()); ++ array_type local_data (r.size ()); + for (size_type i = 0; i < r.size (); ++ i) +- data [i] = data_ [r.start () + i]; +- return indirect_array (r.size (), data); ++ local_data [i] = data_ [r.start () + i]; ++ return indirect_array (r.size (), local_data); + } + BOOST_UBLAS_INLINE + indirect_array compose (const basic_slice<size_type, difference_type> &s) const { + BOOST_UBLAS_CHECK (s.start () + s.stride () * (s.size () - (s.size () > 0)) <= size (), bad_size ()); +- array_type data (s.size ()); ++ array_type local_data (s.size ()); + for (size_type i = 0; i < s.size (); ++ i) +- data [i] = data_ [s.start () + s.stride () * i]; +- return indirect_array (s.size (), data); ++ local_data [i] = data_ [s.start () + s.stride () * i]; ++ return indirect_array (s.size (), local_data); + } + BOOST_UBLAS_INLINE + indirect_array compose (const indirect_array &ia) const { +- array_type data (ia.size_); ++ array_type local_data (ia.size_); + for (size_type i = 0; i < ia.size_; ++ i) { + BOOST_UBLAS_CHECK (ia.data_ [i] <= size_, bad_size ()); +- data [i] = data_ [ia.data_ [i]]; ++ local_data [i] = data_ [ia.data_ [i]]; + } +- return indirect_array (ia.size_, data); ++ return indirect_array (ia.size_, local_data); + } + + // Comparison +@@ -1534,11 +1534,11 @@ + } + + BOOST_UBLAS_INLINE +- indirect_array preprocess (size_type size) const { ++ indirect_array preprocess (size_type s) const { + if (this != &all_) + return *this; +- indirect_array ia (size); +- for (size_type i = 0; i < size; ++ i) ++ indirect_array ia (s); ++ for (size_type i = 0; i < s; ++ i) + ia (i) = i; + return ia; + } +@@ -1666,8 +1666,8 @@ + typedef const value_type const_reference; + + BOOST_UBLAS_INLINE +- index_pair_array(size_type size, V1& data1, V2& data2) : +- size_(size),data1_(data1),data2_(data2) {} ++ index_pair_array(size_type s, V1& data1, V2& data2) : ++ size_(s),data1_(data1),data2_(data2) {} + + BOOST_UBLAS_INLINE + size_type size() const { +@@ -1841,8 +1841,8 @@ + typedef const value_type const_reference; + + BOOST_UBLAS_INLINE +- index_triple_array(size_type size, V1& data1, V2& data2, V3& data3) : +- size_(size),data1_(data1),data2_(data2),data3_(data3) {} ++ index_triple_array(size_type s, V1& data1, V2& data2, V3& data3) : ++ size_(s),data1_(data1),data2_(data2),data3_(data3) {} + + BOOST_UBLAS_INLINE + size_type size() const { +diff -aruN a/boost/numeric/ublas/storage_sparse.hpp b/boost/numeric/ublas/storage_sparse.hpp +--- a/boost/numeric/ublas/storage_sparse.hpp 2009-03-09 13:24:11.000000000 -0700 ++++ b/boost/numeric/ublas/storage_sparse.hpp 2012-02-07 15:25:24.635307503 -0800 +@@ -263,38 +263,38 @@ + private: + // Resizing - implicitly exposses uninitialized (but default constructed) mapped_type + BOOST_UBLAS_INLINE +- void resize (size_type size) { ++ void resize (size_type s) { + BOOST_UBLAS_CHECK (size_ <= capacity_, internal_logic ()); +- if (size > capacity_) { +- const size_type capacity = size << 1; +- BOOST_UBLAS_CHECK (capacity, internal_logic ()); +- pointer data = alloc_.allocate (capacity); +- std::uninitialized_copy (data_, data_ + (std::min) (size, size_), data); +- std::uninitialized_fill (data + (std::min) (size, size_), data + capacity, value_type ()); ++ if (s > capacity_) { ++ const size_type cap = s << 1; ++ BOOST_UBLAS_CHECK (cap, internal_logic ()); ++ pointer data = alloc_.allocate (cap); ++ std::uninitialized_copy (data_, data_ + (std::min) (s, size_), data); ++ std::uninitialized_fill (data + (std::min) (s, size_), data + cap, value_type ()); + + if (capacity_) { + std::for_each (data_, data_ + capacity_, static_destroy); + alloc_.deallocate (data_, capacity_); + } +- capacity_ = capacity; ++ capacity_ = cap; + data_ = data; + } +- size_ = size; ++ size_ = s; + BOOST_UBLAS_CHECK (size_ <= capacity_, internal_logic ()); + } + public: + + // Reserving + BOOST_UBLAS_INLINE +- void reserve (size_type capacity) { ++ void reserve (size_type cap) { + BOOST_UBLAS_CHECK (size_ <= capacity_, internal_logic ()); + // Reduce capacity_ if size_ allows +- BOOST_UBLAS_CHECK (capacity >= size_, bad_size ()); ++ BOOST_UBLAS_CHECK (cap >= size_, bad_size ()); + pointer data; +- if (capacity) { +- data = alloc_.allocate (capacity); ++ if (cap) { ++ data = alloc_.allocate (cap); + std::uninitialized_copy (data_, data_ + size_, data); +- std::uninitialized_fill (data + size_, data + capacity, value_type ()); ++ std::uninitialized_fill (data + size_, data + cap, value_type ()); + } + else + data = 0; +@@ -303,7 +303,7 @@ + std::for_each (data_, data_ + capacity_, static_destroy); + alloc_.deallocate (data_, capacity_); + } +- capacity_ = capacity; ++ capacity_ = cap; + data_ = data; + BOOST_UBLAS_CHECK (size_ <= capacity_, internal_logic ()); + } +diff -aruN a/boost/numeric/ublas/symmetric.hpp b/boost/numeric/ublas/symmetric.hpp +--- a/boost/numeric/ublas/symmetric.hpp 2009-10-06 16:53:19.000000000 -0700 ++++ b/boost/numeric/ublas/symmetric.hpp 2012-02-07 15:25:24.635307503 -0800 +@@ -76,14 +76,14 @@ + size_ (BOOST_UBLAS_SAME (size, size)), data_ (triangular_type::packed_size (layout_type (), size, size)) { + } + BOOST_UBLAS_INLINE +- symmetric_matrix (size_type size1, size_type size2): ++ symmetric_matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size_ (BOOST_UBLAS_SAME (size1, size2)), data_ (triangular_type::packed_size (layout_type (), size1, size2)) { ++ size_ (BOOST_UBLAS_SAME (s1, s2)), data_ (triangular_type::packed_size (layout_type (), s1, s2)) { + } + BOOST_UBLAS_INLINE +- symmetric_matrix (size_type size, const array_type &data): ++ symmetric_matrix (size_type size, const array_type &d): + matrix_container<self_type> (), +- size_ (size), data_ (data) {} ++ size_ (size), data_ (d) {} + BOOST_UBLAS_INLINE + symmetric_matrix (const symmetric_matrix &m): + matrix_container<self_type> (), +@@ -130,8 +130,8 @@ + } + } + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { +- resize (BOOST_UBLAS_SAME (size1, size2), preserve); ++ void resize (size_type s1, size_type s2, bool preserve = true) { ++ resize (BOOST_UBLAS_SAME (s1, s2), preserve); + } + BOOST_UBLAS_INLINE + void resize_packed_preserve (size_type size) { +@@ -944,9 +944,9 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- symmetric_adaptor (matrix_type &data): ++ symmetric_adaptor (matrix_type &d): + matrix_expression<self_type> (), +- data_ (data) { ++ data_ (d) { + BOOST_UBLAS_CHECK (data_.size1 () == data_.size2 (), bad_size ()); + } + BOOST_UBLAS_INLINE +@@ -1201,11 +1201,11 @@ + it1_begin_ (), it1_end_ (), it1_ (), + it2_begin_ (), it2_end_ (), it2_ () {} + BOOST_UBLAS_INLINE +- const_iterator1 (const self_type &m, int begin, int end, ++ const_iterator1 (const self_type &m, int b, int e, + const const_subiterator1_type &it1_begin, const const_subiterator1_type &it1_end, + const const_subiterator2_type &it2_begin, const const_subiterator2_type &it2_end): + container_const_reference<self_type> (m), +- begin_ (begin), end_ (end), current_ (begin), ++ begin_ (b), end_ (e), current_ (b), + it1_begin_ (it1_begin), it1_end_ (it1_end), it1_ (it1_begin_), + it2_begin_ (it2_begin), it2_end_ (it2_end), it2_ (it2_begin_) { + if (current_ == 0 && it1_ == it1_end_) +@@ -1648,11 +1648,11 @@ + it1_begin_ (), it1_end_ (), it1_ (), + it2_begin_ (), it2_end_ (), it2_ () {} + BOOST_UBLAS_INLINE +- const_iterator2 (const self_type &m, int begin, int end, ++ const_iterator2 (const self_type &m, int b, int e, + const const_subiterator1_type &it1_begin, const const_subiterator1_type &it1_end, + const const_subiterator2_type &it2_begin, const const_subiterator2_type &it2_end): + container_const_reference<self_type> (m), +- begin_ (begin), end_ (end), current_ (begin), ++ begin_ (b), end_ (e), current_ (b), + it1_begin_ (it1_begin), it1_end_ (it1_end), it1_ (it1_begin_), + it2_begin_ (it2_begin), it2_end_ (it2_end), it2_ (it2_begin_) { + if (current_ == 0 && it1_ == it1_end_) +diff -aruN a/boost/numeric/ublas/triangular.hpp b/boost/numeric/ublas/triangular.hpp +--- a/boost/numeric/ublas/triangular.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/triangular.hpp 2012-02-07 15:25:24.639286239 -0800 +@@ -106,14 +106,14 @@ + matrix_container<self_type> (), + size1_ (0), size2_ (0), data_ (0) {} + BOOST_UBLAS_INLINE +- triangular_matrix (size_type size1, size_type size2): ++ triangular_matrix (size_type s1, size_type s2): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (triangular_type::packed_size (layout_type (), size1, size2)) { ++ size1_ (s1), size2_ (s2), data_ (triangular_type::packed_size (layout_type (), s1, s2)) { + } + BOOST_UBLAS_INLINE +- triangular_matrix (size_type size1, size_type size2, const array_type &data): ++ triangular_matrix (size_type s1, size_type s2, const array_type &d): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (data) {} ++ size1_ (s1), size2_ (s2), data_ (d) {} + BOOST_UBLAS_INLINE + triangular_matrix (const triangular_matrix &m): + matrix_container<self_type> (), +@@ -149,21 +149,21 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + if (preserve) { +- self_type temporary (size1, size2); ++ self_type temporary (s1, s2); + detail::matrix_resize_preserve<layout_type, triangular_type> (*this, temporary); + } + else { +- data ().resize (triangular_type::packed_size (layout_type (), size1, size2)); +- size1_ = size1; +- size2_ = size2; ++ data ().resize (triangular_type::packed_size (layout_type (), s1, s2)); ++ size1_ = s1; ++ size2_ = s2; + } + } + BOOST_UBLAS_INLINE +- void resize_packed_preserve (size_type size1, size_type size2) { +- size1_ = size1; +- size2_ = size2; ++ void resize_packed_preserve (size_type s1, size_type s2) { ++ size1_ = s1; ++ size2_ = s2; + data ().resize (triangular_type::packed_size (layout_type (), size1_, size2_), value_type ()); + } + +@@ -996,9 +996,9 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- triangular_adaptor (matrix_type &data): ++ triangular_adaptor (matrix_type &d): + matrix_expression<self_type> (), +- data_ (data) {} ++ data_ (d) {} + BOOST_UBLAS_INLINE + triangular_adaptor (const triangular_adaptor &m): + matrix_expression<self_type> (), +diff -aruN a/boost/numeric/ublas/vector.hpp b/boost/numeric/ublas/vector.hpp +--- a/boost/numeric/ublas/vector.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/vector.hpp 2012-02-07 15:25:24.639286239 -0800 +@@ -72,9 +72,9 @@ + /// By default, its elements are initialized to 0. + /// \param size initial size of the vector + explicit BOOST_UBLAS_INLINE +- vector (size_type size): ++ vector (size_type s): + vector_container<self_type> (), +- data_ (size) { ++ data_ (s) { + } + + /// \brief Constructor of a vector by copying from another container +@@ -83,25 +83,25 @@ + /// \param data container of type \c A + /// \todo remove this definition because \c size is not used + BOOST_UBLAS_INLINE +- vector (size_type size, const array_type &data): ++ vector (size_type s, const array_type &d): + vector_container<self_type> (), +- data_ (data) {} ++ data_ (d) {} + + /// \brief Constructor of a vector by copying from another container + /// This type has the generic name \c array_typ within the vector definition. + /// \param data container of type \c A + BOOST_UBLAS_INLINE +- vector (const array_type &data): ++ vector (const array_type &d): + vector_container<self_type> (), +- data_ (data) {} ++ data_ (d) {} + + /// \brief Constructor of a vector with a predefined size and a unique initial value + /// \param size of the vector + /// \param init value to assign to each element of the vector + BOOST_UBLAS_INLINE +- vector (size_type size, const value_type &init): ++ vector (size_type s, const value_type &init): + vector_container<self_type> (), +- data_ (size, init) {} ++ data_ (s, init) {} + + /// \brief Copy-constructor of a vector + /// \param v is the vector to be duplicated +@@ -175,11 +175,11 @@ + /// \param size new size of the vector + /// \param preserve if true, keep values + BOOST_UBLAS_INLINE +- void resize (size_type size, bool preserve = true) { ++ void resize (size_type s, bool preserve = true) { + if (preserve) +- data ().resize (size, typename A::value_type ()); ++ data ().resize (s, typename A::value_type ()); + else +- data ().resize (size); ++ data ().resize (s); + } + + // --------------- +@@ -900,9 +900,9 @@ + vector_container<self_type> (), + size_ (0) {} + explicit BOOST_UBLAS_INLINE +- zero_vector (size_type size): ++ zero_vector (size_type s): + vector_container<self_type> (), +- size_ (size) {} ++ size_ (s) {} + BOOST_UBLAS_INLINE + zero_vector (const zero_vector &v): + vector_container<self_type> (), +@@ -916,8 +916,8 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size, bool /*preserve*/ = true) { +- size_ = size; ++ void resize (size_type s, bool /*preserve*/ = true) { ++ size_ = s; + } + + // Element support +@@ -1110,9 +1110,9 @@ + /// \param size is the dimension of the vector + /// \param index is the order of the vector + BOOST_UBLAS_INLINE +- explicit unit_vector (size_type size, size_type index = 0): ++ explicit unit_vector (size_type s, size_type i = 0): + vector_container<self_type> (), +- size_ (size), index_ (index) {} ++ size_ (s), index_ (i) {} + + /// \brief Copy-constructor + BOOST_UBLAS_INLINE +@@ -1141,8 +1141,8 @@ + /// \brief Resize the vector. The values are preserved by default (i.e. the index does not change) + /// \param size is the new size of the vector + BOOST_UBLAS_INLINE +- void resize (size_type size, bool /*preserve*/ = true) { +- size_ = size; ++ void resize (size_type s, bool /*preserve*/ = true) { ++ size_ = s; + } + + // Element support +@@ -1352,9 +1352,9 @@ + vector_container<self_type> (), + size_ (0), value_ () {} + BOOST_UBLAS_INLINE +- explicit scalar_vector (size_type size, const value_type &value = value_type(1)): ++ explicit scalar_vector (size_type s, const value_type &value = value_type(1)): + vector_container<self_type> (), +- size_ (size), value_ (value) {} ++ size_ (s), value_ (value) {} + BOOST_UBLAS_INLINE + scalar_vector (const scalar_vector &v): + vector_container<self_type> (), +@@ -1368,8 +1368,8 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size, bool /*preserve*/ = true) { +- size_ = size; ++ void resize (size_type s, bool /*preserve*/ = true) { ++ size_ = s; + } + + // Element support +@@ -1594,8 +1594,8 @@ + c_vector (): + size_ (N) /* , data_ () */ {} + explicit BOOST_UBLAS_INLINE +- c_vector (size_type size): +- size_ (size) /* , data_ () */ { ++ c_vector (size_type s): ++ size_ (s) /* , data_ () */ { + if (size_ > N) + bad_size ().raise (); + } +@@ -1631,10 +1631,10 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size, bool preserve = true) { +- if (size > N) ++ void resize (size_type s, bool preserve = true) { ++ if (s > N) + bad_size ().raise (); +- size_ = size; ++ size_ = s; + } + + // Element support +diff -aruN a/boost/numeric/ublas/vector_of_vector.hpp b/boost/numeric/ublas/vector_of_vector.hpp +--- a/boost/numeric/ublas/vector_of_vector.hpp 2007-11-25 10:07:19.000000000 -0800 ++++ b/boost/numeric/ublas/vector_of_vector.hpp 2012-02-07 15:25:24.639286239 -0800 +@@ -66,9 +66,9 @@ + storage_invariants (); + } + BOOST_UBLAS_INLINE +- generalized_vector_of_vector (size_type size1, size_type size2, size_type non_zeros = 0): ++ generalized_vector_of_vector (size_type s1, size_type s2, size_type non_zeros = 0): + matrix_container<self_type> (), +- size1_ (size1), size2_ (size2), data_ (layout_type::size_M (size1_, size2_) + 1) { ++ size1_ (s1), size2_ (s2), data_ (layout_type::size_M (size1_, size2_) + 1) { + const size_type sizeM = layout_type::size_M (size1_, size2_); + const size_type sizem = layout_type::size_m (size1_, size2_); + for (size_type i = 0; i < sizeM; ++ i) // create size1 vector elements +@@ -132,10 +132,10 @@ + + // Resizing + BOOST_UBLAS_INLINE +- void resize (size_type size1, size_type size2, bool preserve = true) { ++ void resize (size_type s1, size_type s2, bool preserve = true) { + const size_type oldM = layout_type::size_M (size1_, size2_); +- size1_ = size1; +- size2_ = size2; ++ size1_ = s1; ++ size2_ = s2; + const size_type sizeM = layout_type::size_M (size1_, size2_); + const size_type sizem = layout_type::size_m (size1_, size2_); + data ().resize (sizeM + 1, preserve); +diff -aruN a/boost/numeric/ublas/vector_proxy.hpp b/boost/numeric/ublas/vector_proxy.hpp +--- a/boost/numeric/ublas/vector_proxy.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/vector_proxy.hpp 2012-02-07 15:25:24.639286239 -0800 +@@ -59,15 +59,15 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- vector_range (vector_type &data, const range_type &r): +- data_ (data), r_ (r.preprocess (data.size ())) { ++ vector_range (vector_type &d, const range_type &r): ++ data_ (d), r_ (r.preprocess (d.size ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (r_.start () <= data_.size () && + // r_.start () + r_.size () <= data_.size (), bad_index ()); + } + BOOST_UBLAS_INLINE +- vector_range (const vector_closure_type &data, const range_type &r, bool): +- data_ (data), r_ (r.preprocess (data.size ())) { ++ vector_range (const vector_closure_type &d, const range_type &r, bool): ++ data_ (d), r_ (r.preprocess (d.size ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (r_.start () <= data_.size () && + // r_.start () + r_.size () <= data_.size (), bad_index ()); +@@ -614,15 +614,15 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- vector_slice (vector_type &data, const slice_type &s): +- data_ (data), s_ (s.preprocess (data.size ())) { ++ vector_slice (vector_type &d, const slice_type &s): ++ data_ (d), s_ (s.preprocess (d.size ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (s_.start () <= data_.size () && + // s_.start () + s_.stride () * (s_.size () - (s_.size () > 0)) <= data_.size (), bad_index ()); + } + BOOST_UBLAS_INLINE +- vector_slice (const vector_closure_type &data, const slice_type &s, int): +- data_ (data), s_ (s.preprocess (data.size ())) { ++ vector_slice (const vector_closure_type &d, const slice_type &s, int): ++ data_ (d), s_ (s.preprocess (d.size ())) { + // Early checking of preconditions here. + // BOOST_UBLAS_CHECK (s_.start () <= data_.size () && + // s_.start () + s_.stride () * (s_.size () - (s_.size () > 0)) <= data_.size (), bad_index ()); +@@ -1159,14 +1159,14 @@ + + // Construction and destruction + BOOST_UBLAS_INLINE +- vector_indirect (vector_type &data, size_type size): +- data_ (data), ia_ (size) {} ++ vector_indirect (vector_type &d, size_type s): ++ data_ (d), ia_ (s) {} + BOOST_UBLAS_INLINE +- vector_indirect (vector_type &data, const indirect_array_type &ia): +- data_ (data), ia_ (ia.preprocess (data.size ())) {} ++ vector_indirect (vector_type &d, const indirect_array_type &ia): ++ data_ (d), ia_ (ia.preprocess (d.size ())) {} + BOOST_UBLAS_INLINE +- vector_indirect (const vector_closure_type &data, const indirect_array_type &ia, int): +- data_ (data), ia_ (ia.preprocess (data.size ())) {} ++ vector_indirect (const vector_closure_type &d, const indirect_array_type &ia, int): ++ data_ (d), ia_ (ia.preprocess (d.size ())) {} + + // Accessors + BOOST_UBLAS_INLINE +diff -aruN a/boost/numeric/ublas/vector_sparse.hpp b/boost/numeric/ublas/vector_sparse.hpp +--- a/boost/numeric/ublas/vector_sparse.hpp 2010-07-04 23:06:24.000000000 -0700 ++++ b/boost/numeric/ublas/vector_sparse.hpp 2012-02-07 15:25:24.639286239 -0800 +@@ -309,9 +309,9 @@ + vector_container<self_type> (), + size_ (0), data_ () {} + BOOST_UBLAS_INLINE +- mapped_vector (size_type size, size_type non_zeros = 0): ++ mapped_vector (size_type s, size_type non_zeros = 0): + vector_container<self_type> (), +- size_ (size), data_ () { ++ size_ (s), data_ () { + detail::map_reserve (data(), restrict_capacity (non_zeros)); + } + BOOST_UBLAS_INLINE +@@ -360,8 +360,8 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size, bool preserve = true) { +- size_ = size; ++ void resize (size_type s, bool preserve = true) { ++ size_ = s; + if (preserve) { + data ().erase (data ().lower_bound(size_), data ().end()); + } +@@ -832,9 +832,9 @@ + storage_invariants (); + } + explicit BOOST_UBLAS_INLINE +- compressed_vector (size_type size, size_type non_zeros = 0): ++ compressed_vector (size_type s, size_type non_zeros = 0): + vector_container<self_type> (), +- size_ (size), capacity_ (restrict_capacity (non_zeros)), filled_ (0), ++ size_ (s), capacity_ (restrict_capacity (non_zeros)), filled_ (0), + index_data_ (capacity_), value_data_ (capacity_) { + storage_invariants (); + } +@@ -887,8 +887,8 @@ + return value_data_; + } + BOOST_UBLAS_INLINE +- void set_filled (const typename index_array_type::size_type & filled) { +- filled_ = filled; ++ void set_filled (const typename index_array_type::size_type & f) { ++ filled_ = f; + storage_invariants (); + } + BOOST_UBLAS_INLINE +@@ -910,14 +910,14 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size, bool preserve = true) { +- size_ = size; ++ void resize (size_type s, bool preserve = true) { ++ size_ = s; + capacity_ = restrict_capacity (capacity_); + if (preserve) { + index_data_. resize (capacity_, size_type ()); + value_data_. resize (capacity_, value_type ()); + filled_ = (std::min) (capacity_, filled_); +- while ((filled_ > 0) && (zero_based(index_data_[filled_ - 1]) >= size)) { ++ while ((filled_ > 0) && (zero_based(index_data_[filled_ - 1]) >= s)) { + --filled_; + } + } +@@ -1473,9 +1473,9 @@ + storage_invariants (); + } + explicit BOOST_UBLAS_INLINE +- coordinate_vector (size_type size, size_type non_zeros = 0): ++ coordinate_vector (size_type s, size_type non_zeros = 0): + vector_container<self_type> (), +- size_ (size), capacity_ (restrict_capacity (non_zeros)), ++ size_ (s), capacity_ (restrict_capacity (non_zeros)), + filled_ (0), sorted_filled_ (filled_), sorted_ (true), + index_data_ (capacity_), value_data_ (capacity_) { + storage_invariants (); +@@ -1531,9 +1531,9 @@ + return value_data_; + } + BOOST_UBLAS_INLINE +- void set_filled (const typename index_array_type::size_type &sorted, const typename index_array_type::size_type &filled) { ++ void set_filled (const typename index_array_type::size_type &sorted, const typename index_array_type::size_type &f) { + sorted_filled_ = sorted; +- filled_ = filled; ++ filled_ = f; + storage_invariants (); + } + BOOST_UBLAS_INLINE +@@ -1556,16 +1556,16 @@ + } + public: + BOOST_UBLAS_INLINE +- void resize (size_type size, bool preserve = true) { ++ void resize (size_type s, bool preserve = true) { + if (preserve) + sort (); // remove duplicate elements. +- size_ = size; ++ size_ = s; + capacity_ = restrict_capacity (capacity_); + if (preserve) { + index_data_. resize (capacity_, size_type ()); + value_data_. resize (capacity_, value_type ()); + filled_ = (std::min) (capacity_, filled_); +- while ((filled_ > 0) && (zero_based(index_data_[filled_ - 1]) >= size)) { ++ while ((filled_ > 0) && (zero_based(index_data_[filled_ - 1]) >= s)) { + --filled_; + } + } +@@ -1813,19 +1813,19 @@ + std::inplace_merge (ipa.begin (), iunsorted, ipa.end ()); + + // sum duplicates with += and remove +- size_type filled = 0; ++ size_type f = 0; + for (size_type i = 1; i < filled_; ++ i) { +- if (index_data_ [filled] != index_data_ [i]) { +- ++ filled; +- if (filled != i) { +- index_data_ [filled] = index_data_ [i]; +- value_data_ [filled] = value_data_ [i]; ++ if (index_data_ [f] != index_data_ [i]) { ++ ++ f; ++ if (f != i) { ++ index_data_ [f] = index_data_ [i]; ++ value_data_ [f] = value_data_ [i]; + } + } else { +- value_data_ [filled] += value_data_ [i]; ++ value_data_ [f] += value_data_ [i]; + } + } +- filled_ = filled + 1; ++ filled_ = f + 1; + sorted_filled_ = filled_; + sorted_ = true; + storage_invariants ();
diff --git a/boost.patches/boost-53.description b/boost.patches/boost-53.description new file mode 100644 index 0000000..a8c9afd --- /dev/null +++ b/boost.patches/boost-53.description
@@ -0,0 +1,3 @@ +Fix compiler warnings triggered by -Wunused-local-typedefs. Some of this was taken +from here https://svn.boost.org/trac/boost/ticket/8546 and some was fixed by looking +at the build log.
diff --git a/boost.patches/boost-53.patch b/boost.patches/boost-53.patch new file mode 100644 index 0000000..552e5a2 --- /dev/null +++ b/boost.patches/boost-53.patch
@@ -0,0 +1,158 @@ +diff -Naur a/boost/algorithm/string/detail/finder.hpp b/boost/algorithm/string/detail/finder.hpp +--- a/boost/algorithm/string/detail/finder.hpp 2009-09-13 12:10:55.000000000 -0700 ++++ b/boost/algorithm/string/detail/finder.hpp 2015-04-15 09:02:18.683944124 -0700 +@@ -142,7 +142,6 @@ + ForwardIteratorT End, + std::forward_iterator_tag ) const + { +- typedef ForwardIteratorT input_iterator_type; + typedef iterator_range<ForwardIteratorT> result_type; + + first_finder_type first_finder( +@@ -263,7 +262,6 @@ + ForwardIteratorT End, + unsigned int N) const + { +- typedef ForwardIteratorT input_iterator_type; + typedef iterator_range<ForwardIteratorT> result_type; + + // Sanity check +@@ -298,7 +296,6 @@ + ForwardIteratorT End, + unsigned int N) const + { +- typedef ForwardIteratorT input_iterator_type; + typedef iterator_range<ForwardIteratorT> result_type; + + // Sanity check +@@ -362,7 +359,6 @@ + unsigned int N, + std::random_access_iterator_tag ) + { +- typedef ForwardIteratorT input_iterator_type; + typedef iterator_range<ForwardIteratorT> result_type; + + if ( (End<=Begin) || ( static_cast<unsigned int>(End-Begin) < N ) ) +@@ -436,7 +432,6 @@ + unsigned int N, + std::random_access_iterator_tag ) + { +- typedef ForwardIteratorT input_iterator_type; + typedef iterator_range<ForwardIteratorT> result_type; + + if ( (End<=Begin) || ( static_cast<unsigned int>(End-Begin) < N ) ) +diff -Naur a/boost/bind/arg.hpp b/boost/bind/arg.hpp +--- a/boost/bind/arg.hpp 2007-11-25 10:07:19.000000000 -0800 ++++ b/boost/bind/arg.hpp 2015-04-15 09:02:18.683944124 -0700 +@@ -34,7 +34,6 @@ + template< class T > arg( T const & /* t */ ) + { + // static assert I == is_placeholder<T>::value +- typedef char T_must_be_placeholder[ I == is_placeholder<T>::value? 1: -1 ]; + } + }; + +diff -Naur a/boost/concept/detail/general.hpp b/boost/concept/detail/general.hpp +--- a/boost/concept/detail/general.hpp 2010-06-08 12:31:13.000000000 -0700 ++++ b/boost/concept/detail/general.hpp 2015-04-15 09:02:18.683944124 -0700 +@@ -12,6 +12,15 @@ + # include <boost/mpl/if.hpp> + # endif + ++ ++// If the compiler warns about unused typedefs then enable this: ++// ++#if defined(__GNUC__) && ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 7))) ++# define BOOST_CONCEPT_ASSERT_UNUSED_ATTRIBUTE __attribute__((unused)) ++#else ++# define BOOST_CONCEPT_ASSERT_UNUSED_ATTRIBUTE ++#endif ++ + // This implementation works on Comeau and GCC, all the way back to + // 2.95 + namespace boost { namespace concepts { +@@ -68,7 +77,7 @@ + # define BOOST_CONCEPT_ASSERT_FN( ModelFnPtr ) \ + typedef ::boost::concepts::detail::instantiate< \ + &::boost::concepts::requirement_<ModelFnPtr>::failed> \ +- BOOST_PP_CAT(boost_concept_check,__LINE__) ++ BOOST_PP_CAT(boost_concept_check,__LINE__) BOOST_CONCEPT_ASSERT_UNUSED_ATTRIBUTE + + }} + +diff -Naur a/boost/ptr_container/detail/move.hpp b/boost/ptr_container/detail/move.hpp +--- a/boost/ptr_container/detail/move.hpp 2008-03-22 14:45:55.000000000 -0700 ++++ b/boost/ptr_container/detail/move.hpp 2015-04-15 09:02:18.699944284 -0700 +@@ -20,7 +20,7 @@ + template<typename Ptr> + class move_source { + public: +- move_source(Ptr& ptr) : ptr_(ptr) {} ++ move_source(Ptr& ptrArg) : ptr_(ptrArg) {} + Ptr& ptr() const { return ptr_; } + private: + Ptr& ptr_; +diff -Naur a/boost/ptr_container/detail/reversible_ptr_container.hpp b/boost/ptr_container/detail/reversible_ptr_container.hpp +--- a/boost/ptr_container/detail/reversible_ptr_container.hpp 2009-04-05 12:55:59.000000000 -0700 ++++ b/boost/ptr_container/detail/reversible_ptr_container.hpp 2015-04-15 09:02:18.699944284 -0700 +@@ -278,9 +278,9 @@ + + private: + template< class ForwardIterator > +- ForwardIterator advance( ForwardIterator begin, size_type n ) ++ ForwardIterator advance( ForwardIterator beginArg, size_type n ) + { +- ForwardIterator iter = begin; ++ ForwardIterator iter = beginArg; + std::advance( iter, n ); + return iter; + } +diff -Naur a/boost/ptr_container/detail/static_move_ptr.hpp b/boost/ptr_container/detail/static_move_ptr.hpp +--- a/boost/ptr_container/detail/static_move_ptr.hpp 2008-03-22 14:45:55.000000000 -0700 ++++ b/boost/ptr_container/detail/static_move_ptr.hpp 2015-04-15 09:02:18.699944284 -0700 +@@ -151,7 +151,7 @@ + deleter_const_reference get_deleter() const { return impl_.second(); } + private: + template<typename TT, typename DD> +- void check(const static_move_ptr<TT, DD>& ptr) ++ void check(const static_move_ptr<TT, DD>& ptrArg) + { + typedef move_ptrs::is_smart_ptr_convertible<TT, T> convertible; + BOOST_STATIC_ASSERT(convertible::value); +diff -Naur a/boost/ptr_container/exception.hpp b/boost/ptr_container/exception.hpp +--- a/boost/ptr_container/exception.hpp 2008-03-22 14:45:55.000000000 -0700 ++++ b/boost/ptr_container/exception.hpp 2015-04-15 09:02:18.699944284 -0700 +@@ -24,7 +24,7 @@ + { + const char* what_; + public: +- bad_ptr_container_operation( const char* what ) : what_( what ) ++ bad_ptr_container_operation( const char* whatArg ) : what_( whatArg ) + { } + + virtual const char* what() const throw() +@@ -38,7 +38,7 @@ + class bad_index : public bad_ptr_container_operation + { + public: +- bad_index( const char* what ) : bad_ptr_container_operation( what ) ++ bad_index( const char* whatArg ) : bad_ptr_container_operation( whatArg ) + { } + }; + +diff -Naur a/boost/system/error_code.hpp b/boost/system/error_code.hpp +--- a/boost/system/error_code.hpp 2010-07-06 03:47:30.000000000 -0700 ++++ b/boost/system/error_code.hpp 2015-04-15 09:02:18.695944245 -0700 +@@ -211,9 +211,9 @@ + inline const error_category & get_system_category() { return system_category(); } + inline const error_category & get_generic_category() { return generic_category(); } + inline const error_category & get_posix_category() { return generic_category(); } +- static const error_category & posix_category = generic_category(); +- static const error_category & errno_ecat = generic_category(); +- static const error_category & native_ecat = system_category(); ++ //static const error_category & posix_category = generic_category(); ++ //static const error_category & errno_ecat = generic_category(); ++ //static const error_category & native_ecat = system_category(); + # endif + + // class error_condition -----------------------------------------------//
diff --git a/boost.patches/boost-54.description b/boost.patches/boost-54.description new file mode 100644 index 0000000..679dc8c --- /dev/null +++ b/boost.patches/boost-54.description
@@ -0,0 +1 @@ +Fix compiler shadowed declaration warnings in uuid_io
diff --git a/boost.patches/boost-54.patch b/boost.patches/boost-54.patch new file mode 100644 index 0000000..12718e7 --- /dev/null +++ b/boost.patches/boost-54.patch
@@ -0,0 +1,12 @@ +diff -aruN boost_1_45_0/boost/uuid/uuid_io.hpp boost_1_45_0.N/boost/uuid/uuid_io.hpp +--- boost_1_45_0/boost/uuid/uuid_io.hpp 2010-07-12 17:37:17.000000000 -0700 ++++ boost_1_45_0.N/boost/uuid/uuid_io.hpp 2015-04-28 17:59:01.600615207 -0700 +@@ -59,7 +59,7 @@ + } + + if (flags & std::ios_base::left) { +- for (std::streamsize i=uuid_width; i<width; i++) { ++ for (std::streamsize j=uuid_width; j<width; j++) { + os << fill; + } + }
diff --git a/boost.patches/boost-55.description b/boost.patches/boost-55.description new file mode 100644 index 0000000..3405cc2 --- /dev/null +++ b/boost.patches/boost-55.description
@@ -0,0 +1 @@ +Allow boost dynamic libraries to expect to be installed in a specific directory
diff --git a/boost.patches/boost-55.patch b/boost.patches/boost-55.patch new file mode 100644 index 0000000..cf15560 --- /dev/null +++ b/boost.patches/boost-55.patch
@@ -0,0 +1,21 @@ +diff -Naur a/tools/build/v2/tools/darwin.jam b/tools/build/v2/tools/darwin.jam +--- a/tools/build/v2/tools/darwin.jam 2010-07-12 00:37:43.000000000 -0700 ++++ b/tools/build/v2/tools/darwin.jam 2015-12-04 10:04:07.000000000 -0800 +@@ -33,6 +33,8 @@ + ## A dependency, that is forced to be included in the link. + feature force-load : : free dependency incidental ; + ++flags darwin.link INSTALL_NAME_PATH <dll-path> ; ++ + ############################################################################# + + if [ MATCH (--debug-configuration) : [ modules.peek : ARGV ] ] +@@ -540,7 +542,7 @@ + + actions link.dll bind LIBRARIES + { +- "$(CONFIG_COMMAND)" -dynamiclib -Wl,-single_module -install_name "$(<:B)$(<:S)" -L"$(LINKPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-SA) -l$(FINDLIBS-ST) $(FRAMEWORK_PATH) -framework$(_)$(FRAMEWORK:D=:S=) $(OPTIONS) $(USER_OPTIONS) ++ "$(CONFIG_COMMAND)" -dynamiclib -Wl,-single_module -install_name "$(INSTALL_NAME_PATH[1])/$(<[1]:B)$(<[1]:S)" -L"$(LINKPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-SA) -l$(FINDLIBS-ST) $(FRAMEWORK_PATH) -framework$(_)$(FRAMEWORK:D=:S=) $(OPTIONS) $(USER_OPTIONS) + } + + # We use libtool instead of ar to support universal binary linking
diff --git a/boost.patches/boost-56.description b/boost.patches/boost-56.description new file mode 100644 index 0000000..ef61834 --- /dev/null +++ b/boost.patches/boost-56.description
@@ -0,0 +1,5 @@ +Suppress -Wstrict-aliasing for boost::shared_ptr<T> with optimization turned on. + +Upstream: +https://svn.boost.org/trac10/ticket/4127 +https://svn.boost.org/trac10/changeset/69251
diff --git a/boost.patches/boost-56.patch b/boost.patches/boost-56.patch new file mode 100644 index 0000000..b6b7951 --- /dev/null +++ b/boost.patches/boost-56.patch
@@ -0,0 +1,20 @@ +diff -Nurp boost_1_45_0.orig/boost/smart_ptr/make_shared.hpp boost_1_45_0/boost/smart_ptr/make_shared.hpp +--- boost_1_45_0.orig/boost/smart_ptr/make_shared.hpp 2017-06-28 10:41:30.850524266 -0700 ++++ boost_1_45_0/boost/smart_ptr/make_shared.hpp 2017-06-28 10:45:11.733596706 -0700 +@@ -49,7 +49,16 @@ private: + { + if( initialized_ ) + { ++#if defined( __GNUC__ ) ++ ++ T * p = reinterpret_cast< T* >( storage_.data_ ); ++ p->~T(); ++ ++#else ++ + reinterpret_cast< T* >( storage_.data_ )->~T(); ++ ++#endif + initialized_ = false; + } + }
diff --git a/boost.tar.bz2 b/boost.tar.bz2 new file mode 100644 index 0000000..e824653 --- /dev/null +++ b/boost.tar.bz2 Binary files differ
diff --git a/boost.url b/boost.url new file mode 100644 index 0000000..75502b2 --- /dev/null +++ b/boost.url
@@ -0,0 +1 @@ +http://download.sourceforge.net/boost/boost_1_45_0.tar.bz2
diff --git a/boost.version b/boost.version new file mode 100644 index 0000000..37918b8 --- /dev/null +++ b/boost.version
@@ -0,0 +1 @@ +1_45_0