Commit 02bfb2a1 authored by John van Groningen's avatar John van Groningen

Merge branch 'fix-shared-libraries-for-windows' into 'master'

Improve handling of import code from library

See merge request !26
parents 9c1c006f 55328630
Pipeline #33962 passed with stage
in 48 seconds
......@@ -942,11 +942,15 @@ step intr (DLink ds=:{ok, newpaths, fileinfo, libsinfo, modpaths, abccache, proj
= GetPathNames /*abcLinkInfo.*/linkObjFileNames ofiles` srcpaths abcPathsCache ps
# (shared_libraries,library_files)
= IF_WINDOWS
(Nil, libs)
( [|l \\ (_,l) <|- libs | isSharedLibrary l]
, Filter (\(_,l) -> not (isSharedLibrary l)) libs
( [|]
, [|l \\ l=:(_,name) <|- libs | not (isSharedLibrary name)]
)
with isSharedLibrary l = size l >= 2 && l.[0]=='-' && l.[1]=='l'
( [|name \\ (_,name) <|- libs | isSharedLibrary name]
, [|l \\ l=:(_,name) <|- libs | not (isSharedLibrary name) && has_dot (size name-1) name]
)
with
isSharedLibrary l = size l >= 2 && l.[0]=='-' && l.[1]=='l'
has_dot i l = if (i<0) False (l.[i]=='.' || has_dot (i-1) l)
# (libPathsOk,lfiles,abcPathsCache, ps)
= GetPathNames library_files lfiles srcpaths abcPathsCache ps
| not objPathsOk
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment