[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-smalltalk] Automake suggestions
From: |
H. Nanosecond |
Subject: |
[Help-smalltalk] Automake suggestions |
Date: |
Sat, 10 Feb 2001 14:53:57 -0500 (EST) |
Hello,
I have some changes I suggest for the Automake files.
I added files to EXTRA_DIST to remove the need for a dist-hook target, I
made it work when building in a directory different from the source, and
changed the test process to give seperate tests for each file. The test system
is copied from kaffe-1.0.5.
Also note that in kernel/Makefile.am the basedir variable is not exported from
the top Makefile, so didn't work correctly, and that the binary isn't installed
first.
diff --unified --recursive --exclude=Makefile --exclude=Makefile.in
--exclude=kernel/*.st --exclude=config.log --exclude=config.status
--exclude=configure --exclude=gst-config --exclude=gst-package
--exclude=gstconf.h -N --exclude=instlog --exclude=gst.output
--exclude=old/libgst/gst.tab.h --exclude=*/libgst/gst.tab.c --exclude=myinst/*
--exclude=Makebody --exclude=Makebody.in --exclude=*.st old/ new/
--- old/Makebody.am Wed Jan 17 07:37:51 2001
+++ new/Makebody.am Fri Feb 9 20:53:49 2001
@@ -24,7 +24,8 @@
examples tcp xml test web i18n
EXTRA_DIST = $(base_DATA) gst-config.in gst-package.in \
- short-names gsticon.ico autogen COPYING.DOC COPYING.LESSER
+ short-names gsticon.ico autogen COPYING.DOC COPYING.LESSER \
+ $(m4_DIST)
include_HEADERS = gstconf.h
DISTCLEANFILES = gstconf.h cfuncs.c Makebody
@@ -56,18 +57,19 @@
m4/waitpid.m4 m4/lightning.m4 m4/localedata.m4 m4/va_arg.m4 \
m4/passvar.m4 m4/modules.m4 m4/gcc.m4
-dist-hook:
- cd $(distdir); rm -f $(DISTCLEANFILES); true
- mkdir $(distdir)/m4
- chmod 777 $(distdir)/m4
- cp -p $(m4_DIST) $(distdir)/m4
+
+#dist-hook:
+# cd $(distdir); rm -f $(DISTCLEANFILES); true
+# mkdir $(distdir)/m4
+# chmod 777 $(distdir)/m4
+# cp -p $(m4_DIST) $(distdir)/m4
# These rules defer the lengthy optimized build to just before installing
install: optimize
optimize:
- cd $(top_srcdir)/libgst && $(MAKE) optimize
+ cd libgst && $(MAKE) optimize
$(MAKE) all
.PHONY: optimize
--- old/configure.in Sat Jan 20 08:56:39 2001
+++ new/configure.in Fri Feb 9 02:43:42 2001
@@ -228,7 +228,7 @@
dnl
blox/Makefile compiler/Makefile examples/Makefile examples/blox/Makefile
i18n/Makefile kernel/Makefile tcp/Makefile web/Makefile xml/Makefile
-test/Makefile
+test/Makefile test/low-level/Makefile test/low-level/TestScript
dnl Unsupported makefiles
dnl
--- old/i18n/Makefile.am Wed Jan 17 08:00:58 2001
+++ new/i18n/Makefile.am Sun Feb 4 22:51:39 2001
@@ -49,17 +49,17 @@
$(i18n_DATA): $(SCRIPTS)
Set-0208.st: Set-0208.st.in Unicode-0208
- ./tables Unicode-0208 < Set-0208.st.in > $@
+ ./tables $(srcdir)/Unicode-0208 < $(srcdir)/Set-0208.st.in > $@
Set-EUC.st: Set-EUC.st.in Unicode-0212
- ./tables Unicode-0212 < Set-EUC.st.in > $@
+ ./tables $(srcdir)/Unicode-0212 < $(srcdir)/Set-EUC.st.in > $@
Set-SJIS.st: Set-SJIS.st.in Unicode-SJIS
- ./tables Unicode-SJIS < Set-SJIS.st.in > $@
+ ./tables $(srcdir)/Unicode-SJIS < $(srcdir)/Set-SJIS.st.in > $@
Set-BIG5.st: Set-BIG5.st.in Unicode-BIG5
- ./tables Unicode-BIG5 < Set-BIG5.st.in > $@
+ ./tables $(srcdir)/Unicode-BIG5 < $(srcdir)/Set-BIG5.st.in > $@
Set-GB.st: Set-GB.st.in Unicode-GB
- ./tables Unicode-GB < Set-GB.st.in > $@
+ ./tables $(srcdir)/Unicode-GB < $(srcdir)/Set-GB.st.in > $@
--- old/kernel/Makefile.am Sat Jan 20 08:09:14 2001
+++ new/kernel/Makefile.am Thu Feb 8 22:00:07 2001
@@ -32,6 +32,10 @@
# Build an image after installing the data; install-data runs after
# install-exec, so the gst executable is already in bindir.
-install-data-local:
- cd $(basedir) && $(bindir)/gst -Vi dummyFile
+pwd:=$(shell pwd)
+
+#install-data-local:
+# cd $(basedir) && $(bindir)/gst -Vi dummyFile
+install-data-local: # what is basedir?
+ cd $(IMAGE_PATH) && $(pwd)/../gst -Vi dummyFile
--- old/test/Makefile.am Tue Jan 30 04:26:14 2001
+++ new/test/Makefile.am Fri Feb 9 02:57:25 2001
@@ -1,6 +1,8 @@
-TESTS = $(srcdir)/low-level/low-level
+#TESTS = $(srcdir)/low-level/low-level
## could add $(srcdir)/ansi/ansi
+SUBDIRS = low-level
+
TESTS_ENVIRONMENT = SMALLTALK_KERNEL=$(top_srcdir)/kernel
lowlevel_DIST = \
@@ -21,13 +23,15 @@
ansi/SUnitPreload.st ansi/SUnitTests.st ansi/ansi \
ansi/load-tests.st ansi/run-tests.st
-dist-hook:
- mkdir $(distdir)/low-level
- chmod 777 $(distdir)/low-level
- cp -p $(lowlevel_DIST) $(distdir)/low-level
- mkdir $(distdir)/ansi
- chmod 777 $(distdir)/ansi
- cp -p $(ansi_DIST) $(distdir)/ansi
+EXTRA_DIST = $(lowlevel_DIST) $(ansi_DIST)
+
+#dist-hook:
+# mkdir $(distdir)/low-level
+# chmod 777 $(distdir)/low-level
+# cp -p $(lowlevel_DIST) $(distdir)/low-level
+# mkdir $(distdir)/ansi
+# chmod 777 $(distdir)/ansi
+# cp -p $(ansi_DIST) $(distdir)/ansi
.PHONY: regress
--- old/test/low-level/Makefile.am Wed Dec 31 19:00:00 1969
+++ new/test/low-level/Makefile.am Tue Feb 6 15:06:45 2001
@@ -0,0 +1,26 @@
+
+#SETUP_ENVIRONMENT = env `. $(top_builddir)/BUILD_ENVIRONMENT; sed 's/.*export
\(.*\)/echo \1=$$\1/' < $(top_builddir)/BUILD_ENVIRONMENT | sh`
+
+#TESTS_ENVIRONMENT = $(SETUP_ENVIRONMENT) $(SHELL) TestScript
+TESTS_ENVIRONMENT = $(SHELL) TestScript
+
+TESTS = \
+arrays.st \
+blocks.st \
+chars.st \
+classes.st \
+dates.st \
+delays.st \
+exceptions.st \
+floatmath.st \
+geometry.st \
+intmath.st \
+objects.st \
+processes.st \
+sets.st \
+strings.st
+
+EXTRA_DIST = $(TESTS)
+
+CLEANFILES = *.log *.diff
+
--- old/test/low-level/TestScript.in Wed Dec 31 19:00:00 1969
+++ new/test/low-level/TestScript.in Tue Feb 6 15:03:45 2001
@@ -0,0 +1,24 @@
+: address@hidden@}
+: ${GST=../../gst}
+: ${SMALLTALK_KERNEL="$srcdir/../../kernel/"}
+
+export SMALLTALK_KERNEL
+
+myname () {
+ echo "$1" | sed 's%\..*%%'
+}
+
+base=$(myname $( basename $1) )
+
+$GST -r ${srcdir}/$base.st > $base.log 2>&1
+
+returnval=0
+
+diff ${srcdir}/$base.ok $base.log | tee $base.diff
+if test -s $base.diff; then
+ returnval=1
+else
+ rm -f $base.diff $base.log
+fi
+
+exit $returnval
--- old/unsupported/Makefile.am Wed Jan 17 07:36:46 2001
+++ new/unsupported/Makefile.am Fri Feb 9 17:39:22 2001
@@ -23,7 +23,9 @@
emacs_DIST = emacs/bison.el emacs/st-changelog.el emacs/st-mode.el
-dist-hook:
- d=$(distdir)/cint; mkdir $$d && chmod 777 $$d && cp -p $(cint_DIST) $$d
- d=$(distdir)/misc; mkdir $$d && chmod 777 $$d && cp -p $(misc_DIST) $$d
- d=$(distdir)/emacs; mkdir $$d && chmod 777 $$d && cp -p $(emacs_DIST)
$$d
+EXTRA_DIST = $(cint_DIST) $(misc_DIST) $(emacs_DIST)
+
+#dist-hook:
+# d=$(distdir)/cint; mkdir $$d && chmod 777 $$d && cp -p $(cint_DIST) $$d
+# d=$(distdir)/misc; mkdir $$d && chmod 777 $$d && cp -p $(misc_DIST) $$d
+# d=$(distdir)/emacs; mkdir $$d && chmod 777 $$d && cp -p $(emacs_DIST)
$$d
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Help-smalltalk] Automake suggestions,
H. Nanosecond <=