Added guile-names.x' here and a rule to make it from
guile-names.c'
1998-10-11 Martin Baulig <martin@home-of-linux.org> * names/Makefile.am (BUILT_SOURCES, CLEANFILES): Added `guile-names.x' here and a rule to make it from `guile-names.c' using guile-snarf. * names/guile-names.awk: Use the SCM_GLOBAL_VCELL macros and guile-snarf here; declared all `glibtop_guile_*' functions static.
This commit is contained in:
committed by
Martin Baulig
parent
691ce2b843
commit
abf854c16a
@@ -1,5 +1,12 @@
|
||||
1998-10-11 Martin Baulig <martin@home-of-linux.org>
|
||||
|
||||
* names/Makefile.am (BUILT_SOURCES, CLEANFILES): Added
|
||||
`guile-names.x' here and a rule to make it from `guile-names.c'
|
||||
using guile-snarf.
|
||||
|
||||
* names/guile-names.awk: Use the SCM_GLOBAL_VCELL macros and
|
||||
guile-snarf here; declared all `glibtop_guile_*' functions static.
|
||||
|
||||
* guile.awk: Declared all `glibtop_guile_get_*' functions static.
|
||||
|
||||
* Makefile.am (BUILT_SOURCES, CLEANFILES): Added `guile.x'.
|
||||
|
@@ -8,13 +8,16 @@ libgtop_guile_names_la_SOURCES = guile-names.c
|
||||
|
||||
libgtop_guile_names_la_LDFLAGS = $(LT_VERSION_INFO)
|
||||
|
||||
BUILT_SOURCES = guile-names.c
|
||||
BUILT_SOURCES = guile-names.c guile-names.x
|
||||
|
||||
guile-names.c: guile-names.awk $(top_builddir)/config.h $(top_srcdir)/features.def
|
||||
$(AWK) -f $(srcdir)/guile-names.awk < $(top_srcdir)/features.def > gnc-t
|
||||
mv gnc-t guile-names.c
|
||||
|
||||
guile-names.x: guile-names.c
|
||||
guile-snarf $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $< > $@
|
||||
|
||||
EXTRA_DIST = guile-names.awk
|
||||
|
||||
CLEANFILES = guile-names.c
|
||||
CLEANFILES = guile-names.c guile-names.x
|
||||
|
||||
|
@@ -14,7 +14,7 @@ BEGIN {
|
||||
}
|
||||
|
||||
function output(feature) {
|
||||
print "SCM";
|
||||
print "static SCM";
|
||||
print "glibtop_guile_names_"feature" (void)";
|
||||
print "{";
|
||||
print "\tint i;";
|
||||
@@ -33,7 +33,7 @@ function output(feature) {
|
||||
|
||||
print "";
|
||||
|
||||
print "SCM";
|
||||
print "static SCM";
|
||||
print "glibtop_guile_types_"feature" (void)";
|
||||
print "{";
|
||||
print "\tint i;";
|
||||
@@ -52,7 +52,7 @@ function output(feature) {
|
||||
|
||||
print "";
|
||||
|
||||
print "SCM";
|
||||
print "static SCM";
|
||||
print "glibtop_guile_labels_"feature" (void)";
|
||||
print "{";
|
||||
print "\tint i;";
|
||||
@@ -72,7 +72,7 @@ function output(feature) {
|
||||
|
||||
print "";
|
||||
|
||||
print "SCM";
|
||||
print "static SCM";
|
||||
print "glibtop_guile_descriptions_"feature" (void)";
|
||||
print "{";
|
||||
print "\tint i;";
|
||||
@@ -109,22 +109,24 @@ END {
|
||||
output(feature);
|
||||
}
|
||||
|
||||
for (feature in features) {
|
||||
feature_name = feature; sub(/_/, "-", feature_name);
|
||||
print "SCM_GLOBAL_VCELL (s_names_"feature", \"glibtop-names-"feature_name"\");";
|
||||
print "SCM_GLOBAL_VCELL (s_labels_"feature", \"glibtop-labels-"feature_name"\");";
|
||||
print "SCM_GLOBAL_VCELL (s_types_"feature", \"glibtop-types-"feature_name"\");";
|
||||
print "SCM_GLOBAL_VCELL (s_descriptions_"feature", \"glibtop-descriptions-"feature_name"\");";
|
||||
}
|
||||
print "";
|
||||
|
||||
print "void";
|
||||
print "glibtop_boot_guile_names (void)";
|
||||
print "{";
|
||||
|
||||
print "#include \"guile-names.x\"";
|
||||
for (feature in features) {
|
||||
print "\tgh_new_procedure0_0";
|
||||
print "\t\t(\"glibtop-names-"feature"\", glibtop_guile_names_"feature");";
|
||||
print "";
|
||||
print "\tgh_new_procedure0_0";
|
||||
print "\t\t(\"glibtop-types-"feature"\", glibtop_guile_types_"feature");";
|
||||
print "";
|
||||
print "\tgh_new_procedure0_0";
|
||||
print "\t\t(\"glibtop-labels-"feature"\", glibtop_guile_labels_"feature");";
|
||||
print "";
|
||||
print "\tgh_new_procedure0_0";
|
||||
print "\t\t(\"glibtop-descriptions-"feature"\", glibtop_guile_descriptions_"feature");";
|
||||
print "SCM_SETCDR (s_names_"feature", glibtop_guile_names_"feature" ());";
|
||||
print "SCM_SETCDR (s_labels_"feature", glibtop_guile_labels_"feature" ());";
|
||||
print "SCM_SETCDR (s_types_"feature", glibtop_guile_types_"feature" ());";
|
||||
print "SCM_SETCDR (s_descriptions_"feature", glibtop_guile_descriptions_"feature" ());";
|
||||
}
|
||||
print "}";
|
||||
}
|
||||
|
Reference in New Issue
Block a user