@@ -165,17 +165,26 @@ def get_config_option(self, config_header):
165
165
166
166
def get_compile_options (self , defines , includes , for_asm = False ):
167
167
opts = ['-D%s' % d for d in defines ]
168
- config_header = self .get_config_header ()
169
- if config_header is not None :
170
- opts = opts + self .get_config_option (config_header )
171
- if for_asm :
168
+ if for_asm :
169
+ config_macros = self .config .get_config_data_macros ()
170
+ macros_cmd = ['"-D%s"' % d .replace ('"' , '' ) for d in config_macros ]
171
+ if self .RESPONSE_FILES :
172
+ via_file = self .make_option_file (
173
+ macros_cmd , "asm_macros_{}.xcl" )
174
+ opts += ['-f' , via_file ]
175
+ else :
176
+ opts += macros_cmd
172
177
return opts
173
- if self .RESPONSE_FILES :
174
- opts += ['-f' , self .get_inc_file (includes )]
175
178
else :
176
- opts += ["-I%s" % i for i in includes ]
179
+ if self .RESPONSE_FILES :
180
+ opts += ['-f' , self .get_inc_file (includes )]
181
+ else :
182
+ opts += ["-I%s" % i for i in includes ]
183
+ config_header = self .get_config_header ()
184
+ if config_header is not None :
185
+ opts = opts + self .get_config_option (config_header )
177
186
178
- return opts
187
+ return opts
179
188
180
189
@hook_tool
181
190
def assemble (self , source , object , includes ):
0 commit comments