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
d1578a61
Commit
d1578a61
authored
Nov 13, 2015
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
makefiles: Add support for specifying extra dependencies in libraries and programs.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3042f720
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
34 additions
and
10 deletions
+34
-10
configure
configure
+3
-5
configure.ac
configure.ac
+3
-5
makedep.c
tools/makedep.c
+28
-0
No files found.
configure
View file @
d1578a61
...
...
@@ -7989,8 +7989,7 @@ IMPORTLIB = libwine.a
INSTALL_LIB = libwine.dll
INSTALL_DEV = libwine.a
libwine_LDFLAGS = -shared
\$
(srcdir)/wine.def
libwine.dll:
\$
(srcdir)/wine.def
libwine_DEPS = wine.def
"
;;
...
...
@@ -8239,7 +8238,7 @@ libwine_LDFLAGS = -dynamiclib -install_name @rpath/libwine.$libwine_soversion.dy
as_fn_append LOADER_RULES
"
${
wine_binary
}
_OBJS = main.o
${
wine_binary
}
_LDFLAGS =
$LDEXECFLAGS
-lwine
\$
(PTHREAD_LIBS)
$
wine_binary
$wine_binary
-installed:
wine_info.plist
$
{
wine_binary
}
_DEPS =
wine_info.plist
"
;;
...
...
@@ -8755,8 +8754,7 @@ SHAREDLIB = libwine.so.$libwine_version
INSTALL_LIB = libwine.so.
$libwine_version
libwine.so.
$libwine_soversion
INSTALL_DEV = libwine.so
libwine_LDFLAGS =
$shared_ldflags
libwine.so.
$libwine_version
:
\$
(srcdir)/wine.map
libwine_DEPS = wine.map
"
...
...
configure.ac
View file @
d1578a61
...
...
@@ -723,8 +723,7 @@ IMPORTLIB = libwine.a
INSTALL_LIB = libwine.dll
INSTALL_DEV = libwine.a
libwine_LDFLAGS = -shared \$(srcdir)/wine.def
libwine.dll: \$(srcdir)/wine.def
libwine_DEPS = wine.def
"])
;;
...
...
@@ -853,7 +852,7 @@ libwine_LDFLAGS = -dynamiclib -install_name @rpath/libwine.$libwine_soversion.dy
AS_VAR_APPEND([LOADER_RULES],["
${wine_binary}_OBJS = main.o
${wine_binary}_LDFLAGS = $LDEXECFLAGS -lwine \$(PTHREAD_LIBS)
$
wine_binary $wine_binary-installed:
wine_info.plist
$
{wine_binary}_DEPS =
wine_info.plist
"])
;;
...
...
@@ -955,8 +954,7 @@ SHAREDLIB = libwine.so.$libwine_version
INSTALL_LIB = libwine.so.$libwine_version libwine.so.$libwine_soversion
INSTALL_DEV = libwine.so
libwine_LDFLAGS = $shared_ldflags
libwine.so.$libwine_version: \$(srcdir)/wine.map
libwine_DEPS = wine.map
"])
AS_VAR_APPEND([LOADER_RULES],["
...
...
tools/makedep.c
View file @
d1578a61
...
...
@@ -1866,6 +1866,28 @@ static void get_dependencies( struct strarray *deps, struct incl_file *file, str
/*******************************************************************
* get_local_dependencies
*
* Get the local dependencies of a given target.
*/
static
struct
strarray
get_local_dependencies
(
const
struct
makefile
*
make
,
const
char
*
name
,
struct
strarray
targets
)
{
unsigned
int
i
;
struct
strarray
deps
=
get_expanded_make_var_array
(
make
,
file_local_var
(
name
,
"DEPS"
));
for
(
i
=
0
;
i
<
deps
.
count
;
i
++
)
{
if
(
strarray_exists
(
&
targets
,
deps
.
str
[
i
]
))
deps
.
str
[
i
]
=
obj_dir_path
(
make
,
deps
.
str
[
i
]
);
else
deps
.
str
[
i
]
=
src_dir_path
(
make
,
deps
.
str
[
i
]
);
}
return
deps
;
}
/*******************************************************************
* add_install_rule
*/
static
void
add_install_rule
(
const
struct
makefile
*
make
,
struct
strarray
*
install_rules
,
...
...
@@ -2018,6 +2040,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
struct
strarray
mo_files
=
empty_strarray
;
struct
strarray
mc_files
=
empty_strarray
;
struct
strarray
ok_files
=
empty_strarray
;
struct
strarray
in_files
=
empty_strarray
;
struct
strarray
dlldata_files
=
empty_strarray
;
struct
strarray
c2man_files
=
empty_strarray
;
struct
strarray
implib_objs
=
empty_strarray
;
...
...
@@ -2224,6 +2247,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
free
(
dest
);
free
(
dir
);
}
strarray_add
(
&
in_files
,
xstrdup
(
obj
)
);
strarray_add
(
&
all_targets
,
xstrdup
(
obj
)
);
output
(
"%s: %s
\n
"
,
obj_dir_path
(
make
,
obj
),
source
->
filename
);
output
(
"
\t
$(SED_CMD) %s >$@ || (rm -f $@ && false)
\n
"
,
source
->
filename
);
...
...
@@ -2595,6 +2619,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
output
(
"%s:"
,
obj_dir_path
(
make
,
make
->
sharedlib
));
output_filenames_obj_dir
(
make
,
object_files
);
output_filenames
(
get_local_dependencies
(
make
,
basename
,
in_files
));
output
(
"
\n
"
);
output
(
"
\t
$(CC) -o $@"
);
output_filenames_obj_dir
(
make
,
object_files
);
...
...
@@ -2719,6 +2744,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
char
*
program_installed
=
NULL
;
char
*
program
=
strmake
(
"%s%s"
,
make
->
programs
.
str
[
i
],
exe_ext
);
struct
strarray
all_libs
=
empty_strarray
;
struct
strarray
deps
=
get_local_dependencies
(
make
,
make
->
programs
.
str
[
i
],
in_files
);
struct
strarray
objs
=
get_expanded_make_var_array
(
make
,
file_local_var
(
make
->
programs
.
str
[
i
],
"OBJS"
));
struct
strarray
symlinks
=
get_expanded_make_var_array
(
make
,
...
...
@@ -2727,6 +2753,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
if
(
!
objs
.
count
)
objs
=
object_files
;
output
(
"%s:"
,
obj_dir_path
(
make
,
program
)
);
output_filenames_obj_dir
(
make
,
objs
);
output_filenames
(
deps
);
output
(
"
\n
"
);
output
(
"
\t
$(CC) -o $@"
);
output_filenames_obj_dir
(
make
,
objs
);
...
...
@@ -2748,6 +2775,7 @@ static struct strarray output_sources( const struct makefile *make, struct strar
output
(
"
\n
"
);
output
(
"%s:"
,
obj_dir_path
(
make
,
program_installed
)
);
output_filenames_obj_dir
(
make
,
objs
);
output_filenames
(
deps
);
output
(
"
\n
"
);
output
(
"
\t
$(CC) -o $@"
);
output_filenames_obj_dir
(
make
,
objs
);
...
...
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