Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
35a7ed0c
Commit
35a7ed0c
authored
May 04, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
May 04, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winegcc: Add support for msvc target.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
66aa39d9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
5 deletions
+32
-5
winegcc.c
tools/winegcc/winegcc.c
+32
-5
No files found.
tools/winegcc/winegcc.c
View file @
35a7ed0c
...
...
@@ -487,7 +487,6 @@ static strarray *get_link_args( struct options *opts, const char *output_name )
strarray_add
(
flags
,
strmake
(
"-Wl,-soname,%s.so"
,
output_name
));
break
;
case
PLATFORM_WINDOWS
:
case
PLATFORM_MINGW
:
case
PLATFORM_CYGWIN
:
if
(
opts
->
shared
||
opts
->
win16_app
)
...
...
@@ -515,6 +514,24 @@ static strarray *get_link_args( struct options *opts, const char *output_name )
strarray_addall
(
link_args
,
flags
);
return
link_args
;
case
PLATFORM_WINDOWS
:
if
(
opts
->
shared
||
opts
->
win16_app
)
{
strarray_add
(
flags
,
"-shared"
);
strarray_add
(
flags
,
"-Wl,-kill-at"
);
}
if
(
opts
->
unicode_app
)
strarray_add
(
flags
,
"-municode"
);
if
(
opts
->
nodefaultlibs
||
opts
->
use_msvcrt
)
strarray_add
(
flags
,
"-nodefaultlibs"
);
if
(
opts
->
nostartfiles
||
opts
->
use_msvcrt
)
strarray_add
(
flags
,
"-nostartfiles"
);
if
(
opts
->
image_base
)
strarray_add
(
flags
,
strmake
(
"-Wl,-base:%s"
,
opts
->
image_base
));
if
(
opts
->
subsystem
)
strarray_add
(
flags
,
strmake
(
"-Wl,-subsystem:%s"
,
opts
->
subsystem
));
else
strarray_add
(
flags
,
strmake
(
"-Wl,-subsystem:%s"
,
opts
->
gui_app
?
"windows"
:
"console"
));
strarray_addall
(
link_args
,
flags
);
return
link_args
;
default:
if
(
opts
->
image_base
)
{
...
...
@@ -1298,16 +1315,26 @@ static void build(struct options* opts)
entry_point
=
opts
->
target_cpu
==
CPU_x86
?
"DllMainCRTStartup@12"
:
"DllMainCRTStartup"
;
if
(
is_pe
&&
entry_point
)
strarray_add
(
link_args
,
strmake
(
"-Wl,--entry,%s%s"
,
is_pe
&&
opts
->
target_cpu
==
CPU_x86
?
"_"
:
""
,
entry_point
));
{
if
(
opts
->
target_platform
==
PLATFORM_WINDOWS
)
strarray_add
(
link_args
,
strmake
(
"-Wl,-entry:%s"
,
entry_point
));
else
strarray_add
(
link_args
,
strmake
(
"-Wl,--entry,%s%s"
,
is_pe
&&
opts
->
target_cpu
==
CPU_x86
?
"_"
:
""
,
entry_point
));
}
strarray_add
(
link_args
,
spec_o_name
);
if
(
is_pe
)
{
for
(
j
=
0
;
j
<
opts
->
delayimports
->
size
;
j
++
)
strarray_add
(
link_args
,
strmake
(
"-Wl,-delayload,%s"
,
opts
->
delayimports
->
base
[
j
]));
{
if
(
opts
->
target_platform
==
PLATFORM_WINDOWS
)
strarray_add
(
link_args
,
strmake
(
"-Wl,-delayload:%s"
,
opts
->
delayimports
->
base
[
j
]));
else
strarray_add
(
link_args
,
strmake
(
"-Wl,-delayload,%s"
,
opts
->
delayimports
->
base
[
j
]));
}
}
for
(
j
=
0
;
j
<
files
->
size
;
j
++
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment