Skip to content

Commit 8720965

Browse files
bellenotsftnight
authored andcommitted
Dont pass -fPIC flag on Windows (unsupported option)
1 parent 5947e13 commit 8720965

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

test/CodeGeneration/Symbols.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// LICENSE.TXT for details.
77
//------------------------------------------------------------------------------
88

9-
// RUN: clang -shared -fPIC -DCLING_EXPORT=%dllexport -DBUILD_SHARED %s -o%T/libSymbols%shlibext
9+
// RUN: clang -shared %fPIC -DCLING_EXPORT=%dllexport -DBUILD_SHARED %s -o%T/libSymbols%shlibext
1010
// RUN: %cling --nologo -L%T -lSymbols %s | FileCheck %s
1111

1212
// Check that weak symbols do not get re-emitted (ROOT-6124)

test/lit.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,8 +276,10 @@ else:
276276

277277
if platform.system() in ['Windows']:
278278
config.substitutions.append(('%dllexport', '"__declspec(dllexport)"'))
279+
config.substitutions.append(('%fPIC', ''))
279280
else:
280281
config.substitutions.append(('%dllexport', ''))
282+
config.substitutions.append(('%fPIC', '-fPIC'))
281283

282284
if IsWindows and execute_external:
283285
config.substitutions.append(('%mkdir', 'mkdir'))

0 commit comments

Comments
 (0)