File tree Expand file tree Collapse file tree 4 files changed +17
-2
lines changed Expand file tree Collapse file tree 4 files changed +17
-2
lines changed Original file line number Diff line number Diff line change 4444
4545/config.mk
4646/config.gypi
47+ /config_fips.gypi
4748* -nodegyp *
4849/gyp-mac-tool
4950/dist-osx
Original file line number Diff line number Diff line change 7474
7575distclean :
7676 -rm -rf out
77- -rm -f config.gypi icu_config.gypi
77+ -rm -f config.gypi icu_config.gypi config_fips.gypi
7878 -rm -f config.mk
7979 -rm -rf $(NODE_EXE ) $(NODE_G_EXE )
8080 -rm -rf node_modules
Original file line number Diff line number Diff line change @@ -787,7 +787,7 @@ def configure_openssl(o):
787787 o ['variables' ]['openssl_fips' ] = options .openssl_fips
788788 fips_dir = os .path .join (root_dir , 'deps' , 'openssl' , 'fips' )
789789 fips_ld = os .path .abspath (os .path .join (fips_dir , 'fipsld' ))
790- o ['make_global_settings ' ] = [
790+ o ['make_fips_settings ' ] = [
791791 ['LINK' , fips_ld + ' <(openssl_fips)/bin/fipsld' ],
792792 ]
793793 else :
@@ -1109,6 +1109,15 @@ configure_fullystatic(output)
11091109variables = output ['variables' ]
11101110del output ['variables' ]
11111111
1112+ # make_global_settings for special FIPS linking
1113+ # should not be used to compile modules in node-gyp
1114+ config_fips = { 'make_global_settings' : [] }
1115+ if 'make_fips_settings' in output :
1116+ config_fips ['make_global_settings' ] = output ['make_fips_settings' ]
1117+ del output ['make_fips_settings' ]
1118+ write ('config_fips.gypi' , do_not_edit +
1119+ pprint .pformat (config_fips , indent = 2 ) + '\n ' )
1120+
11121121# make_global_settings should be a root level element too
11131122if 'make_global_settings' in output :
11141123 make_global_settings = output ['make_global_settings' ]
Original file line number Diff line number Diff line change @@ -30,17 +30,22 @@ def run_gyp(args):
3030 args .append (os .path .join (node_root , 'node.gyp' ))
3131 common_fn = os .path .join (node_root , 'common.gypi' )
3232 options_fn = os .path .join (node_root , 'config.gypi' )
33+ options_fips_fn = os .path .join (node_root , 'config_fips.gypi' )
3334 else :
3435 args .append (os .path .join (os .path .abspath (node_root ), 'node.gyp' ))
3536 common_fn = os .path .join (os .path .abspath (node_root ), 'common.gypi' )
3637 options_fn = os .path .join (os .path .abspath (node_root ), 'config.gypi' )
38+ options_fips_fn = os .path .join (os .path .abspath (node_root ), 'config_fips.gypi' )
3739
3840 if os .path .exists (common_fn ):
3941 args .extend (['-I' , common_fn ])
4042
4143 if os .path .exists (options_fn ):
4244 args .extend (['-I' , options_fn ])
4345
46+ if os .path .exists (options_fips_fn ):
47+ args .extend (['-I' , options_fips_fn ])
48+
4449 args .append ('--depth=' + node_root )
4550
4651 # There's a bug with windows which doesn't allow this feature.
You can’t perform that action at this time.
0 commit comments