@@ -35,18 +35,6 @@ def initialize_options(self):
35
35
self .fcompiler = None
36
36
old_config .initialize_options (self )
37
37
38
- def try_run (self , body , headers = None , include_dirs = None ,
39
- libraries = None , library_dirs = None , lang = "c" ):
40
- # 2008-11-16, RemoveMe
41
- warnings .warn ("\n +++++++++++++++++++++++++++++++++++++++++++++++++\n " \
42
- "Usage of try_run is deprecated: please do not \n " \
43
- "use it anymore, and avoid configuration checks \n " \
44
- "involving running executable on the target machine.\n " \
45
- "+++++++++++++++++++++++++++++++++++++++++++++++++\n " ,
46
- DeprecationWarning )
47
- return old_config .try_run (self , body , headers , include_dirs , libraries ,
48
- library_dirs , lang )
49
-
50
38
def _check_compiler (self ):
51
39
old_config ._check_compiler (self )
52
40
from numpy .distutils .fcompiler import FCompiler , new_fcompiler
@@ -429,51 +417,6 @@ def check_gcc_function_attribute(self, attribute, name):
429
417
def check_gcc_variable_attribute (self , attribute ):
430
418
return check_gcc_variable_attribute (self , attribute )
431
419
432
- def get_output (self , body , headers = None , include_dirs = None ,
433
- libraries = None , library_dirs = None ,
434
- lang = "c" , use_tee = None ):
435
- """Try to compile, link to an executable, and run a program
436
- built from 'body' and 'headers'. Returns the exit status code
437
- of the program and its output.
438
- """
439
- # 2008-11-16, RemoveMe
440
- warnings .warn ("\n +++++++++++++++++++++++++++++++++++++++++++++++++\n " \
441
- "Usage of get_output is deprecated: please do not \n " \
442
- "use it anymore, and avoid configuration checks \n " \
443
- "involving running executable on the target machine.\n " \
444
- "+++++++++++++++++++++++++++++++++++++++++++++++++\n " ,
445
- DeprecationWarning )
446
- from distutils .ccompiler import CompileError , LinkError
447
- self ._check_compiler ()
448
- exitcode , output = 255 , ''
449
- try :
450
- grabber = GrabStdout ()
451
- try :
452
- src , obj , exe = self ._link (body , headers , include_dirs ,
453
- libraries , library_dirs , lang )
454
- grabber .restore ()
455
- except :
456
- output = grabber .data
457
- grabber .restore ()
458
- raise
459
- exe = os .path .join ('.' , exe )
460
- exitstatus , output = exec_command (exe , execute_in = '.' ,
461
- use_tee = use_tee )
462
- if hasattr (os , 'WEXITSTATUS' ):
463
- exitcode = os .WEXITSTATUS (exitstatus )
464
- if os .WIFSIGNALED (exitstatus ):
465
- sig = os .WTERMSIG (exitstatus )
466
- log .error ('subprocess exited with signal %d' % (sig ,))
467
- if sig == signal .SIGINT :
468
- # control-C
469
- raise KeyboardInterrupt
470
- else :
471
- exitcode = exitstatus
472
- log .info ("success!" )
473
- except (CompileError , LinkError ):
474
- log .info ("failure." )
475
- self ._clean ()
476
- return exitcode , output
477
420
478
421
class GrabStdout (object ):
479
422
0 commit comments