* Dependencies in leim/Makefile.in
@ 2004-04-26 12:05 Eli Zaretskii
2004-04-29 1:42 ` Kenichi Handa
0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2004-04-26 12:05 UTC (permalink / raw)
[This isn't a new problem, but perhaps it's time to fix it.]
If some of the *.tit files is updated, the corresponding *.elc files
are not re-generated. This is because there are no dependencies in
leim/Makefile.in that tell Make to do that.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Dependencies in leim/Makefile.in
2004-04-26 12:05 Dependencies in leim/Makefile.in Eli Zaretskii
@ 2004-04-29 1:42 ` Kenichi Handa
2004-04-29 5:58 ` Eli Zaretskii
0 siblings, 1 reply; 5+ messages in thread
From: Kenichi Handa @ 2004-04-29 1:42 UTC (permalink / raw)
Cc: emacs-devel
In article <7494-Mon26Apr2004140554+0300-eliz@gnu.org>, "Eli Zaretskii" <eliz@gnu.org> writes:
> [This isn't a new problem, but perhaps it's time to fix it.]
> If some of the *.tit files is updated, the corresponding *.elc files
> are not re-generated. This is because there are no dependencies in
> leim/Makefile.in that tell Make to do that.
For instance, TIT-GB is defined as below.
TIT-GB=\
quail/CCDOSPY.elc \
quail/Punct.elc \
quail/QJ.elc \
quail/SW.elc \
quail/TONEPY.elc
Are there anyway to generate a variable that is equivalent
to this without writing it directly:
TIT-GB-SOURCE=\
CXTERM-DIC/CCDOSPY.tit \
CXTERM-DIC/Punct.tit \
CXTERM-DIC/QJ.tit \
CXTERM-DIC/SW.tit \
CXTERM-DIC/TONEPY.tit
With Gnu make, it seems that we can do:
TIT-GB-SOURCE := $(TIT-GB:quail/%.elc=CXTERM-DIC/%.tit)
But, is such a variable substitution generally available?
---
Ken'ichi HANDA
handa@m17n.org
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Dependencies in leim/Makefile.in
2004-04-29 1:42 ` Kenichi Handa
@ 2004-04-29 5:58 ` Eli Zaretskii
2004-05-01 5:51 ` Kenichi Handa
0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2004-04-29 5:58 UTC (permalink / raw)
Cc: emacs-devel
> Date: Thu, 29 Apr 2004 10:42:02 +0900 (JST)
> From: Kenichi Handa <handa@m17n.org>
>
> TIT-GB=\
> quail/CCDOSPY.elc \
> quail/Punct.elc \
> quail/QJ.elc \
> quail/SW.elc \
> quail/TONEPY.elc
>
> Are there anyway to generate a variable that is equivalent
> to this without writing it directly:
I don't know, but we could ask Paul D. Smith, the GNU Make maintainer.
> With Gnu make, it seems that we can do:
>
> TIT-GB-SOURCE := $(TIT-GB:quail/%.elc=CXTERM-DIC/%.tit)
>
> But, is such a variable substitution generally available?
One idea is to get rid of the prefix directory in the source file
names (CXTERM-DIC in this case), by putting those directories into
VPATH, and then use an implicit dependency ".tit.elc:" and leave it to
Make to find the *.tit files. (Yes, I know that VPATH is also
unavailable in some flavors of Make, but I think it's more widespread
than the feature you used above.)
Even if no general solution is possible, we could use a GNU Make
specific one; that way, at least users of GNU Make will have a better
Makefile.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Dependencies in leim/Makefile.in
2004-04-29 5:58 ` Eli Zaretskii
@ 2004-05-01 5:51 ` Kenichi Handa
0 siblings, 0 replies; 5+ messages in thread
From: Kenichi Handa @ 2004-05-01 5:51 UTC (permalink / raw)
Cc: emacs-devel
In article <ufzanfhqi.fsf@gnu.org>, Eli Zaretskii <eliz@gnu.org> writes:
>> With Gnu make, it seems that we can do:
>>
>> TIT-GB-SOURCE := $(TIT-GB:quail/%.elc=CXTERM-DIC/%.tit)
>>
>> But, is such a variable substitution generally available?
> One idea is to get rid of the prefix directory in the source file
> names (CXTERM-DIC in this case), by putting those directories into
> VPATH, and then use an implicit dependency ".tit.elc:" and leave it to
> Make to find the *.tit files. (Yes, I know that VPATH is also
> unavailable in some flavors of Make, but I think it's more widespread
> than the feature you used above.)
> Even if no general solution is possible, we could use a GNU Make
> specific one; that way, at least users of GNU Make will have a better
> Makefile.
I've just installed the attached fix which takes the
different approach. I gave up generating a list of TIT and
MISC-DIC sources, but could eliminate kludgy code for
avoiding parallel make problems.
I changed only leim/Makefile.in, and tested it only with GNU
Make. I'd like to ask main maintainers of the other systems
to change makefile.nt and makefile.w32-in accordingly (and
test them).
---
Ken'ichi HANDA
handa@m17n.org
Index: Makefile.in
===================================================================
RCS file: /cvsroot/emacs/emacs/leim/Makefile.in,v
retrieving revision 1.58
retrieving revision 1.60
diff -u -c -r1.58 -r1.60
cvs server: conflicting specifications of output style
*** Makefile.in 1 Mar 2004 06:56:32 -0000 1.58
--- Makefile.in 1 May 2004 05:02:57 -0000 1.60
***************
*** 117,129 ****
RUSSIAN=${srcdir}/quail/cyrillic.elc ${srcdir}/quail/cyril-jis.elc
! MISC= \
${srcdir}/quail/ethiopic.elc \
${srcdir}/quail/ipa.elc \
${srcdir}/quail/hebrew.elc \
${srcdir}/quail/georgian.elc
! MISC-DIC=\
quail/tsang-b5.elc \
quail/quick-b5.elc \
quail/tsang-cns.elc \
--- 117,129 ----
RUSSIAN=${srcdir}/quail/cyrillic.elc ${srcdir}/quail/cyril-jis.elc
! OTHERS= \
${srcdir}/quail/ethiopic.elc \
${srcdir}/quail/ipa.elc \
${srcdir}/quail/hebrew.elc \
${srcdir}/quail/georgian.elc
! MISC= \
quail/tsang-b5.elc \
quail/quick-b5.elc \
quail/tsang-cns.elc \
***************
*** 137,153 ****
EASTASIA=${CHINESE} ${JAPANESE} ${KOREAN}
ASIA=${EASTASIA} ${THAI} ${VIETNAMESE} ${LAO} ${INDIAN} ${TIBETAN}
EUROPEAN=${LATIN} ${SLAVIC} ${GREEK} ${RUSSIAN}
! WORLD=${ASIA} ${EUROPEAN} ${MISC} ${MISC-DIC} ${UNICODE}
! TIT=${CHINESE-TIT}
! NON-TIT=${CHINESE-NON-TIT} ${JAPANESE} ${KOREAN} ${EUROPEAN} ${MISC}
.SUFFIXES: .elc .el
.el.elc:
${RUN-EMACS} -f batch-byte-compile $<
! all: ${BUILT-EMACS} ${SUBDIRS} ${WORLD} leim-list.el
# To ensure that we can run Emacs. This target is ignored (never
# being hit) if a user changes default value of EMACS.
--- 137,153 ----
EASTASIA=${CHINESE} ${JAPANESE} ${KOREAN}
ASIA=${EASTASIA} ${THAI} ${VIETNAMESE} ${LAO} ${INDIAN} ${TIBETAN}
EUROPEAN=${LATIN} ${SLAVIC} ${GREEK} ${RUSSIAN}
! WORLD=${ASIA} ${EUROPEAN} ${OTHERS} ${MISC} ${UNICODE}
! TIT-MISC=${CHINESE-TIT} ${MISC}
! NON-TIT-MISC=${CHINESE-NON-TIT} ${JAPANESE} ${KOREAN} ${EUROPEAN} ${OTHERS}
.SUFFIXES: .elc .el
.el.elc:
${RUN-EMACS} -f batch-byte-compile $<
! all: ${BUILT-EMACS} ${SUBDIRS} leim-list.el
# To ensure that we can run Emacs. This target is ignored (never
# being hit) if a user changes default value of EMACS.
***************
*** 158,195 ****
mkdir $@
touch stamp-subdir
! # The rules which generate ${TIT} and ${MISC-DIC} files create them all
! # in one go. So we need to prevent parallel execution for that target,
! # otherwise Emacs complains about files being locked. .NOTPARALLEL is
! # for GNU Make, .NO_PARALLEL is for other Make's.
! .NOTPARALLEL: ${TIT} ${MISC-DIC}
!
! .NO_PARALLEL: ${TIT} ${MISC-DIC}
!
! # Rule to generate quail/*.el from CXTERM-DIC/*.tit.
! # The "if [ -f $@ ]; then true; " part prevents parallel Make's
! # which don't honor .NOTPARALLEL, such as SGI's Make, from running
! # this rule many times, one each for every file it creates.
! ${TIT}:
! if [ -d quail ]; then true; else make quail; fi
! if [ -f $@ ]; then true; else \
! ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
! --eval '(batch-titdic-convert t)' -dir quail ${srcdir}/CXTERM-DIC; fi
! if [ -f $@ ]; then true; else \
! ${RUN-EMACS} -l ${buildlisppath}/international/quail \
! -f batch-byte-compile ${TIT:.elc=.el}; fi
!
! # Rule to generate quail/*.el from MISC-DIC/*.
! ${MISC-DIC}:
! if [ -d quail ]; then true; else make quail; fi
! if [ -f $@ ]; then true; else \
! ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
! -f batch-miscdic-convert -dir quail ${srcdir}/MISC-DIC; fi
! if [ -f $@ ]; then true; else \
! ${RUN-EMACS} -l ${buildlisppath}/international/quail \
! -f batch-byte-compile ${MISC-DIC:.elc=.el}; fi
!
! leim-list.el: ${SUBDIRS} ${WORLD}
if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
${RUN-EMACS} -l ${buildlisppath}/international/quail \
--eval "(update-leim-list-file \".\")" ; \
--- 158,205 ----
mkdir $@
touch stamp-subdir
! TIT-SOURCES= \
! CXTERM-DIC/4Corner.tit \
! CXTERM-DIC/ARRAY30.tit \
! CXTERM-DIC/CCDOSPY.tit \
! CXTERM-DIC/ECDICT.tit \
! CXTERM-DIC/ETZY.tit \
! CXTERM-DIC/PY-b5.tit \
! CXTERM-DIC/Punct-b5.tit \
! CXTERM-DIC/Punct.tit \
! CXTERM-DIC/QJ-b5.tit \
! CXTERM-DIC/QJ.tit \
! CXTERM-DIC/SW.tit \
! CXTERM-DIC/TONEPY.tit \
! CXTERM-DIC/ZOZY.tit
!
! changed.tit: ${TIT-SOURCES}
! echo "0" > $@
!
! MISC-SOURCES= \
! MISC-DIC/CTLau-b5.html \
! MISC-DIC/CTLau.html \
! MISC-DIC/cangjie-table.b5 \
! MISC-DIC/cangjie-table.cns \
! MISC-DIC/pinyin.map \
! MISC-DIC/ziranma.cin
!
! changed.misc: ${MISC-SOURCES}
! echo "0" > $@
!
! leim-list.el: ${SUBDIRS} ${NON-TIT-MISC} changed.tit changed.misc
! if [ `(cat changed.tit)` = 0 ] ; then \
! ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
! -f batch-titdic-convert -dir quail ${srcdir}/CXTERM-DIC; \
! echo "1" > changed.tit; \
! else true; fi
! if [ `(cat changed.misc)` = 0 ] ; then \
! ${RUN-EMACS} -l ${buildlisppath}/international/titdic-cnv \
! -f batch-miscdic-convert -dir quail ${srcdir}/MISC-DIC; \
! echo "1" > changed.misc; \
! else true; fi
! ${RUN-EMACS} -l ${buildlisppath}/international/quail \
! -f batch-byte-compile-if-not-done ${TIT-MISC:.elc=.el}
if [ x`(cd ${srcdir} && /bin/pwd)` = x`(/bin/pwd)` ] ; then \
${RUN-EMACS} -l ${buildlisppath}/international/quail \
--eval "(update-leim-list-file \".\")" ; \
***************
*** 223,230 ****
-chmod -R a+r ${INSTALLDIR}
clean mostlyclean:
! rm -f ${TIT} ${TIT:.elc=.el} ${MISC-DIC} ${MISC-DIC:.elc=.el} \
! leim-list.el
distclean: clean
if test -f stamp-subdir; then rm -rf ${SUBDIRS} stamp-subdir; fi
--- 233,240 ----
-chmod -R a+r ${INSTALLDIR}
clean mostlyclean:
! rm -f ${TIT-MISC} ${TIT-MISC:.elc=.el} \
! leim-list.el changed.tit changed.misc
distclean: clean
if test -f stamp-subdir; then rm -rf ${SUBDIRS} stamp-subdir; fi
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Dependencies in leim/Makefile.in
@ 2004-05-04 1:27 Kenichi Handa
0 siblings, 0 replies; 5+ messages in thread
From: Kenichi Handa @ 2004-05-04 1:27 UTC (permalink / raw)
I wrote:
> I've just installed the attached fix which takes the
> different approach. I gave up generating a list of TIT and
> MISC-DIC sources, but could eliminate kludgy code for
> avoiding parallel make problems.
and someone (sorry, I lost your mail) reported a bug of that
change. I've just installed a fix.
---
Ken'ichi HANDA
handa@m17n.org
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2004-05-04 1:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-26 12:05 Dependencies in leim/Makefile.in Eli Zaretskii
2004-04-29 1:42 ` Kenichi Handa
2004-04-29 5:58 ` Eli Zaretskii
2004-05-01 5:51 ` Kenichi Handa
-- strict thread matches above, loose matches on Subject: below --
2004-05-04 1:27 Kenichi Handa
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.