diff --git a/configure.ac b/configure.ac index f5370bd..060d3f9 100644 --- a/configure.ac +++ b/configure.ac @@ -57,6 +57,7 @@ AC_OUTPUT([ doc/Makefile examples/Makefile lib/Makefile + lib/misc/Makefile scm/Makefile scripts/Makefile src/Makefile diff --git a/lib/Makefile.am b/lib/Makefile.am index e69de29..cbdaf3b 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -0,0 +1 @@ +SUBDIRS = misc unix xaw xlib xm xt diff --git a/lib/misc/Makefile b/lib/misc/Makefile deleted file mode 100644 index 29e6f57..0000000 --- a/lib/misc/Makefile +++ /dev/null @@ -1,24 +0,0 @@ -SHELL=/bin/sh -MAKE=make - -all: default - -Makefile.local: build ../../config/system ../../config/site - $(SHELL) ./build - -default: Makefile.local - $(MAKE) -f Makefile.local - -install: Makefile.local - $(MAKE) -f Makefile.local install - -localize: Makefile.local - -lint: Makefile.local - $(MAKE) -f Makefile.local lint - -clean: Makefile.local - $(MAKE) -f Makefile.local clean - -distclean: Makefile.local - $(MAKE) -f Makefile.local distclean diff --git a/lib/misc/Makefile.am b/lib/misc/Makefile.am new file mode 100644 index 0000000..d7ef723 --- /dev/null +++ b/lib/misc/Makefile.am @@ -0,0 +1,46 @@ +NULL = + +libelk_LTLIBRARIES = \ + libbitstring.la \ + libelk-eval.la \ + libhack.la \ + libnewhandler.la \ + libregexp.la \ + libdebug.la \ + libgdbm.la \ + libmonitor.la \ + librecord.la \ + libstruct.la \ + $(NULL) +libelkdir = /usr/lib/elk + +libbitstring_la_SOURCES = bitstring.c +libbitstring_la_LIBADD = $(top_builddir)/src/libelk.la + +libelk_eval_la_SOURCES = elk-eval.c +libelk_eval_la_LIBADD = $(top_builddir)/src/libelk.la + +libhack_la_SOURCES = hack.c +libhack_la_LIBADD = $(top_builddir)/src/libelk.la + +libnewhandler_la_SOURCES = newhandler.c +libnewhandler_la_LIBADD = $(top_builddir)/src/libelk.la + +libregexp_la_SOURCES = regexp.c +libregexp_la_LIBADD = $(top_builddir)/src/libelk.la + +libdebug_la_SOURCES = debug.c +libdebug_la_LIBADD = $(top_builddir)/src/libelk.la + +libgdbm_la_SOURCES = gdbm.c +libgdbm_la_LIBADD = $(top_builddir)/src/libelk.la -lgdbm + +libmonitor_la_SOURCES = monitor.c +libmonitor_la_LIBADD = $(top_builddir)/src/libelk.la + +librecord_la_SOURCES = record.c +librecord_la_LIBADD = $(top_builddir)/src/libelk.la + +libstruct_la_SOURCES = struct.c +libstruct_la_LIBADD = $(top_builddir)/src/libelk.la + diff --git a/lib/misc/build b/lib/misc/build deleted file mode 100755 index 1e30dca..0000000 --- a/lib/misc/build +++ /dev/null @@ -1,137 +0,0 @@ -. ../../config/system -. ../../config/site - -if [ _$gdbm = _yes ]; then - gdbm_c="gdbm.c" - gdbm_o="gdbm.o" - gdbm_so="gdbm.so" -else - gdbm_incl= -fi - -echo Building Makefile.local... -cat <Makefile.local -# This Makefile was produced by running ./build in this directory. - -SHELL=/bin/sh - -CC= ${cc-cc} -CFLAGS= $cflags $obj_cflags -LINTFLAGS= $lintflags - -INC= ../../include - -H= \$(INC)/compat.h\\ - \$(INC)/config.h\\ - \$(INC)/cstring.h\\ - \$(INC)/exception.h\\ - \$(INC)/extern.h\\ - \$(INC)/funcproto.h\\ - \$(INC)/gc.h\\ - \$(INC)/misc.h\\ - \$(INC)/object.h\\ - \$(INC)/param.h\\ - \$(INC)/stkmem.h\\ - \$(INC)/type.h - -C= bitstring.c\\ - debug.c\\ - elk-eval.c\\ - hack.c\\ - monitor.c\\ - newhandler.c\\ - record.c\\ - regexp.c\\ - struct.c $gdbm_c - -O= bitstring.o\\ - debug.o\\ - elk-eval.o\\ - hack.o\\ - monitor.o\\ - newhandler.o\\ - record.o\\ - regexp.o\\ - struct.o $gdbm_o - -SO= bitstring.so\\ - debug.so\\ - elk-eval.so\\ - hack.so\\ - monitor.so\\ - newhandler.so\\ - record.so\\ - regexp.so\\ - struct.so $gdbm_so - -.c.o: - \$(CC) \$(CFLAGS) -I\$(INC) $gdbm_incl -c \$< - ../../scripts/makedl \$@ \$@ - -all: \$(SO) - -bitstring.o: \$(H) bitstring.c -debug.o: \$(H) debug.c -elk-eval.o: \$(H) elk-eval.c -hack.o: \$(H) hack.c -monitor.o: \$(H) monitor.c -newhandler.o: \$(H) newhandler.c -record.o: \$(H) record.c -regexp.o: \$(H) regexp.c -struct.o: \$(H) struct.c -gdbm.o: \$(H) gdbm.c - -bitstring.so: bitstring.o - gcc -shared -o \$@ \$< -lc - -debug.so: debug.o - gcc -shared -o \$@ \$< -lc - -elk-eval.so: elk-eval.o - gcc -shared -o \$@ \$< -lc - -hack.so: hack.o - gcc -shared -o \$@ \$< -lc - -monitor.so: monitor.o - gcc -shared -o \$@ \$< -lc - -newhandler.so: newhandler.o - gcc -shared -o \$@ \$< -lc - -record.so: record.o - gcc -shared -o \$@ \$< -lc - -regexp.so: regexp.o - gcc -shared -o \$@ \$< -lc - -struct.so: struct.o - gcc -shared -o \$@ \$< -lc - -gdbm.so: gdbm.o - gcc -shared -o \$@ \$< -lgdbm -lc - -install: \$(SO) - -@if [ ! -d $install_dir/lib ]; then \\ - echo mkdir $install_dir/lib; \\ - mkdir $install_dir/lib; \\ - fi - -@if [ ! -d $install_dir/lib/elk ]; then \\ - echo mkdir $install_dir/lib/elk; \\ - mkdir $install_dir/lib/elk; \\ - fi - @for i in \$(SO) ;\\ - do \\ - echo cp \$\$i $install_dir/lib/elk; \\ - cp \$\$i $install_dir/lib/elk; \\ - done - -lint: - lint \$(LINTFLAGS) -I\$(INC) $gdbm_incl \$(C) - -clean: - rm -f *.so *.o core - -distclean: - rm -f *.so *.o core lint.out Makefile.local -EOT diff --git a/src/Makefile.am b/src/Makefile.am index bc914b2..743babb 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -41,6 +41,6 @@ libelk_la_SOURCES = \ $(NULL) bin_PROGRAMS = elk -elk_LDADD = libelk.la +elk_LDADD = $(top_builddir)/src/libelk.la elk_SOURCES = main.c