This was already passed through for linking, and for spec.o files, but was overlooked when implementing -Wl,--out-implib
Signed-off-by: Kevin Puetz PuetzKevinA@JohnDeere.com --- tools/winegcc/winegcc.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/tools/winegcc/winegcc.c b/tools/winegcc/winegcc.c index 0aafca1271a..aa8c63f5457 100644 --- a/tools/winegcc/winegcc.c +++ b/tools/winegcc/winegcc.c @@ -1408,6 +1408,8 @@ static void build(struct options* opts) strarray_add( &implib_args, strmake( "--cc-cmd=%s", strarray_tostring( tool, " " ))); tool = build_tool_name( opts, TOOL_LD ); strarray_add( &implib_args, strmake( "--ld-cmd=%s", strarray_tostring( tool, " " ))); + if (opts->force_pointer_size) + strarray_add(&implib_args, strmake("-m%u", 8 * opts->force_pointer_size ));
strarray_add(&implib_args, "--implib"); strarray_add(&implib_args, "-o");
Kevin Puetz PuetzKevinA@JohnDeere.com writes:
This was already passed through for linking, and for spec.o files, but was overlooked when implementing -Wl,--out-implib
Signed-off-by: Kevin Puetz PuetzKevinA@JohnDeere.com
tools/winegcc/winegcc.c | 2 ++ 1 file changed, 2 insertions(+)
This should most likely be done in get_winebuild_args().
Alexandre Julliard julliard@winehq.org writes:
This should most likely be done in get_winebuild_args().
I considered that, but that sends -m32/-m64 to subcommands that don't care e.g. winebuild --fixup-constructors peeks at the ELF magic number instead, and winebuld --builtin just modifies an existing PE header in-place. winebuild forwards force_pointer_size in get_as_command and get_ld_command, so it kind of goes with adding --cc-cmd and --ld-cmd (which are also not in get_winebuild_args).
That said, winebuild will parse -m32/-m64 whether it needs it or not, and it does get passed to set_target_ptr_size. So I can see the case for pairing it up paring it with --target (which is in get_winebuild_args)
I'll send a v2 doing it that way, you can pick whichever you like.