From ce92b0f468af117e99e4d36d04e9fc2c92e912f2 Mon Sep 17 00:00:00 2001 From: Vladimir Prus Date: Thu, 27 Jul 2006 06:55:52 +0000 Subject: [PATCH] Fix logic for adding 'rt' on Sun. [SVN r34750] --- src/tools/python.jam | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/tools/python.jam b/src/tools/python.jam index b76947ba8..2c8486d78 100644 --- a/src/tools/python.jam +++ b/src/tools/python.jam @@ -52,6 +52,8 @@ lib dl ; lib util ; # Python uses pthread symbols. lib pthread ; +# Extra library needed by phtread on some platforms. +lib rt ; # Initializes the Python toolset. @@ -152,15 +154,17 @@ rule init-unix ( version ? : root ? : includes ? : libraries ? : condition * ) # affected by threading mode. extra-libs += pthread ; + extra-libs-conditional = ; # Add 'rt' option on Sun. While we duplicate the # logic already in sun.jam and gcc.jam, I see no easy # way to refactor it. - condition += sun:rt ; + # Note that for 'sun' toolset, rt is already unconditionally + # added. switch [ modules.peek : JAMUNAME ] { - case SunOS* : + case SunOS* : { - condition += gcc:rt ; + extra-libs-conditional += gcc:rt ; } } @@ -178,8 +182,8 @@ rule init-unix ( version ? : root ? : includes ? : libraries ? : condition * ) ; alias python - : $(extra-libs) - : $(condition) + : $(extra-libs) + : $(condition) $(extra-libs-conditional) : : $(includes) $(libraries)