> 21 окт. 2014 г., в 12:16, Warlich, Christof <[email protected]>
> написал(а):
>
> Hi,
>
> I’m just about porting a rather complex build from CYGWIN to MSYS2. While the
> build uses the (MinGW) GNU toolchain most of the time, some files need to be
> compiled with Microsofts VC. For this, I do something like e.g.:
>
> $ cmd /c cl -nologo -c somefile.c -Fosomefile.obj
>
> which works fine under CYGWIN, but fails when using MSYS2: Here, I need to
> “escape” the /c like this to make things work correctly:
>
> $ cmd //c cl -nologo -c somefile.c -Fosomefile.obj
>
> That’s fine so far, but next, linking fails:
>
> cmd //c link -nologo -subsystem:console -incremental:no -machine:I386
> -LIBPATH:../mvs/VC98/Lib somefile.obj -out:somefile.exe
> Microsoft (R) Incremental Linker Version 6.00.8447
> Copyright (C) Microsoft Corp 1992-1998. All rights reserved.
>
> LINK : warning LNK4105: Kein Argument mit Option "/LIBPATH;..\mvs\VC98\Lib"
> angegeben; Schalter wird ignoriert
> LINK : fatal error LNK1104: Datei "LIBC.lib" kann nicht geoeffnet werden
>
> Carefully comparing the command line with the error message, it looks like
> MSYS2 seems to apply its path conversion heuristic on “LIBPATH:”, i.e.
> changing it to “LIBPATH;”, causing the link to fail.
>
> My Questions: Did I guess right that MSYS2’s path conversion heuristic is
> causing the issue? If so, how can I prevent MSYS2 to run its path conversion
> heuristics? If not, what else is causing the problem?
>
We have special environment variable for skipping some arguments conversion.
It’s called «MSYS2_ARG_CONV_EXCL»
You can specify semicolon separated list of words that arguments start to skip
it conversion. For example:
export MSYS2_ARG_CONV_EXCL=«-LIBPATH;-machine»
Regards,
Alexey.
> Many thanks for help,
>
> Chris
>
>
>
>
>
> ------------------------------------------------------------------------------
> Comprehensive Server Monitoring with Site24x7.
> Monitor 10 servers for $9/Month.
> Get alerted through email, SMS, voice calls or mobile push notifications.
> Take corrective actions from your mobile device.
> http://p.sf.net/sfu/Zoho_______________________________________________
> <http://p.sf.net/sfu/Zoho_______________________________________________>
> Msys2-users mailing list
> [email protected] <mailto:[email protected]>
> https://lists.sourceforge.net/lists/listinfo/msys2-users
> <https://lists.sourceforge.net/lists/listinfo/msys2-users>
------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
Msys2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/msys2-users