Skip to content

Commit f0ab8d0

Browse files
committed
filter cargo artifacts
1 parent fe45e2f commit f0ab8d0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/Language/Rust/Inline/Internal.hs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,9 +217,8 @@ cargoFinalizer extraArgs dependencies = do
217217
Just (JSString (fromJSString -> "compiler-artifact")) -> do
218218
case lookup "filenames" jObj of
219219
Just (JSArray values) -> forM_ values $ \case
220-
JSString (fromJSString -> rustLibFp) -> do
220+
JSString (fromJSString -> rustLibFp) | ext <- takeExtension rustLibFp, ext `elem` [".a", ".o"] -> do
221221
-- Move the library to a GHC temporary file
222-
let ext = takeExtension rustLibFp
223222
rustLibFp' <- addTempFile ext
224223
runIO $ copyFile rustLibFp rustLibFp'
225224

0 commit comments

Comments
 (0)