changeset 5610:18d089fc6934

cross_compiling hack: robustification.
author Jan Nieuwenhuizen <janneke@gnu.org>
date Wed, 23 Sep 2009 19:35:24 +0200
parents 70b6d068b98d
children 64662bdcca0c
files gub/target.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/gub/target.py	Wed Sep 23 19:58:26 2009 +0200
+++ b/gub/target.py	Wed Sep 23 19:35:24 2009 +0200
@@ -18,8 +18,9 @@
         return '%(tools_prefix)s/lib/librestrict.so'
     def autoupdate (self):
         build.AutoBuild.autoupdate (self)
-        self.file_sub ([('cross_compiling=(maybe|no|yes)',
-                         'cross_compiling=yes')], '%(configure_binary)s')
+        if self.expand ('%(configure_binary)s').startswith ('/'):
+            self.file_sub ([('cross_compiling=(maybe|no|yes)',
+                             'cross_compiling=yes')], file)
     @context.subst_method
     def config_cache_flag (self):
         if True or self.config_cache_flag_broken: