diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2011-05-04 20:10:36 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2011-05-04 21:41:39 +0300 |
commit | a60eb4b18345626a84e23784d77ca231812e1dff (patch) | |
tree | 80192afeadd44b073958c2762491cc7dfea778a1 | |
parent | b65bfa7564f564f85d3c595c6c1030af2acf5056 (diff) | |
download | grecs-a60eb4b18345626a84e23784d77ca231812e1dff.tar.gz grecs-a60eb4b18345626a84e23784d77ca231812e1dff.tar.bz2 |
Improve docs. Add an option to create installable distribution.
-rw-r--r-- | .gitignore | 3 | ||||
-rw-r--r-- | Makefile.am | 2 | ||||
-rw-r--r-- | am/grecs.m4 | 21 | ||||
-rw-r--r-- | doc/GRECS_SETUP.3 | 131 | ||||
-rw-r--r-- | doc/Makefile.am | 33 | ||||
-rw-r--r-- | doc/grecs-syntax.texi | 10 | ||||
-rw-r--r-- | doc/grecs_asprintf.3 | 90 | ||||
-rw-r--r-- | doc/grecs_config.5 | 343 | ||||
-rw-r--r-- | doc/grecs_error.3 | 132 | ||||
-rw-r--r-- | doc/grecs_format_locus.3 | 68 | ||||
-rw-r--r-- | doc/grecs_format_node.3 | 102 | ||||
-rw-r--r-- | doc/grecs_format_node_path.3 | 71 | ||||
-rw-r--r-- | doc/grecs_format_value.3 | 66 | ||||
-rw-r--r-- | doc/grecs_include_path_setup.3 | 68 | ||||
-rw-r--r-- | doc/grecs_malloc.3 | 129 | ||||
-rw-r--r-- | doc/grecs_node_free.3 | 63 | ||||
-rw-r--r-- | doc/grecs_parse.3 | 185 | ||||
-rw-r--r-- | doc/grecs_stmt_path.5 | 123 | ||||
-rw-r--r-- | doc/grecs_strdup.3 | 70 | ||||
-rw-r--r-- | doc/grecs_tree_free.3 | 61 | ||||
-rw-r--r-- | doc/tmpl.3 | 54 | ||||
-rw-r--r-- | src/.gitignore | 2 | ||||
-rw-r--r-- | src/Make-inst.am | 19 | ||||
-rw-r--r-- | src/Make-noinst.am | 18 | ||||
-rw-r--r-- | src/Make.am | 42 | ||||
-rw-r--r-- | tests/Makefile.am | 2 |
26 files changed, 1900 insertions, 8 deletions
@@ -1,4 +1,6 @@ | |||
1 | *.a | 1 | *.a |
2 | *.la | ||
3 | *.lo | ||
2 | *.o | 4 | *.o |
3 | *.tar.* | 5 | *.tar.* |
4 | *~ | 6 | *~ |
@@ -6,6 +8,7 @@ | |||
6 | .emacs.desktop | 8 | .emacs.desktop |
7 | .emacs.desktop.lock | 9 | .emacs.desktop.lock |
8 | .emacsrc | 10 | .emacsrc |
11 | .libs | ||
9 | ABOUT-NLS | 12 | ABOUT-NLS |
10 | ChangeLog | 13 | ChangeLog |
11 | INSTALL | 14 | INSTALL |
diff --git a/Makefile.am b/Makefile.am index 96bfab7..643d06a 100644 --- a/Makefile.am +++ b/Makefile.am | |||
@@ -1,2 +1,2 @@ | |||
1 | SUBDIRS=src @GRECS_TESTDIR@ | 1 | SUBDIRS=src @GRECS_TESTDIR@ @GRECS_DOCDIR@ |
2 | EXTRA_DIST=@GRECS_BUILD_AUX@ | 2 | EXTRA_DIST=@GRECS_BUILD_AUX@ |
diff --git a/am/grecs.m4 b/am/grecs.m4 index 8de0d08..764ce46 100644 --- a/am/grecs.m4 +++ b/am/grecs.m4 | |||
@@ -72,6 +72,8 @@ AC_DEFUN([GRECS_SETUP],[ | |||
72 | AC_PROG_YACC | 72 | AC_PROG_YACC |
73 | AM_PROG_LEX | 73 | AM_PROG_LEX |
74 | 74 | ||
75 | AC_HEADER_SYS_WAIT | ||
76 | |||
75 | AC_SUBST([GRECS_SUBDIR],m4_if([$1],,grecs,$1)) | 77 | AC_SUBST([GRECS_SUBDIR],m4_if([$1],,grecs,$1)) |
76 | _GRECS_SET_OPTIONS([$2]) | 78 | _GRECS_SET_OPTIONS([$2]) |
77 | # ********************** | 79 | # ********************** |
@@ -139,9 +141,26 @@ AC_DEFUN([GRECS_SETUP],[ | |||
139 | AM_MISSING_PROG([AUTOM4TE], [autom4te]) | 141 | AM_MISSING_PROG([AUTOM4TE], [autom4te]) |
140 | GRECS_TESTDIR=tests | 142 | GRECS_TESTDIR=tests |
141 | ]) | 143 | ]) |
142 | _GRECS_IF_OPTION_SET([getopt],[GRECS_BUILD_AUX="build-aux/getopt.m4"]) | 144 | _GRECS_IF_OPTION_SET([getopt],[ |
145 | AC_CHECK_HEADERS([getopt.h]) | ||
146 | AC_CHECK_FUNCS([sysconf getdtablesize getopt_long]) | ||
147 | GRECS_BUILD_AUX="build-aux/getopt.m4" | ||
148 | ]) | ||
143 | _GRECS_IF_OPTION_SET([git2chg],[GRECS_BUILD_AUX="$GRECS_BUILD_AUX build-aux/git2chg.awk"]) | 149 | _GRECS_IF_OPTION_SET([git2chg],[GRECS_BUILD_AUX="$GRECS_BUILD_AUX build-aux/git2chg.awk"]) |
144 | AC_SUBST([GRECS_BUILD_AUX]) | 150 | AC_SUBST([GRECS_BUILD_AUX]) |
145 | AC_SUBST([GRECS_INCLUDES]) | 151 | AC_SUBST([GRECS_INCLUDES]) |
146 | AC_SUBST([GRECS_TESTDIR]) | 152 | AC_SUBST([GRECS_TESTDIR]) |
153 | AC_SUBST([GRECS_LDADD]) | ||
154 | AC_SUBST([GRECS_DOCDIR]) | ||
155 | _GRECS_IF_OPTION_SET([install],[ | ||
156 | LT_INIT | ||
157 | GRECS_LDADD='$(top_builddir)/m4_if([$1],,grecs,$1)/src/libgrecs.la' | ||
158 | GRECS_DOCDIR='doc' | ||
159 | AC_CONFIG_FILES(m4_if([$1],,grecs,$1)/src/Makefile:m4_if([$1],,grecs,$1)/src/Make-inst.in | ||
160 | m4_if([$1],,grecs,$1)/doc/Makefile) | ||
161 | ],[ | ||
162 | GRECS_LDADD='$(top_builddir)/m4_if([$1],,grecs,$1)/src/libgrecs.a' | ||
163 | AC_CONFIG_FILES(m4_if([$1],,grecs,$1)/src/Makefile:m4_if([$1],,grecs,$1)/src/Make-noinst.in) | ||
164 | ]) | ||
165 | AC_CONFIG_FILES(m4_if([$1],,grecs,$1)/Makefile) | ||
147 | ]) | 166 | ]) |
diff --git a/doc/GRECS_SETUP.3 b/doc/GRECS_SETUP.3 new file mode 100644 index 0000000..23c0ad5 --- /dev/null +++ b/doc/GRECS_SETUP.3 | |||
@@ -0,0 +1,131 @@ | |||
1 | .\" This file is part of grecs -*- nroff -*- | ||
2 | .\" Copyright (C) 2007, 2009-2011 Sergey Poznyakoff | ||
3 | .\" | ||
4 | .\" Grecs is free software; you can redistribute it and/or modify | ||
5 | .\" it under the terms of the GNU General Public License as published by | ||
6 | .\" the Free Software Foundation; either version 3, or (at your option) | ||
7 | .\" any later version. | ||
8 | .\" | ||
9 | .\" Grecs is distributed in the hope that it will be useful, | ||
10 | .\" but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | .\" GNU General Public License for more details. | ||
13 | .\" | ||
14 | .\" You should have received a copy of the GNU General Public License | ||
15 | .\" along with Grecs. If not, see <http://www.gnu.org/licenses/>. | ||
16 | .\" This file is part of SLB. | ||
17 | .\" Copyright (C) 2011 Sergey Poznyakoff | ||
18 | .\" | ||
19 | .TH GRECS_SETUP 3 "May 4, 2011" "GRECS" "Grecs User Reference" | ||
20 | .SH NAME | ||
21 | GRECS_SETUP \- Initialize \fBgrecs\fR submodule. | ||
22 | .SH SYNOPSIS | ||
23 | .BI "GRECS_SETUP(" "dir" ", " "options" ", " "pp-setup-file" ) | ||
24 | .SH DESCRIPTION | ||
25 | The \fBGRECS_SETUP\fR macro is invoked from the host project's | ||
26 | \fBconfigure.ac\fR. It initializes the \fBgrecs\fR submodule | ||
27 | variables for compilation within that project. | ||
28 | .PP | ||
29 | All arguments are optional. | ||
30 | .PP | ||
31 | The | ||
32 | .I dir | ||
33 | argument specifies the directory, relative to the source tree top, | ||
34 | where \fBgrecs\fR has been cloned. If omitted, \fBgrecs\fR is assumed. | ||
35 | .sp | ||
36 | For example, if \fBgrecs\fR was cloned using the following command: | ||
37 | .sp | ||
38 | .nf | ||
39 | git clone ssh://git.gnu.org.ua/gitroot/grecs.git lib/grecs | ||
40 | .fi | ||
41 | .sp | ||
42 | then the \fIdir\fR argument must be \fBlib/grecs\fR. | ||
43 | .PP | ||
44 | The | ||
45 | .I options | ||
46 | argument is a space-separated list of options. The following options | ||
47 | are understood: | ||
48 | .TP | ||
49 | .B no-preproc | ||
50 | Disable the use of preprocessor. | ||
51 | .TP | ||
52 | .B install | ||
53 | Create and install shared library \fBlibgrecs.so\fR. Install the | ||
54 | documentation as well. | ||
55 | .TP | ||
56 | .B std-pp-setup | ||
57 | Install the standard \fBpp-setup\fR file. | ||
58 | .TP | ||
59 | .B pp-setup-option | ||
60 | Add the | ||
61 | .B --with-pp-setup-file | ||
62 | option to the produced configuration file. This option allows user to | ||
63 | control whether to install the \fBpp-setup\fR file. | ||
64 | .TP | ||
65 | .B tests | ||
66 | Build tests. | ||
67 | .TP | ||
68 | .B getopt | ||
69 | Add \fBgetopt.m4\fR to the distributed tarball. The file is located | ||
70 | in \fIdir\fR/build-aux. | ||
71 | .TP | ||
72 | .B git2chg | ||
73 | Add \fBgit2chg.awk\fR to the distributed tarball. The file is located | ||
74 | in \fIdir\fR/build-aux. | ||
75 | .PP | ||
76 | The | ||
77 | .I pp-setup-file | ||
78 | argument supplies the pathname of the alternative preprocessor | ||
79 | setup file. It is ignored if | ||
80 | .B std-pp-setup option | ||
81 | is given. | ||
82 | .PP | ||
83 | If neither | ||
84 | .B std-pp-setup | ||
85 | option, nor | ||
86 | .I pp-setup-file | ||
87 | parameter are supplied, no preprocessor setup file is installed. | ||
88 | .SH EXAMPLE | ||
89 | .SS "Default setup" | ||
90 | .RS 4 | ||
91 | .nf | ||
92 | GRECS_SETUP | ||
93 | .fi | ||
94 | .RE | ||
95 | .SS "Complex setup" | ||
96 | The library sources are in \fBlib/grecs\fR. Configure the testsuite | ||
97 | and add the \fBgetopt.m4\fR file to the distribution. Install | ||
98 | preprocessor setup file from \fBsrc/pp-setup\fR: | ||
99 | .sp | ||
100 | .RS 4 | ||
101 | .nf | ||
102 | GRECS_SETUP(lib/grecs, [tests getopt], [$(top_srcdir)/src/pp-setup]) | ||
103 | .RE | ||
104 | .SH "SEE ALSO" | ||
105 | .BR getopt.m4 (5), | ||
106 | .BR pp-setup (5). | ||
107 | .SH AUTHORS | ||
108 | Sergey Poznyakoff | ||
109 | .SH "BUG REPORTS" | ||
110 | Report bugs to <gray+grecs@gnu.org.ua>. | ||
111 | .SH COLOPHON | ||
112 | The \fBGrecs\fR library is constantly changing, so this manual page | ||
113 | may be incorrect or out-of-date. For the latest copy of \fBGrecs\fR | ||
114 | documentation, visit <http://www.gnu.org.ua/software/grecs>. | ||
115 | .SH COPYRIGHT | ||
116 | Copyright \(co 2011 Sergey Poznyakoff | ||
117 | .br | ||
118 | .na | ||
119 | License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> | ||
120 | .br | ||
121 | .ad | ||
122 | This is free software: you are free to change and redistribute it. | ||
123 | There is NO WARRANTY, to the extent permitted by law. | ||
124 | .\" Local variables: | ||
125 | .\" eval: (add-hook 'write-file-hooks 'time-stamp) | ||
126 | .\" time-stamp-start: ".TH [A-Z_][A-Z0-9_]* [0-9] \"" | ||
127 | .\" time-stamp-format: "%:B %:d, %:y" | ||
128 | .\" time-stamp-end: "\"" | ||
129 | .\" time-stamp-line-limit: 20 | ||
130 | .\" end: | ||