@@ -1684,9 +1684,7 @@ def test_prelinking(self):
1684
1684
# Prelinking currently only works on recently new GNU toolchains.
1685
1685
# Skip everything else. When support for other toolchains is added,
1686
1686
# remove limitations as necessary.
1687
- if is_osx ():
1688
- raise SkipTest ('Prelinking not supported on Darwin.' )
1689
- if 'clang' in os .environ .get ('CC' , 'dummy' ):
1687
+ if 'clang' in os .environ .get ('CC' , 'dummy' ) and not is_osx ():
1690
1688
raise SkipTest ('Prelinking not supported with Clang.' )
1691
1689
testdir = os .path .join (self .unit_test_dir , '86 prelinking' )
1692
1690
env = get_fake_env (testdir , self .builddir , self .prefix )
@@ -1704,8 +1702,7 @@ def test_prelinking(self):
1704
1702
stderr = subprocess .DEVNULL ,
1705
1703
encoding = 'utf-8' , text = True , timeout = 1 )
1706
1704
obj_files = p .stdout .strip ().split ('\n ' )
1707
- self .assertEqual (len (obj_files ), 1 )
1708
- self .assertTrue (obj_files [0 ].endswith ('-prelink.o' ))
1705
+ self .assertTrue (any (o .endswith ('-prelink.o' ) for o in obj_files ))
1709
1706
1710
1707
def do_one_test_with_nativefile (self , testdir , args ):
1711
1708
testdir = os .path .join (self .common_test_dir , testdir )
0 commit comments