67
67
import easybuild .tools .environment as env
68
68
import easybuild .tools .toolchain as toolchain
69
69
from easybuild .base import fancylogger
70
- from easybuild .base .frozendict import FrozenDict
71
70
from easybuild .framework .easyconfig import EASYCONFIGS_PKG_SUBDIR
72
71
from easybuild .framework .easyconfig .easyconfig import ITERATE_OPTIONS , EasyConfig , ActiveMNS , get_easyblock_class
73
72
from easybuild .framework .easyconfig .easyconfig import get_module_path , letter_dir_for , resolve_template
@@ -189,7 +188,7 @@ def __init__(self, ec, logfile=None):
189
188
190
189
# list of patch/source files, along with checksums
191
190
self .patches = []
192
- self .all_patches = set () # set of all patches (including patches of extensions)
191
+ self .all_patches_paths = set () # set of paths to all patches (including patches of extensions)
193
192
self .src = []
194
193
self .data_src = []
195
194
self .checksums = []
@@ -603,7 +602,7 @@ def fetch_patches(self, patch_specs=None, extension=False, checksums=None):
603
602
patch_info ['path' ] = path
604
603
patch_info ['checksum' ] = self .get_checksum_for (checksums , filename = patch_info ['name' ], index = index )
605
604
606
- self .all_patches .add (FrozenDict ( patch_info ) )
605
+ self .all_patches_paths .add (path )
607
606
if extension :
608
607
patches .append (patch_info )
609
608
else :
@@ -5129,9 +5128,8 @@ def ensure_writable_log_dir(log_dir):
5129
5128
block = det_full_ec_version (app .cfg ) + ".block"
5130
5129
repo .add_easyconfig (ecdict ['original_spec' ], app .name , block , buildstats , currentbuildstats )
5131
5130
repo .add_easyconfig (spec , app .name , det_full_ec_version (app .cfg ), buildstats , currentbuildstats )
5132
- for patch in app .all_patches :
5133
- if 'path' in patch :
5134
- repo .add_patch (patch ['path' ], app .name )
5131
+ for patch_path in app .all_patches_paths :
5132
+ repo .add_patch (patch_path , app .name )
5135
5133
repo .commit ("Built %s" % app .full_mod_name )
5136
5134
del repo
5137
5135
except EasyBuildError as err :
@@ -5153,11 +5151,10 @@ def ensure_writable_log_dir(log_dir):
5153
5151
_log .debug ("Copied easyconfig file %s to %s" , spec , newspec )
5154
5152
5155
5153
# copy patches
5156
- for patch in app .all_patches :
5157
- if 'path' in patch :
5158
- target = os .path .join (new_log_dir , os .path .basename (patch ['path' ]))
5159
- copy_file (patch ['path' ], target )
5160
- _log .debug ("Copied patch %s to %s" , patch ['path' ], target )
5154
+ for patch_path in app .all_patches_paths :
5155
+ target = os .path .join (new_log_dir , os .path .basename (patch_path ))
5156
+ copy_file (patch_path , target )
5157
+ _log .debug ("Copied patch %s to %s" , patch_path , target )
5161
5158
5162
5159
if build_option ('read_only_installdir' ) and not app .cfg ['stop' ]:
5163
5160
# take away user write permissions (again)
0 commit comments