Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
356e46a1
Commit
356e46a1
authored
Oct 29, 2015
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
makefiles: Generate rules for installing symlinks.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
5cd33959
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
19 deletions
+25
-19
makedep.c
tools/makedep.c
+22
-1
Makefile.in
tools/winegcc/Makefile.in
+3
-18
No files found.
tools/makedep.c
View file @
356e46a1
...
...
@@ -1831,6 +1831,9 @@ static void output_install_rules( struct makefile *make, struct strarray files,
output
(
"
\t
%s $(INSTALL_SCRIPT_FLAGS) %s $(DESTDIR)%s
\n
"
,
install_sh
,
src_dir_path
(
make
,
file
),
dest
+
1
);
break
;
case
'y'
:
/* symlink */
output
(
"
\t
$(RM) $(DESTDIR)%s && $(LN_S) %s $(DESTDIR)%s
\n
"
,
dest
+
1
,
file
,
dest
+
1
);
break
;
default:
assert
(
0
);
}
...
...
@@ -1853,7 +1856,7 @@ static void output_install_rules( struct makefile *make, struct strarray files,
static
struct
strarray
output_sources
(
struct
makefile
*
make
,
struct
strarray
*
testlist_files
)
{
struct
incl_file
*
source
;
unsigned
int
i
;
unsigned
int
i
,
j
;
struct
strarray
object_files
=
empty_strarray
;
struct
strarray
crossobj_files
=
empty_strarray
;
struct
strarray
res_files
=
empty_strarray
;
...
...
@@ -2018,6 +2021,7 @@ static struct strarray output_sources( struct makefile *make, struct strarray *t
{
if
(
strendswith
(
obj
,
".man"
)
&&
source
->
file
->
args
)
{
struct
strarray
symlinks
;
char
*
dir
,
*
dest
=
replace_extension
(
obj
,
".man"
,
""
);
char
*
lang
=
strchr
(
dest
,
'.'
);
char
*
section
=
source
->
file
->
args
;
...
...
@@ -2028,6 +2032,10 @@ static struct strarray output_sources( struct makefile *make, struct strarray *t
}
else
dir
=
strmake
(
"$(mandir)/man%s"
,
section
);
add_install_rule
(
make
,
dest
,
xstrdup
(
obj
),
strmake
(
"d%s/%s.%s"
,
dir
,
dest
,
section
));
symlinks
=
get_expanded_make_var_array
(
make
,
file_local_var
(
dest
,
"SYMLINKS"
));
for
(
j
=
0
;
j
<
symlinks
.
count
;
j
++
)
add_install_rule
(
make
,
symlinks
.
str
[
j
],
strmake
(
"%s.%s"
,
dest
,
section
),
strmake
(
"y%s/%s.%s"
,
dir
,
symlinks
.
str
[
j
],
section
));
free
(
dest
);
free
(
dir
);
strarray_add
(
&
all_targets
,
xstrdup
(
obj
)
);
...
...
@@ -2447,6 +2455,8 @@ static struct strarray output_sources( struct makefile *make, struct strarray *t
struct
strarray
all_libs
=
empty_strarray
;
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
,
file_local_var
(
make
->
programs
.
str
[
i
],
"SYMLINKS"
));
if
(
!
objs
.
count
)
objs
=
object_files
;
output
(
"%s:"
,
obj_dir_path
(
make
,
program
)
);
...
...
@@ -2485,8 +2495,19 @@ static struct strarray output_sources( struct makefile *make, struct strarray *t
output
(
"
\n
"
);
strarray_add
(
&
all_targets
,
program
);
if
(
symlinks
.
count
)
{
output_filenames_obj_dir
(
make
,
symlinks
);
output
(
": %s
\n
"
,
obj_dir_path
(
make
,
program
));
output
(
"
\t
$(RM) $@ && $(LN_S) %s $@
\n
"
,
obj_dir_path
(
make
,
program
));
strarray_addall
(
&
all_targets
,
symlinks
);
}
add_install_rule
(
make
,
program
,
program_installed
?
program_installed
:
program
,
strmake
(
"p$(bindir)/%s"
,
program
));
for
(
j
=
0
;
j
<
symlinks
.
count
;
j
++
)
add_install_rule
(
make
,
symlinks
.
str
[
j
],
program
,
strmake
(
"y$(bindir)/%s%s"
,
symlinks
.
str
[
j
],
exe_ext
));
}
for
(
i
=
0
;
i
<
make
->
scripts
.
count
;
i
++
)
...
...
tools/winegcc/Makefile.in
View file @
356e46a1
...
...
@@ -2,6 +2,8 @@ PROGRAMS = winegcc
MANPAGES
=
winegcc.man.in
winegcc_SYMLINKS
=
winecpp wineg++
C_SRCS
=
\
utils.c
\
winegcc.c
...
...
@@ -16,21 +18,4 @@ winegcc_EXTRADEFS = \
-DLD
=
"
\"
$(LD)
\"
"
\
-DPRELINK
=
"
\"
$(PRELINK)
\"
"
INSTALL_DEV
=
$(PROGRAMS)
EXTRA_TARGETS
=
winecpp
$(EXEEXT)
wineg++
$(EXEEXT)
all
:
$(EXTRA_TARGETS)
winecpp$(EXEEXT) wineg++$(EXEEXT)
:
winegcc$(EXEEXT)
$(RM)
$@
&&
$(LN_S)
winegcc
$(EXEEXT)
$@
install install-dev
::
cd
$(DESTDIR)$(bindir)
&&
$(RM)
wineg++
$(EXEEXT)
&&
$(LN_S)
winegcc
$(EXEEXT)
wineg++
$(EXEEXT)
cd
$(DESTDIR)$(bindir)
&&
$(RM)
winecpp
$(EXEEXT)
&&
$(LN_S)
winegcc
$(EXEEXT)
winecpp
$(EXEEXT)
cd
$(DESTDIR)$(mandir)
/man
$(prog_manext)
&&
$(RM)
wineg++.
$(prog_manext)
&&
$(LN_S)
winegcc.
$(prog_manext)
wineg++.
$(prog_manext)
cd
$(DESTDIR)$(mandir)
/man
$(prog_manext)
&&
$(RM)
winecpp.
$(prog_manext)
&&
$(LN_S)
winegcc.
$(prog_manext)
winecpp.
$(prog_manext)
uninstall
::
$(RM)
$(DESTDIR)$(bindir)
/wineg++
$(EXEEXT)
$(DESTDIR)$(bindir)
/winecpp
$(EXEEXT)
$(RM)
$(DESTDIR)$(mandir)
/man
$(prog_manext)
/wineg++.
$(prog_manext)
$(DESTDIR)$(mandir)
/man
$(prog_manext)
/winecpp.
$(prog_manext)
INSTALL_DEV
=
$(PROGRAMS)
$(winegcc_SYMLINKS)
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