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
aa76bec2
Commit
aa76bec2
authored
Feb 11, 2020
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
setupapi: Support a WineSourceDirs section to copy files from the Wine build or data dir.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
32a2cde6
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
install.c
dlls/setupapi/install.c
+18
-0
No files found.
dlls/setupapi/install.c
View file @
aa76bec2
...
...
@@ -119,14 +119,32 @@ static WCHAR *dup_section_line_field( HINF hinf, const WCHAR *section, const WCH
*/
static
BOOL
copy_files_callback
(
HINF
hinf
,
PCWSTR
field
,
void
*
arg
)
{
INFCONTEXT
context
;
struct
files_callback_info
*
info
=
arg
;
WCHAR
src_root
[
MAX_PATH
],
*
p
;
if
(
!
info
->
src_root
)
{
const
WCHAR
*
build_dir
=
_wgetenv
(
L"WINEBUILDDIR"
);
const
WCHAR
*
data_dir
=
_wgetenv
(
L"WINEDATADIR"
);
if
((
build_dir
||
data_dir
)
&&
SetupFindFirstLineW
(
hinf
,
L"WineSourceDirs"
,
field
,
&
context
))
{
lstrcpyW
(
src_root
,
build_dir
?
build_dir
:
data_dir
);
src_root
[
1
]
=
'\\'
;
/* change \??\ to \\?\ */
p
=
src_root
+
lstrlenW
(
src_root
);
*
p
++
=
'\\'
;
if
(
!
build_dir
||
!
SetupGetStringFieldW
(
&
context
,
2
,
p
,
MAX_PATH
-
(
p
-
src_root
),
NULL
))
{
if
(
!
SetupGetStringFieldW
(
&
context
,
1
,
p
,
MAX_PATH
-
(
p
-
src_root
),
NULL
))
p
[
-
1
]
=
0
;
}
}
else
{
lstrcpyW
(
src_root
,
PARSER_get_inf_filename
(
hinf
)
);
if
((
p
=
wcsrchr
(
src_root
,
'\\'
)))
*
p
=
0
;
}
}
if
(
field
[
0
]
==
'@'
)
/* special case: copy single file */
SetupQueueDefaultCopyW
(
info
->
queue
,
info
->
layout
?
info
->
layout
:
hinf
,
...
...
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