Skip to content

Commit a394fd2

Browse files
committed
Fix to only add libdirs if they are in the easyconfig
1 parent 75ffb0c commit a394fd2

1 file changed

Lines changed: 9 additions & 8 deletions

File tree

eb_hooks.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1071,15 +1071,16 @@ def pre_configure_hook_graphviz(self, *args, **kwargs):
10711071

10721072
# Replace --with-ltdl-lib and --with-zlibdir options defined in the EC to point to compat layer
10731073
lib_dir = os.path.join(usr_dir, 'lib64')
1074-
new_items = {
1075-
f'--with-ltdl-lib={lib_dir}',
1076-
f'--with-zlibdir={lib_dir}',
1077-
}
1078-
# Add to the new_items all the old items except the `--with-ltdl-lib` and `--with-ltdl-lib` for which we already defined new values above
1074+
new_items = set()
1075+
# Add to the new_items all the old items except the `--with-ltdl-lib` and `--with-ltdl-lib` for
1076+
# which we fix the lib dir to lib64 instead of lib
10791077
for item in old_items:
1080-
if item.startswith('--with-ltdl-lib') or item.startswith('--with-zlibdir'):
1081-
continue
1082-
new_items.add(item)
1078+
if item.startswith('--with-ltdl-lib'):
1079+
new_items.add(f'--with-ltdl-lib={lib_dir}')
1080+
elif item.startswith('--with-zlibdir'):
1081+
new_items.add(f'--with-zlibdir={lib_dir}')
1082+
else:
1083+
new_items.add(item)
10831084

10841085
self.cfg['configopts'] = ' '.join(new_items)
10851086
else:

0 commit comments

Comments
 (0)