Jacek Caban : winegcc: Check also for unsuffixed lib/ dir in get_lib_dir.

Alexandre Julliard julliard at winehq.org
Thu Jul 19 16:47:58 CDT 2018


Module: wine
Branch: master
Commit: 551d0971c54896f286e41a39217094a477363d49
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=551d0971c54896f286e41a39217094a477363d49

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Thu Jul 19 16:50:33 2018 +0200

winegcc: Check also for unsuffixed lib/ dir in get_lib_dir.

Wine uses lib/ and lib64/ by default. This fixes -m32 handling in such
configuration.

Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 tools/winegcc/winegcc.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/tools/winegcc/winegcc.c b/tools/winegcc/winegcc.c
index 5d604d2..931ac53 100644
--- a/tools/winegcc/winegcc.c
+++ b/tools/winegcc/winegcc.c
@@ -458,7 +458,12 @@ static char *get_lib_dir( struct options *opts )
         while (p > buffer && p[-1] == '/') p--;
         strcpy( p, libwine );
         if (check_platform( opts, buffer )) goto found;
-        if (p > buffer + 2 && (!memcmp( p - 2, "32", 2 ) || !memcmp( p - 2, "64", 2 ))) p -= 2;
+        if (p > buffer + 2 && (!memcmp( p - 2, "32", 2 ) || !memcmp( p - 2, "64", 2 )))
+        {
+            p -= 2;
+            strcpy( p, libwine );
+            if (check_platform( opts, buffer )) goto found;
+        }
         if (opts->target_cpu != CPU_x86_64 && opts->target_cpu != CPU_ARM64)
         {
             strcpy( p, "32" );




More information about the wine-cvs mailing list