[pkg-boost-commits] r14332 - in boost/trunk/debian: . patches

smr at alioth.debian.org smr at alioth.debian.org
Tue Nov 18 09:38:35 UTC 2008


Author: smr
Date: 2008-11-18 09:38:34 +0000 (Tue, 18 Nov 2008)
New Revision: 14332

Added:
   boost/trunk/debian/mergeinfo
   boost/trunk/debian/patches/add-disable-long-double.patch
   boost/trunk/debian/patches/atomic_count.patch
   boost/trunk/debian/patches/atomic_count_gcc.patch
   boost/trunk/debian/patches/jam-hardening.patch
   boost/trunk/debian/patches/math_tools_config.patch
   boost/trunk/debian/patches/no-long-double-math.patch
Modified:
   boost/trunk/debian/changelog
   boost/trunk/debian/patches/series
   boost/trunk/debian/rules
Log:
Merge changesets r14314 through r14330 from branches/1.36.0 (versions
1.36.0-4 through -8) to trunk.  This captures the changes to fix build
failures on arm, armel, hppa, mips, and sparc.

Differences from branches/1.36.0:
- patches/no-long-double-math.patch dropped; incorporated upstream
- other patches tweaked for upstream changes



Modified: boost/trunk/debian/changelog
===================================================================
--- boost/trunk/debian/changelog	2008-11-16 20:14:44 UTC (rev 14331)
+++ boost/trunk/debian/changelog	2008-11-18 09:38:34 UTC (rev 14332)
@@ -1,3 +1,31 @@
+boost1.37 (1.37.0-2) UNRELEASED; urgency=low
+
+  * patches/atomic_count_gcc.patch: New.  GCC version >= 4.2 has moved
+    <bits/atomic.h> to <ext/atomic.h>.
+  
+  * patches/jam-hardening.patch: New.  Fix warnings generated by hardening
+    options, -D_FORTIFY_SOURCE=2 and -Wformat-security.  Thanks to Kees
+    Cook for the patch.  Closes: #505734.
+
+  * patches/atomic_count.patch: New.  Exclude armel, m68k, and sparc from
+    atomic_count_sync case since they do not have __sync functions
+    (http://gcc.gnu.org/onlinedocs/gcc-4.1.0/gcc/Atomic-Builtins.html).
+  
+  * patches/math_tools_config.patch: New.  Define
+    BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS for arm, armel, mips, and
+    mipsel, as they all seem to have no log1pl() function.
+  
+  * patches/add-disable-long-double.patch: New.  Add option
+    --disable-long-double which, if specified on the bjam command line,
+    omits the TR1 and C99 long double libraries.  If not specified but
+    BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS is defined, we end up with a
+    build failure.
+  * rules: Add --disable-long-double for architectures arm, armel, hppa,
+    mips, and mipsel.  Exclude math_c99l and math_tr1l from debhelper
+    .install files for these arches.
+  
+ -- Steve M. Robbins <smr at debian.org>  Tue, 18 Nov 2008 03:30:15 -0600
+
 boost1.37 (1.37.0-1) unstable; urgency=low
 
   * New upstream.  Closes: #504475.

Added: boost/trunk/debian/mergeinfo
===================================================================
--- boost/trunk/debian/mergeinfo	                        (rev 0)
+++ boost/trunk/debian/mergeinfo	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,46 @@
+	1.36.0-3
+	--------
+
+Changeset on branches/1.36.0:
+
+------------------------------------------------------------------------
+r14308 | smr | 2008-11-09 15:26:09 -0600 (Sun, 09 Nov 2008) | 1 line
+Changed paths:
+   M /boost/branches/1.36.0/debian/changelog
+   M /boost/branches/1.36.0/debian/compat
+   M /boost/branches/1.36.0/debian/control
+   M /boost/branches/1.36.0/debian/rules
+
+Ensure debug symbols present in -dbg package.  Fix for 495812.
+------------------------------------------------------------------------
+
+Already merged by hand into 1.37.0-1:
+
+------------------------------------------------------------------------
+r14309 | smr | 2008-11-09 15:51:00 -0600 (Sun, 09 Nov 2008) | 1 line
+Changed paths:
+   M /boost/trunk/debian/changelog
+   M /boost/trunk/debian/compat
+   M /boost/trunk/debian/control
+   M /boost/trunk/debian/rules
+
+Merge CL 14308 from branches/1.36.0: Fix symbol generation for -dbg.
+------------------------------------------------------------------------
+
+
+
+	1.36.0-4 through -8
+	-------------------
+
+Changes to fix build failures on ARM, MIPS, SPARC, HPPA.
+Changesets on /1.36.0: r14314 through r14330.
+
+Merge command:
+
+  (execute in trunk directory)
+  svn -r 14314:14330 merge svn+ssh://smr@svn.debian.org/svn/pkg-boost/boost/branches/1.36.0
+
+Then tweaked patch set:
+ - delete no-long-double-math.patch
+ - updated some others by hand
+

Copied: boost/trunk/debian/patches/add-disable-long-double.patch (from rev 14330, boost/branches/1.36.0/debian/patches/add-disable-long-double.patch)
===================================================================
--- boost/trunk/debian/patches/add-disable-long-double.patch	                        (rev 0)
+++ boost/trunk/debian/patches/add-disable-long-double.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,67 @@
+Add option --disable-long-double to Boost build procedure.
+Specifying this option essentially allows us to ignore
+a build failure.
+
+c.f. http://lists.boost.org/boost-build/2008/11/20683.php
+
+
+--- boost1.36-1.36.0.orig/libs/math/build/Jamfile.v2
++++ boost1.36-1.36.0/libs/math/build/Jamfile.v2
+@@ -51,7 +51,18 @@
+ sph_neumann
+ ;
+ 
+-compile has_long_double_support.cpp ;
++if --disable-long-double in [ modules.peek : ARGV ]
++{
++    build-long-double = false ;
++}
++else
++{
++    build-long-double = true ;
++    compile has_long_double_support.cpp ;
++}
++
++ECHO "Build long double: " $(build-long-double) ;
++
+ 
+ lib boost_math_tr1 : ../src/tr1/$(TR1_SOURCES).cpp
+     :         
+@@ -63,11 +74,15 @@
+  	     <link>shared:<define>BOOST_MATH_TR1_DYN_LINK=1
+    ;
+ 
++if $(build-long-double) = true
++{
++echo "BUILDING MATH_TR1 LONG" ;
+ lib boost_math_tr1l : ../src/tr1/$(TR1_SOURCES)l.cpp
+     :         
+  	     <link>shared:<define>BOOST_MATH_TR1_DYN_LINK=1
+  	     <dependency>has_long_double_support
+    ;
++}
+ 
+ lib boost_math_c99 : ../src/tr1/$(C99_SOURCES).cpp
+     :         
+@@ -79,12 +94,20 @@
+  	     <link>shared:<define>BOOST_MATH_TR1_DYN_LINK=1
+    ;
+ 
++if $(build-long-double) = true
++{
++echo "BUILDING MATH_C99 LONG" ;
+ lib boost_math_c99l : ../src/tr1/$(C99_SOURCES)l.cpp
+     :         
+  	     <link>shared:<define>BOOST_MATH_TR1_DYN_LINK=1
+  	     <dependency>has_long_double_support
+    ;
++}
+ 
+ 
+-boost-install boost_math_c99 boost_math_c99f boost_math_c99l boost_math_tr1 boost_math_tr1f boost_math_tr1l ;
++boost-install boost_math_c99 boost_math_c99f boost_math_tr1 boost_math_tr1f ;
+ 
++if $(build-long-double) = true
++{
++boost-install boost_math_c99l boost_math_tr1l ;
++}

Copied: boost/trunk/debian/patches/atomic_count.patch (from rev 14330, boost/branches/1.36.0/debian/patches/atomic_count.patch)
===================================================================
--- boost/trunk/debian/patches/atomic_count.patch	                        (rev 0)
+++ boost/trunk/debian/patches/atomic_count.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,11 @@
+--- boost1.37-1.37.0.orig/boost/detail/atomic_count.hpp
++++ boost1.37-1.37.0/boost/detail/atomic_count.hpp
+@@ -98,7 +98,7 @@
+ #elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
+ #  include <boost/detail/atomic_count_win32.hpp>
+ 
+-#elif defined( __GNUC__ ) && ( __GNUC__ * 100 + __GNUC_MINOR__ >= 401 ) && !defined( __arm__ ) && !defined( __hppa ) && ( !defined( __INTEL_COMPILER ) || defined( __ia64__ ) )
++#elif defined( __GNUC__ ) && ( __GNUC__ * 100 + __GNUC_MINOR__ >= 401 ) && !defined( __arm__ ) && !defined( __armel__ ) && !defined( __hppa ) && !defined( __hppa__ ) && !defined( __m68k__ ) && !defined( __sparc__ ) && ( !defined( __INTEL_COMPILER ) || defined( __ia64__ ) )
+ #  include <boost/detail/atomic_count_sync.hpp>
+ 
+ #elif defined(__GLIBCPP__) || defined(__GLIBCXX__)

Copied: boost/trunk/debian/patches/atomic_count_gcc.patch (from rev 14330, boost/branches/1.36.0/debian/patches/atomic_count_gcc.patch)
===================================================================
--- boost/trunk/debian/patches/atomic_count_gcc.patch	                        (rev 0)
+++ boost/trunk/debian/patches/atomic_count_gcc.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,15 @@
+--- boost1.36-1.36.0.orig/boost/detail/atomic_count_gcc.hpp
++++ boost1.36-1.36.0/boost/detail/atomic_count_gcc.hpp
+@@ -17,7 +17,11 @@
+ //  http://www.boost.org/LICENSE_1_0.txt)
+ //
+ 
+-#include <bits/atomicity.h>
++#if defined( __GNUC__ ) && ( __GNUC__ * 100 + __GNUC_MINOR__ >= 402 )
++#  include <ext/atomicity.h>
++#else
++#  include <bits/atomicity.h>
++#endif
+ 
+ namespace boost
+ {

Copied: boost/trunk/debian/patches/jam-hardening.patch (from rev 14330, boost/branches/1.36.0/debian/patches/jam-hardening.patch)
===================================================================
--- boost/trunk/debian/patches/jam-hardening.patch	                        (rev 0)
+++ boost/trunk/debian/patches/jam-hardening.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,79 @@
+From Kees Cook, Debian BTS #505734
+
+--- boost1.37-1.37.0.orig/tools/jam/src/compile.c
++++ boost1.37-1.37.0/tools/jam/src/compile.c
+@@ -1404,7 +1404,7 @@
+       i = (level+1)*2;
+       while ( i > 35 )
+       {
+-        printf( indent );
++        printf( "%s", indent );
+         i -= 35;
+       }
+ 
+--- boost1.37-1.37.0.orig/tools/jam/src/make1.c
++++ boost1.37-1.37.0/tools/jam/src/make1.c
+@@ -1018,7 +1018,7 @@
+ 			list_sublist( ns, start, chunk ),
+ 			list_new( L0, newstr( "%" ) ) );
+ 
+-                    printf( cmd->buf );
++                    printf( "%s", cmd->buf );
+                 
+ 		    exit( EXITBAD );
+ 		}
+--- boost1.37-1.37.0.orig/tools/jam/src/output.c
++++ boost1.37-1.37.0/tools/jam/src/output.c
+@@ -20,7 +20,7 @@
+     while ( *data )
+     {
+         size_t len = strcspn(data,"\r");
+-        fwrite(data,len,1,io);
++        do { if (fwrite(data,len,1,io)) {} } while (0);
+         data += len;
+         if ( *data == '\r' ) ++data;
+     }
+--- boost1.37-1.37.0.orig/tools/jam/src/variable.c
++++ boost1.37-1.37.0/tools/jam/src/variable.c
+@@ -416,8 +416,18 @@
+         }
+         if ( output_0 < output_1 )
+         {
+-            if ( out_file ) fwrite(output_0,output_1-output_0,1,out_file);
+-            if ( out_debug ) fwrite(output_0,output_1-output_0,1,stdout);
++            if ( out_file ) {
++                if ( fwrite(output_0,output_1-output_0,1,out_file) < 1 ) {
++                    printf( "failed to write output file!\n" );
++                    exit( EXITBAD );
++                }
++            }
++            if ( out_debug ) {
++                if ( fwrite(output_0,output_1-output_0,1,stdout) < 1 ) {
++                    printf( "failed to write output to stdout!\n" );
++                    exit( EXITBAD );
++                }
++            }
+         }
+         output_0 = output_1;
+ 
+@@ -457,8 +467,18 @@
+         }
+         else if ( output_0 < output_1 )
+         {
+-            if ( out_file ) fwrite(output_0,output_1-output_0,1,out_file);
+-            if ( out_debug ) fwrite(output_0,output_1-output_0,1,stdout);
++            if ( out_file ) {
++                if ( fwrite(output_0,output_1-output_0,1,out_file) < 1 ) {
++                    printf( "failed to write output file!\n" );
++                    exit( EXITBAD );
++                }
++            }
++            if ( out_debug ) {
++                if ( fwrite(output_0,output_1-output_0,1,stdout) < 1 ) {
++                    printf( "failed to write output to stdout!\n" );
++                    exit( EXITBAD );
++                }
++            }
+         }
+         
+         in = output_1;

Copied: boost/trunk/debian/patches/math_tools_config.patch (from rev 14330, boost/branches/1.36.0/debian/patches/math_tools_config.patch)
===================================================================
--- boost/trunk/debian/patches/math_tools_config.patch	                        (rev 0)
+++ boost/trunk/debian/patches/math_tools_config.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,10 @@
+--- boost1.37-1.37.0.orig/boost/math/tools/config.hpp
++++ boost1.37-1.37.0/boost/math/tools/config.hpp
+@@ -24,6 +24,7 @@
+ #include <boost/math/special_functions/detail/round_fwd.hpp>
+ 
+ #if defined(__CYGWIN__) || defined(__FreeBSD__) || defined(__NetBSD__) \
++   || defined(__arm__) || defined(__armel__) || defined(__hppa__) || defined(__mips__) || defined(__mipsel__) \
+    || defined(__hppa) || defined(__NO_LONG_DOUBLE_MATH)
+ #  define BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
+ #endif

Copied: boost/trunk/debian/patches/no-long-double-math.patch (from rev 14330, boost/branches/1.36.0/debian/patches/no-long-double-math.patch)
===================================================================
--- boost/trunk/debian/patches/no-long-double-math.patch	                        (rev 0)
+++ boost/trunk/debian/patches/no-long-double-math.patch	2008-11-18 09:38:34 UTC (rev 14332)
@@ -0,0 +1,10 @@
+--- boost1.37-1.37.0.orig/boost/math/special_functions/log1p.hpp
++++ boost1.37-1.37.0/boost/math/special_functions/log1p.hpp
+@@ -388,6 +388,7 @@
+    else
+       return log(u)*(x/(u-1.0));
+ }
++#ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS
+ template <class Policy>
+ inline float log1p(float x, const Policy& pol)
+ {

Modified: boost/trunk/debian/patches/series
===================================================================
--- boost/trunk/debian/patches/series	2008-11-16 20:14:44 UTC (rev 14331)
+++ boost/trunk/debian/patches/series	2008-11-18 09:38:34 UTC (rev 14332)
@@ -1,3 +1,8 @@
+atomic_count.patch
+math_tools_config.patch
+add-disable-long-double.patch
+atomic_count_gcc.patch
+jam-hardening.patch
 endian.patch
 avoid-PATH_MAX.patch
 jam-wall-clean.patch

Modified: boost/trunk/debian/rules
===================================================================
--- boost/trunk/debian/rules	2008-11-16 20:14:44 UTC (rev 14331)
+++ boost/trunk/debian/rules	2008-11-18 09:38:34 UTC (rev 14332)
@@ -27,7 +27,8 @@
 	thread wave
 
 # these are special cases, where shared library has not the same name of the Boost library
-boost_lib_math := math_c99 math_c99f math_c99l math_tr1 math_tr1f math_tr1l
+boost_lib_math := math_c99 math_c99f math_tr1 math_tr1f
+boost_lib_math_long_double := math_c99l math_tr1l
 boost_lib_serialization := serialization wserialization
 boost_lib_test := prg_exec_monitor unit_test_framework
 
@@ -127,17 +128,32 @@
 		) \
 	)
 
+BUILD_LONG_DOUBLE = yes
+
 TOOLSET_CONFIG="using gcc : : : <compileflags>-D_REENTRANT ;"
 ifeq ($(DEB_BUILD_ARCH), hppa)
 TOOLSET_CONFIG="using gcc : : : <compileflags>-D_REENTRANT <compileflags>-mlong-calls <compileflags>-DBOOST_SP_USE_PTHREADS ;"
+BUILD_LONG_DOUBLE = no
 else ifeq ($(DEB_BUILD_ARCH), sparc)
 TOOLSET_CONFIG="using gcc : : : <compileflags>-D_REENTRANT <compileflags>-DBOOST_SP_USE_PTHREADS ;"
 else ifeq ($(DEB_BUILD_ARCH), arm)
 TOOLSET_CONFIG="using gcc : : : <compileflags>-D_REENTRANT <compileflags>-DBOOST_SP_USE_PTHREADS ;"
+BUILD_LONG_DOUBLE = no
 else ifeq ($(DEB_BUILD_ARCH), armel)
 TOOLSET_CONFIG="using gcc : : : <compileflags>-D_REENTRANT <compileflags>-DBOOST_SP_USE_PTHREADS ;"
+BUILD_LONG_DOUBLE = no
+else ifeq ($(DEB_BUILD_ARCH), mips)
+BUILD_LONG_DOUBLE = no
+else ifeq ($(DEB_BUILD_ARCH), mipsel)
+BUILD_LONG_DOUBLE = no
 endif
 
+ifeq ($(BUILD_LONG_DOUBLE), yes)
+boost_lib_math += $(boost_lib_math_long_double)
+else
+JAM_OPT += --disable-long-double
+endif
+
 PYTHON_CONFIG1 = "using python : 2.4 : /usr ;"
 PYTHON_CONFIG2 = "using python : 2.5 : /usr ;"
 
@@ -147,7 +163,7 @@
 bjam = $(CURDIR)/tools/jam/src/bjam
 
 # FIXME: find a flag to disable reading /etc/site-config.jam
-JAM = $(bjam) $(JOBS) -d2 --user-config=$(CURDIR)/user-config.jam -sHAVE_ICU=1 debug-symbols=on
+JAM = $(bjam) $(JOBS) -d2 $(JAM_OPT) --user-config=$(CURDIR)/user-config.jam -sHAVE_ICU=1 debug-symbols=on
 jam_variants = variant=release,debug threading=multi link=shared,static
 
 $(bjam):




More information about the pkg-boost-commits mailing list