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
b78ef40a
Commit
b78ef40a
authored
Nov 13, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
makefiles: Don't copy the source makefile into the sub-directory stub makefiles.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d2e7a977
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
15 deletions
+32
-15
makedep.c
tools/makedep.c
+32
-15
No files found.
tools/makedep.c
View file @
b78ef40a
...
...
@@ -1578,7 +1578,7 @@ static FILE *open_input_makefile( const struct makefile *make )
FILE
*
ret
;
if
(
make
->
obj_dir
)
input_file_name
=
root_src_dir_path
(
obj_dir_path
(
make
,
strmake
(
"%s.in"
,
output_makefile_name
)
));
input_file_name
=
root_src_dir_path
(
obj_dir_path
(
make
,
"Makefile.in"
));
else
input_file_name
=
output_makefile_name
;
/* always use output name for main Makefile */
...
...
@@ -3629,7 +3629,7 @@ static void output_subdirs( struct makefile *make )
strarray_addall
(
&
all_targets
,
make
->
all_targets
);
for
(
i
=
0
;
i
<
subdirs
.
count
;
i
++
)
{
strarray_add
(
&
makefile_deps
,
src_dir_path
(
submakes
[
i
],
strmake
(
"%s.in"
,
output_makefile_name
)
));
strarray_add
(
&
makefile_deps
,
src_dir_path
(
submakes
[
i
],
"Makefile.in"
));
strarray_addall_uniq
(
&
make
->
phony_targets
,
submakes
[
i
]
->
phony_targets
);
strarray_addall_uniq
(
&
make
->
uninstall_files
,
submakes
[
i
]
->
uninstall_files
);
strarray_addall_uniq
(
&
dependencies
,
submakes
[
i
]
->
dependencies
);
...
...
@@ -3998,6 +3998,13 @@ static void output_stub_makefile( struct makefile *make )
struct
strarray
targets
=
empty_strarray
;
const
char
*
make_var
=
strarray_get_value
(
&
top_makefile
->
vars
,
"MAKE"
);
if
(
make
->
obj_dir
)
create_dir
(
make
->
obj_dir
);
output_file_name
=
obj_dir_path
(
make
,
"Makefile"
);
output_file
=
create_temp_file
(
output_file_name
);
output
(
"# Auto-generated stub makefile; all rules forward to the top-level makefile
\n\n
"
);
if
(
make_var
)
output
(
"MAKE = %s
\n\n
"
,
make_var
);
output
(
"all:
\n
"
);
...
...
@@ -4021,6 +4028,10 @@ static void output_stub_makefile( struct makefile *make )
output
(
".PHONY:"
);
output_filenames
(
targets
);
output
(
"
\n
"
);
fclose
(
output_file
);
output_file
=
NULL
;
rename_temp_file
(
output_file_name
);
}
...
...
@@ -4059,17 +4070,14 @@ static void output_silent_rules(void)
/*******************************************************************
* output_
dependencies
* output_
top_makefile
*/
static
void
output_
dependencies
(
struct
makefile
*
make
)
static
void
output_
top_makefile
(
struct
makefile
*
make
)
{
struct
strarray
ignore_files
=
empty_strarray
;
char
buffer
[
1024
];
FILE
*
src_file
;
int
i
,
found
=
0
;
if
(
make
->
obj_dir
)
create_dir
(
make
->
obj_dir
);
output_file_name
=
obj_dir_path
(
make
,
output_makefile_name
);
output_file
=
create_temp_file
(
output_file_name
);
...
...
@@ -4085,20 +4093,29 @@ static void output_dependencies( struct makefile *make )
if
(
!
found
)
output
(
"
\n
%s (everything below this line is auto-generated; DO NOT EDIT!!)
\n
"
,
separator
);
if
(
make
==
top_makefile
)
{
if
(
silent_rules
)
output_silent_rules
();
for
(
i
=
0
;
i
<
subdirs
.
count
;
i
++
)
output_sources
(
submakes
[
i
]
);
output_sources
(
make
);
}
else
output_stub_makefile
(
make
);
if
(
silent_rules
)
output_silent_rules
();
for
(
i
=
0
;
i
<
subdirs
.
count
;
i
++
)
output_sources
(
submakes
[
i
]
);
output_sources
(
make
);
/* disable implicit rules */
output
(
".SUFFIXES:
\n
"
);
fclose
(
output_file
);
output_file
=
NULL
;
rename_temp_file
(
output_file_name
);
}
/*******************************************************************
* output_dependencies
*/
static
void
output_dependencies
(
struct
makefile
*
make
)
{
struct
strarray
ignore_files
=
empty_strarray
;
if
(
make
->
obj_dir
)
create_dir
(
make
->
obj_dir
);
if
(
make
==
top_makefile
)
output_top_makefile
(
make
);
else
output_stub_makefile
(
make
);
strarray_addall
(
&
ignore_files
,
make
->
distclean_files
);
strarray_addall
(
&
ignore_files
,
make
->
clean_files
);
...
...
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