aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2011-05-13 23:43:07 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2011-05-13 23:43:07 +0300
commit3b336240d9ac05bac621568b95086dbff2371acd (patch)
treec4a1f208ce8f33300f7e31811b79aa921f9e357e
parent4c1056b45580fcb687cac656834f42dd9fba4ae8 (diff)
downloadgrecs-3b336240d9ac05bac621568b95086dbff2371acd.tar.gz
grecs-3b336240d9ac05bac621568b95086dbff2371acd.tar.bz2
Improvements in git2chg.awk and grecs setup sequence.
* build-aux/git2chg.awk: New configuration variables: since=YYYY-MM-DD, to cut off entries earlier than the given date, and append=FILE, to append FILE to the generated ChangeLog. * am/grecs.m4 (GRECS_HOST_PROJECT_INCLUDES): New substitution variable. * src/Make.am (INCLUDES): Expand GRECS_HOST_PROJECT_INCLUDES. * tests/Makefile.am: Likewise.
-rw-r--r--am/grecs.m41
-rw-r--r--build-aux/git2chg.awk30
-rw-r--r--src/Make.am2
-rw-r--r--tests/Makefile.am2
4 files changed, 33 insertions, 2 deletions
diff --git a/am/grecs.m4 b/am/grecs.m4
index ce6d077..0d1b03d 100644
--- a/am/grecs.m4
+++ b/am/grecs.m4
@@ -159,6 +159,7 @@ AC_DEFUN([GRECS_SETUP],[
AC_SUBST([GRECS_DISTCK_AT])
AC_SUBST([GRECS_README])
AC_SUBST([GRECS_INCLUDES],['-I$(top_srcdir)/]grecsdir[src]')
+ AC_SUBST([GRECS_HOST_PROJECT_INCLUDES])
_GRECS_OPTION_SWITCH([install],[
LT_INIT
GRECS_LDADD=['$(top_builddir)/]grecsdir[src/libgrecs.la']
diff --git a/build-aux/git2chg.awk b/build-aux/git2chg.awk
index 1ddf698..11e2f1c 100644
--- a/build-aux/git2chg.awk
+++ b/build-aux/git2chg.awk
@@ -14,8 +14,30 @@
# You should have received a copy of the GNU General Public License
# along with Grecs. If not, see <http://www.gnu.org/licenses/>.
+BEGIN {
+ if (since)
+ split(since,since_a,"-")
+}
+
+function timeok(t, a) {
+ if (!since)
+ return 1
+ split(t,a,"-")
+ if (a[1] < since_a[1])
+ return 0
+ if (a[1] > since_a[1])
+ return 1
+ if (a[2] < since_a[2])
+ return 0
+ if (a[2] > since_a[2])
+ return 1
+ return a[3] > since_a[3]
+}
+
/^[0-9]+ .* +<[^>]+>/ {
s = strftime("%F", $1)
+ if (!timeok(s))
+ exit
sub(/^[0-9]+ +/,"")
if (s == datestr && author == $0)
next
@@ -35,6 +57,14 @@ NF==0 {
print "\t" $0 }
END {
+ if (append) {
+ print ""
+ while ((getline < append) > 0) {
+ if (match($0, /^Local *Variables:/))
+ break
+ print
+ }
+ }
print "\f"
# Make sure Emacs won't recognize this line:
print "Local", "Variables:"
diff --git a/src/Make.am b/src/Make.am
index e415ada..915e6c4 100644
--- a/src/Make.am
+++ b/src/Make.am
@@ -35,7 +35,7 @@ noinst_HEADERS = yygrecs.h
EXTRA_DIST=grecs-gram.h $(PP_SETUP_FILE) Make.am Make-inst.am Make-shared.am Make-static.am
-INCLUDES = -I$(srcdir) -I$(top_srcdir)/@GRECS_SUBDIR@ @GRECS_INCLUDES@
+INCLUDES = -I$(srcdir) -I$(top_srcdir)/@GRECS_SUBDIR@ @GRECS_INCLUDES@ @GRECS_HOST_PROJECT_INCLUDES@
AM_YFLAGS = -dtv
AM_LFLAGS = -d
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 0bf7752..df8739a 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -87,7 +87,7 @@ noinst_PROGRAMS = \
gcfver
LDADD = @GRECS_LDADD@
-INCLUDES = @GRECS_INCLUDES@
+INCLUDES = @GRECS_INCLUDES@ @GRECS_HOST_PROJECT_INCLUDES@

Return to:

Send suggestions and report system problems to the System administrator.