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
abc62981
Commit
abc62981
authored
Nov 19, 2013
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
makefiles: Add support for parent source directory in c2man.
parent
0fba32f1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
11 deletions
+19
-11
Make.rules.in
Make.rules.in
+8
-8
c2man.pl
tools/c2man.pl
+11
-3
No files found.
Make.rules.in
View file @
abc62981
...
...
@@ -108,17 +108,17 @@ all: $(MANPAGES:.man.in=.man)
# Rules for auto documentation
manpages::
$(C_SRCS)
dummy
$(C2MAN) -o $(top_builddir)/documentation/man$(api_manext) -R$(top_builddir) -C$(srcdir) $(
INCLUDES) -S$(api_manext)
$(MAINSPEC:%=-w %) $(C_SRCS)
manpages:: dummy
$(C2MAN) -o $(top_builddir)/documentation/man$(api_manext) -R$(top_builddir) -C$(srcdir) $(
PARENTSRC:%=-P%) -I$(top_srcdir)/include
$(MAINSPEC:%=-w %) $(C_SRCS)
htmlpages::
$(C_SRCS)
dummy
$(C2MAN) -o $(top_builddir)/documentation/html -R$(top_builddir) -C$(srcdir) $(
INCLUDES)
-Th $(MAINSPEC:%=-w %) $(C_SRCS)
htmlpages:: dummy
$(C2MAN) -o $(top_builddir)/documentation/html -R$(top_builddir) -C$(srcdir) $(
PARENTSRC:%=-P%) -I$(top_srcdir)/include
-Th $(MAINSPEC:%=-w %) $(C_SRCS)
sgmlpages::
$(C_SRCS)
dummy
$(C2MAN) -o $(top_builddir)/documentation/api-guide -R$(top_builddir) -C$(srcdir) $(
INCLUDES)
-Ts $(MAINSPEC:%=-w %) $(C_SRCS)
sgmlpages:: dummy
$(C2MAN) -o $(top_builddir)/documentation/api-guide -R$(top_builddir) -C$(srcdir) $(
PARENTSRC:%=-P%) -I$(top_srcdir)/include
-Ts $(MAINSPEC:%=-w %) $(C_SRCS)
xmlpages::
$(C_SRCS)
dummy
$(C2MAN) -o $(top_builddir)/documentation/api-guide-xml -R$(top_builddir) -C$(srcdir) $(
INCLUDES)
-Tx $(MAINSPEC:%=-w %) $(C_SRCS)
xmlpages:: dummy
$(C2MAN) -o $(top_builddir)/documentation/api-guide-xml -R$(top_builddir) -C$(srcdir) $(
PARENTSRC:%=-P%) -I$(top_srcdir)/include
-Tx $(MAINSPEC:%=-w %) $(C_SRCS)
# Rules for cleaning
...
...
tools/c2man.pl
View file @
abc62981
...
...
@@ -48,7 +48,8 @@ my $EXPORT_FLAGS = 4; # Flags - see above.
# Options
my
$opt_output_directory
=
"man3w"
;
# All default options are for nroff (man pages)
my
$opt_manual_section
=
"3w"
;
my
$opt_source_dir
=
""
;
my
$opt_source_dir
=
"."
;
my
$opt_parent_dir
=
""
;
my
$opt_wine_root_dir
=
""
;
my
$opt_output_format
=
""
;
# '' = nroff, 'h' = html, 's' = sgml, 'x' = xml
my
$opt_output_empty
=
0
;
# Non-zero = Create 'empty' comments (for every implemented function)
...
...
@@ -251,8 +252,10 @@ sub process_source_file($)
print
"Processing "
.
$source_file
.
"\n"
;
}
open
(
SOURCE_FILE
,
"<$source_file"
)
||
((
$opt_source_dir
ne
""
)
||
((
$opt_source_dir
ne
"
.
"
)
&&
open
(
SOURCE_FILE
,
"<$opt_source_dir/$source_file"
))
||
((
$opt_parent_dir
ne
""
)
&&
open
(
SOURCE_FILE
,
"<$opt_source_dir/$opt_parent_dir/$source_file"
))
||
die
"couldn't open "
.
$source_file
.
"\n"
;
# Add this source file to the list of source files
...
...
@@ -2241,7 +2244,8 @@ sub usage()
" -Ts : Output SGML (DocBook source) instead of a man page\n"
,
" -C <dir> : Source directory, to find source files if they are not found in the\n"
,
" current directory. Default is \""
,
$opt_source_dir
,
"\"\n"
,
" -R <dir> : Root of build directory, default is \""
,
$opt_wine_root_dir
,
"\"\n"
,
" -P <dir> : Parent source directory.\n"
,
" -R <dir> : Root of build directory.\n"
,
" -o <dir> : Create output in <dir>, default is \""
,
$opt_output_directory
,
"\"\n"
,
" -s <sect>: Set manual section to <sect>, default is "
,
$opt_manual_section
,
"\n"
,
" -e : Output \"FIXME\" documentation from empty comments.\n"
,
...
...
@@ -2291,6 +2295,10 @@ while(defined($_ = shift @ARGV))
if
(
$_
ne
""
)
{
$opt_source_dir
=
$_
;
}
last
;
};
s/^P//
&&
do
{
if
(
$_
ne
""
)
{
$opt_parent_dir
=
$_
;
}
last
;
};
s/^R//
&&
do
{
if
(
$_
=~
/^\//
)
{
$opt_wine_root_dir
=
$_
;
}
else
{
$opt_wine_root_dir
=
`cd $pwd/$_ && pwd`
;
}
$opt_wine_root_dir
=~
s/\n//
;
...
...
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