From 68f224ff08642781917b0af0b80c195053c4145b Mon Sep 17 00:00:00 2001 From: rdb Date: Sat, 17 Oct 2009 14:33:01 +0000 Subject: [PATCH] Experimental; copy the whole 'direct' tree to 'built' to avoid the hacky __init__.py (which we can't use anymore because of the way the runtime is packaged) --- makepanda/makepanda.py | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/makepanda/makepanda.py b/makepanda/makepanda.py index ce6fd0a9be..2983d0488a 100755 --- a/makepanda/makepanda.py +++ b/makepanda/makepanda.py @@ -1389,21 +1389,13 @@ CreatePandaVersionFiles() ########################################################################################## # -# Generate direct/__init__.py +# Copy the "direct" tree # ########################################################################################## -DIRECTINIT=""" -import os,sys -srcdir1 = os.path.join(__path__[0], 'src') -srcdir2 = os.path.join(__path__[0], '..', '..', 'direct', 'src') -if (os.path.isdir(srcdir1)): __path__[0] = srcdir1 -elif (os.path.isdir(srcdir2)): __path__[0] = srcdir2 -else: sys.exit("Cannot find the 'direct' tree") -""" - if (PkgSkip("PYTHON")==0): - ConditionalWriteFile(GetOutputDir()+'/direct/__init__.py', DIRECTINIT) + CopyTree(GetOutputDir()+'/direct','direct/src') + ConditionalWriteFile(GetOutputDir()+'/direct/__init__.py', "") ########################################################################################## #