Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: linked-in modules
- X-seq: zsh-workers 2616
- From: Zoltan Hidvegi <hzoli@xxxxxxxxxx>
- To: zefram@xxxxxxxxxxxxxxxxx (Zefram)
- Subject: Re: linked-in modules
- Date: Mon, 23 Dec 1996 03:51:47 +0100 (MET)
- Cc: zsh-workers@xxxxxxxxxxxxxxx
- In-reply-to: <768.199612221820@xxxxxxxxxxxxxxxxxxxxxxx> from Zefram at "Dec 22, 96 06:20:17 pm"
> This patch makes the linked-in modules mechanism more general. It makes
> it available whether dynamic loading is available or not, the way I
> originally intended it. It also avoids a lot of special-casing in
> the Makefiles, so that the Makefile only needs to know specially about
> modules that have more than one source file (currently only zle).
This Makefile will soon become the most complicated part of zsh. Here
are some more Makefile changes on the top of Zefram's patch. It makes
some rules silent. It cleans up the cleanup rules.
And the biggest change (at least for me): I reworote proto rule to get
parallel make compile zsh without problems (at the university I use a
dual PPro 200, which can compile everything in about 40 seconds this
way).
Zoltan
*** Src/Makefile.in.zefram Mon Dec 23 00:57:19 1996
--- Src/Makefile.in Mon Dec 23 03:42:38 1996
***************
*** 154,160 ****
utils.o watch.o
# dynamically loadable modules
! MODULE_DIRS = Modules Zle
MONULE_DIRS =
LOBJS = main.o
--- 154,160 ----
utils.o watch.o
# dynamically loadable modules
! MODULE_DIRS = $(MODULE_DIR) Zle
MONULE_DIRS =
LOBJS = main.o
***************
*** 186,194 ****
# default target
all: bin modules
! modules: proto $(ANSI@U@KNR) $(MO@D@ULE_DIRS)
! bin: proto zsh
zsh: $(ANSI@U@KNR) $(@L@IBZSH) $(@L@OBJS) $(@L@STMP)
$(LINK) $(@L@OBJS) $(@L@LIST) $(LIBS)
--- 186,194 ----
# default target
all: bin modules
! modules: $(ANSI@U@KNR) $(MO@D@ULE_DIRS)
! bin: zsh
zsh: $(ANSI@U@KNR) $(@L@IBZSH) $(@L@OBJS) $(@L@STMP)
$(LINK) $(@L@OBJS) $(@L@LIST) $(LIBS)
***************
*** 211,223 ****
$(AWK) -f $(srcdir)/rlimits.awk $(RLIMITS_INC_H) > rlimits.h || \
echo WARNING: unknown limits: mail rlimits.h to developers
! $(OBJS): $(HDRS)
init.o: bltinmods.list zshpaths.h
! module.o: zshxmods.h
!
! $(MODULE_DIRS): FORCE
@cd $@ && $(MAKE) $(MAKEDEFS) modules
zshpaths.h: FORCE
--- 211,221 ----
$(AWK) -f $(srcdir)/rlimits.awk $(RLIMITS_INC_H) > rlimits.h || \
echo WARNING: unknown limits: mail rlimits.h to developers
! $(OBJS): proto $(HDRS)
init.o: bltinmods.list zshpaths.h
! $(MODULE_DIRS): $(PROTO) $(HDRS) FORCE
@cd $@ && $(MAKE) $(MAKEDEFS) modules
zshpaths.h: FORCE
***************
*** 236,242 ****
done ) > $@
zshxmods.h: $(MODBINS)
! ( \
modbins=" `cat $(MODBINS)` "; \
for mod in $(XMODS); do \
case $$modbins in \
--- 234,241 ----
done ) > $@
zshxmods.h: $(MODBINS)
! @echo "Creating \`$@'."
! @( \
modbins=" `cat $(MODBINS)` "; \
for mod in $(XMODS); do \
case $$modbins in \
***************
*** 262,271 ****
$(MODBINS):
echo $(@D@YNAMIC_XMODS) > $@
! proto: $(PROTO)
! @for dir in $(MODULE_DIRS); do \
! ( cd $$dir && $(MAKE) $(MAKEDEFS) proto ) || exit 1; \
! done
$(PROTO): makepro.sed
--- 261,267 ----
$(MODBINS):
echo $(@D@YNAMIC_XMODS) > $@
! proto: $(PROTO) proto-recursive FORCE
$(PROTO): makepro.sed
***************
*** 288,294 ****
fi; \
done ;; \
esac; \
- echo Making $${objs}:; \
$(MAKE) $(MAKEDEFS) $$objs || exit 1; \
echo $$objs >> $(NSTMP).tmp; \
for obj in $$objs; do \
--- 284,289 ----
***************
*** 324,359 ****
-if [ -f $(bindir)/zsh ]; then rm -f $(bindir)/zsh; fi
-if [ -f $(bindir)/zsh-$(VERSION) ]; then rm -f $(bindir)/zsh-$(VERSION); fi
! # install modules
! install.modules:
! for dir in $(MO@D@ULE_DIRS); do \
! (cd $$dir && make install.modules); \
! done
!
! # uninstall modules
! uninstall.modules:
! for dir in $(MO@D@ULE_DIRS); do \
! (cd $$dir && make uninstall.modules); \
done
# ========== DEPENDENCIES FOR CLEANUP ==========
! DLCLEAN = $(MODULE_DIR)/*.$(DL_EXT) $(MODULE_DIR)/*.*.[co] $(MODULE_DIR)/*.pro
! NLCLEAN =
! mostlyclean:
! rm -f core stamp-modobjs* *.o $(MODULE_DIR)/*.o *~
!
! clean: mostlyclean
! rm -f zsh ansi2knr $(@D@LCLEAN) signames.h rlimits.h \
! zshpaths.h bltinmods.list zshxmods.h *.*.c *.pro
! distclean: clean
rm -f Makefile
! realclean: distclean
rm -f TAGS tags
! superclean: realclean
# ========== DEPENDENCIES FOR MAINTENANCE ==========
--- 319,358 ----
-if [ -f $(bindir)/zsh ]; then rm -f $(bindir)/zsh; fi
-if [ -f $(bindir)/zsh-$(VERSION) ]; then rm -f $(bindir)/zsh-$(VERSION); fi
! # install/uninstall modules
! install.modules uninstall.modules:
! @for dir in $(MO@D@ULE_DIRS); do \
! (cd $$dir && $(MAKE) $(MAKEDEFS) $@); \
done
# ========== DEPENDENCIES FOR CLEANUP ==========
! mostlyclean: mostlyclean-recursive mostlyclean-src
! clean: clean-recursive clean-src
! distclean: distclean-recursive distclean-src
! realclean: realclean-recursive realclean-src
! superclean: superclean-recursive superclean-src
!
! mostlyclean-src:
! rm -f core stamp-modobjs* *.o
!
! clean-src: mostlyclean-src
! rm -f zsh ansi2knr signames.h rlimits.h zshpaths.h \
! $(MODBINS) bltinmods.list zshxmods.h *.*.c *.pro
! distclean-src: clean-src
rm -f Makefile
! realclean-src: distclean-src
rm -f TAGS tags
! superclean-src: realclean-src
!
! mostlyclean-recursive clean-recursive distclean-recursive realclean-recursive superclean-recursive proto-recursive:
! @for dir in $(MODULE_DIRS); do \
! target=`echo $@ | sed s/-recursive//`; \
! (cd $$dir && $(MAKE) $(MAKEDEFS) $$target) || exit 1; \
! done
# ========== DEPENDENCIES FOR MAINTENANCE ==========
*** Src/Modules/Makefile.in.zefram Mon Dec 23 00:57:20 1996
--- Src/Modules/Makefile.in Mon Dec 23 03:01:56 1996
***************
*** 96,102 ****
# default target
all: modules
! modules: proto $(MODULES)
proto: $(PROTO)
--- 96,104 ----
# default target
all: modules
! modules: $(MODULES)
!
! $(MODULES): proto
proto: $(PROTO)
***************
*** 127,134 ****
# ========== DEPENDENCIES FOR CLEANUP ==========
- DLCLEAN = $(MODULE_DIR)/*.$(DL_EXT) $(MODULE_DIR)/*.*.[co] $(MODULE_DIR)/*.pro
- NLCLEAN =
mostlyclean:
rm -f core stamp-modobjs* *.o *.$(DL_EXT) *~
--- 129,134 ----
*** Src/Zle/Makefile.in.zefram Mon Dec 23 00:57:20 1996
--- Src/Zle/Makefile.in Mon Dec 23 03:01:32 1996
***************
*** 105,116 ****
# default target
all: modules
! modules: proto $(MODULES)
zle.so: $(ZLEOBJS)
$(LINK) $(ZLEOBJS)
! $(OBJS): $(HDRS)
proto: $(PROTO)
--- 105,116 ----
# default target
all: modules
! modules: $(MODULES)
zle.so: $(ZLEOBJS)
$(LINK) $(ZLEOBJS)
! $(OBJS): proto $(HDRS)
proto: $(PROTO)
***************
*** 141,148 ****
# ========== DEPENDENCIES FOR CLEANUP ==========
- DLCLEAN = $(MODULE_DIR)/*.$(DL_EXT) $(MODULE_DIR)/*.*.[co] $(MODULE_DIR)/*.pro
- NLCLEAN =
mostlyclean:
rm -f core stamp-modobjs* *.o *.$(DL_EXT) *~
--- 141,146 ----
Messages sorted by:
Reverse Date,
Date,
Thread,
Author