@@ -227,6 +227,25 @@ def CalculateGeneratorInputInfo(params):
227227"""
228228
229229
230+ LINK_COMMANDS_OS390 = """\
231+ quiet_cmd_alink = AR($(TOOLSET)) $@
232+ cmd_alink = rm -f $@ && $(AR.$(TOOLSET)) crs $@ $(filter %.o,$^)
233+
234+ quiet_cmd_alink_thin = AR($(TOOLSET)) $@
235+ cmd_alink_thin = rm -f $@ && $(AR.$(TOOLSET)) crsT $@ $(filter %.o,$^)
236+
237+ quiet_cmd_link = LINK($(TOOLSET)) $@
238+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS)
239+
240+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
241+ cmd_solink = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS) -Wl,DLL
242+
243+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
244+ cmd_solink_module = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS) -Wl,DLL
245+
246+ """
247+
248+
230249# Header of toplevel Makefile.
231250# This should go into the build tree, but it's easier to keep it here for now.
232251SHARED_HEADER = ("""\
@@ -310,7 +329,7 @@ def CalculateGeneratorInputInfo(params):
310329# We write to a dep file on the side first and then rename at the end
311330# so we can't end up with a broken dep file.
312331depfile = $(depsdir)/$(call replace_spaces,$@).d
313- DEPFLAGS = -MMD -MF $(depfile).raw
332+ DEPFLAGS = %(makedep_args)s -MF $(depfile).raw
314333
315334# We have to fixup the deps output in a few ways.
316335# (1) the file output should mention the proper .o file.
@@ -2013,6 +2032,7 @@ def CalculateMakefilePath(build_file, base_name):
20132032
20142033 flock_command = 'flock'
20152034 copy_archive_arguments = '-af'
2035+ makedep_arguments = '-MMD'
20162036 header_params = {
20172037 'default_target' : default_target ,
20182038 'builddir' : builddir_name ,
@@ -2023,6 +2043,7 @@ def CalculateMakefilePath(build_file, base_name):
20232043 'extra_commands' : '' ,
20242044 'srcdir' : srcdir ,
20252045 'copy_archive_args' : copy_archive_arguments ,
2046+ 'makedep_args' : makedep_arguments ,
20262047 }
20272048 if flavor == 'mac' :
20282049 flock_command = './gyp-mac-tool flock'
@@ -2036,6 +2057,14 @@ def CalculateMakefilePath(build_file, base_name):
20362057 header_params .update ({
20372058 'link_commands' : LINK_COMMANDS_ANDROID ,
20382059 })
2060+ elif flavor == 'os390' :
2061+ copy_archive_arguments = '-fPR'
2062+ makedep_arguments = '-qmakedep=gcc'
2063+ header_params .update ({
2064+ 'copy_archive_args' : copy_archive_arguments ,
2065+ 'makedep_args' : makedep_arguments ,
2066+ 'link_commands' : LINK_COMMANDS_OS390 ,
2067+ })
20392068 elif flavor == 'solaris' :
20402069 header_params .update ({
20412070 'flock' : './gyp-flock-tool flock' ,
0 commit comments