Skip to content

Commit f521e03

Browse files
committed
build: add an action to revert openssl.cnf
This commit adds an action that is run when openssl-is-fips is not specified and overwrites openssl.cnf as this would otherwise cause and error if the fips configuration is left from an earlier configuration.
1 parent 5f03556 commit f521e03

File tree

1 file changed

+19
-5
lines changed

1 file changed

+19
-5
lines changed

node.gyp

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,6 @@
592592
],
593593
'outputs': [
594594
'<(fipsconfig)',
595-
'bajja.txt',
596595
],
597596
'action': [
598597
'<(openssl-cli)', 'fipsinstall',
@@ -628,18 +627,33 @@
628627
},
629628
{
630629
'action_name': 'include_fips_cnf',
631-
'inputs': [ '<(opensslconfig_internal)', ],
632-
#'outputs': [ '<(opensslconfig_internal)', ],
633-
'outputs': [ '', ],
630+
'inputs': [ '<(opensslconfig)', ],
631+
'outputs': [ '<(opensslconfig_internal)', ],
634632
'action': [
635633
'python', 'tools/enable_fips_include.py',
636634
'<(opensslconfig_internal)',
637635
'<(fipsconfig)',
638636
],
639637
},
640638
],
639+
}, {
640+
'variables': {
641+
'opensslconfig_internal': '<(obj_dir)/deps/openssl/openssl.cnf',
642+
'opensslconfig': './deps/openssl/openssl/apps/openssl.cnf',
643+
},
644+
'actions': [
645+
{
646+
'action_name': 'reset_openssl_cnf',
647+
'inputs': [ '<(opensslconfig)', ],
648+
'outputs': [ '<(opensslconfig_internal)', ],
649+
'action': [
650+
'python', 'tools/copyfile.py',
651+
'./deps/openssl/openssl/apps/openssl.cnf',
652+
'<(obj_dir)/deps/openssl/openssl.cnf',
653+
],
654+
},
655+
],
641656
}],
642-
643657
],
644658
}, # node_core_target_name
645659
{

0 commit comments

Comments
 (0)