]> git.saurik.com Git - wxWidgets.git/blobdiff - build/bakefiles/regenMakefile.py
fixed VC++ warning in release build
[wxWidgets.git] / build / bakefiles / regenMakefile.py
index 87e04884eb9e969376c1a59d1c1cb9d1455a87e1..5434dbbfedd8c7a3ea2abb760d24896af49b822f 100755 (executable)
@@ -50,6 +50,7 @@ def addMakefile(bake, makedirs, deps=[], args={}):
     dep = string.join(deps + [bake], ' ')
 
     add(bake, makedirs, 'Makefile.in', dep, 'autoconf', args)
+    add(bake, makedirs, 'makefile.bcc', dep, 'borland', args)
 
 
 
@@ -60,13 +61,16 @@ def addMakefile(bake, makedirs, deps=[], args={}):
 # main makefile:
 addMakefile('wx.bkl', {'all':'..','autoconf':'../..'},
             ['common.bkl', 'config.bkl', 'files.bkl', 'monolithic.bkl',
-             'wxwin.py'])
+             'multilib.bkl', 'wxwin.py'])
 
 # samples main makefile:
-addMakefile('../../samples/samples.bkl', {'all':'../../samples'})
+addMakefile('../../samples/samples.bkl', {'all':'../../samples'},
+            args={'autoconf':'-DAUTOCONF_MACROS_FILE=../../autoconf_inc.m4'})
 
 
-def onSubmakefile(acdir, dirname, names):
+CONTRIB_DIR = 1
+
+def onSubmakefile(type, dirname, names):
     bakes = [x for x in names if x.endswith('.bkl')]
     if len(bakes) == 0: return
     depth = dirname.count('/') - 2
@@ -74,18 +78,24 @@ def onSubmakefile(acdir, dirname, names):
     prefix = ''.join(['../' for i in range(0,depth)])
 
     args = {
-        'all':'-DWXTOPDIR=/%s..' % prefix,
+        'all':'-DWXTOPDIR=%s../' % prefix,
         'autoconf':'-DAUTOCONF_MACROS_FILE=../../autoconf_inc.m4',
     }
     
     for bake in bakes:
+        if type==CONTRIB_DIR:
+            acdir = '../../contrib/src/%s' % dirname.split('/')[-1]
+            ruledep = 'common_contrib.bkl'
+        else:
+            acdir = dirname
+            ruledep = 'common_samples.bkl'
         addMakefile('%s/%s' % (dirname, bake),
-                    {'all':dirname,'autoconf':dirname+acdir},
-                    deps=['common.bkl','common_samples.bkl','config.bkl'],
+                    {'all':dirname,'autoconf':acdir},
+                    deps=['common.bkl',ruledep,'config.bkl'],
                     args=args)
 
-os.path.walk('../../samples', onSubmakefile, '')
-os.path.walk('../../contrib/src', onSubmakefile, '/..')
+os.path.walk('../../samples', onSubmakefile, None)
+os.path.walk('../../contrib/build', onSubmakefile, CONTRIB_DIR)
 
 
 cleanCmds = ''