ignore __pycache__ dir for scons and cmake installation (py3.2 caches modules here).
authorCampbell Barton <ideasman42@gmail.com>
Wed, 9 Feb 2011 00:45:16 +0000 (00:45 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Wed, 9 Feb 2011 00:45:16 +0000 (00:45 +0000)
SConstruct
source/creator/CMakeLists.txt

index 03e61cd06b66297f0761f5f7e1dc3f2715c5abec..fe60d41c48d39caa37557913ed8b93533b644e90 100644 (file)
@@ -489,11 +489,13 @@ if  env['OURPLATFORM']!='darwin':
                         dn.remove('.svn')
                     if '_svn' in dn:
                         dn.remove('_svn')
-                    
+                    if '__pycache__' in dn:  # py3.2 cache dir
+                        dn.remove('__pycache__')
+
                     dir = os.path.join(env['BF_INSTALLDIR'], VERSION)
                     dir += os.sep + os.path.basename(scriptpath) + dp[len(scriptpath):]
-                    
-                    source=[os.path.join(dp, f) for f in df if f[-3:]!='pyc']
+
+                    source=[os.path.join(dp, f) for f in df if not f.endswith(".pyc")]
                     # To ensure empty dirs are created too
                     if len(source)==0:
                         env.Execute(Mkdir(dir))
index 2c89c3b6b9fe7509b5c843abf3dc789be473e1cb..64f117c2bcd338817fa899edc24d05fcc89599c0 100644 (file)
@@ -241,6 +241,7 @@ if(WITH_INSTALL)
                        DESTINATION ${CMAKE_INSTALL_PREFIX}/share/blender/${BLENDER_VERSION}/scripts
                        PATTERN ".svn" EXCLUDE
                        PATTERN "*.pyc" EXCLUDE
+                       PATTERN "__pycache__" EXCLUDE
                )
                install(
                        DIRECTORY ${CMAKE_SOURCE_DIR}/release/datafiles/brushicons/