3 ## Copyright (C) 2007 Steve Youngs.
5 ## This file is part of SXEmacs.
7 ## SXEmacs is free software: you can redistribute it and/or modify it
8 ## under the terms of the GNU General Public License as published by the
9 ## Free Software Foundation, either version 3 of the License, or (at your
10 ## option) any later version.
12 ## SXEmacs is distributed in the hope that it will be
13 ## useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
14 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 ## General Public License for more details.
17 ## You should have received a copy of the GNU General Public License
18 ## along with this program. If not, see <http://www.gnu.org/licenses/>.
20 ## Process this file with automake to produce Makefile.in
22 # Help the Developers and yourself. Just use the C locale and settings
23 # for the compilation. They can still be overriden by make LANG=<whatever>
24 # but that is general a not very good idea
30 top_builddir = @top_builddir@
31 top_srcdir = @top_srcdir@
32 abs_top_builddir = @abs_top_builddir@
33 abs_top_srcdir = @abs_top_srcdir@
35 sxesrcdir = $(top_srcdir)/src
36 bldsrcdir = $(top_builddir)/src
37 sxelispdir = $(abs_top_srcdir)/lisp
38 bldlispdir = $(abs_top_builddir)/lisp
39 bldffidir = $(bldlispdir)/ffi
40 bldmuledir = $(bldlispdir)/mule
41 bldtermdir = $(bldlispdir)/term
42 sxelwlibdir = $(top_srcdir)/src/ui/lwlib
43 bldlwlibdir = $(top_builddir)/src/ui/lwlib
45 lispffidir = $(lispdir)/ffi
46 lispmuledir = $(lispdir)/mule
47 lisptermdir = $(lispdir)/term
49 statlispdir = ${datadir}/${inststaticdir}
50 sxepkgdir = $(statlispdir)/sxemacs-packages
51 xepkgdir = $(statlispdir)/xemacs-packages
52 mulepkgdir = $(statlispdir)/mule-packages
53 sitepkgdir = $(statlispdir)/site-packages
55 ETAGS = $(top_builddir)/lib-src/etags
56 TAGS_DEPENDENCIES = $(ETAGS)
64 subdirs = ffi mule term
66 nocompile_bldchainels = \
67 build-autoloads.el compile-core.el loadup-el.el loadup.el \
68 site-load.el update-elc.el update-elc-2.el very-early-lisp.el
69 compile_bldchainels = \
70 autoload.el dump-paths.el dumped-lisp.el find-paths.el \
71 finder.el make-docfile.el setup-paths.el startup.el
72 bldchainels = $(nocompile_bldchainels) $(compile_bldchainels)
74 abbrev.el about.el alist.el apropos.el auto-save.el \
75 auto-show.el backquote.el blessmail.el buff-menu.el buffer.el \
76 build-rpt.el byte-optimize.el bytecomp-runtime.el bytecomp.el \
77 callers-of-rpt.el cl-compat.el cl-extra.el cl-macs.el cl-seq.el \
78 cl.el cmdloop.el code-cmds.el code-files.el code-process.el \
79 coding.el compat.el config.el console.el cus-dep.el \
80 cus-edit.el cus-face.el cus-file.el cus-load.el cus-start.el \
81 custom.el derived.el device.el dialog-items.el dialog.el \
82 disass.el disp-table.el dragdrop.el easy-mmode.el easymenu.el \
83 emod-utils.el etags.el events.el extents.el faces.el ffi.el \
84 files-nomule.el files.el fill.el float-sup.el font-lock.el \
85 font-menu.el font.el fontl-hooks.el format.el frame.el \
86 glyphs.el gnuserv.el gpm.el gui.el gutter-items.el gutter.el \
87 help-macro.el help-nomule.el help.el hyper-apropos.el indent.el \
88 info.el isearch-mode.el iso8859-1.el issue-tracker.el \
89 itimer-autosave.el itimer.el keydefs.el keymap.el ldap.el \
90 lib-complete.el lisp-initd.el lisp-mnt.el lisp-mode.el lisp.el \
91 list-mode.el loaddefs.el loadhist.el map-ynp.el \
92 menubar-items.el menubar.el minibuf.el misc.el mode-motion.el \
93 modeline.el mouse.el movemail.el multicast.el mwheel.el \
94 number.el objects.el obsolete.el package-admin.el \
95 package-get.el package-info.el package-ui.el packages.el \
96 page.el paragraphs.el paths.el picture.el printer.el \
97 process.el rect.el regexp-opt.el register.el replace.el \
98 resize-minibuffer.el scrollbar.el select.el shadow.el simple.el \
99 sound.el specifier.el subr.el symbol-syntax.el symbols.el \
100 syntax.el text-mode.el text-props.el toolbar-items.el \
101 toolbar.el tty-init.el undo-stack.el userlock.el version.el \
102 view-less.el wid-browse.el wid-edit.el widget.el \
103 window-xemacs.el window.el x-color.el x-compose.el x-faces.el \
104 x-font-menu.el x-init.el x-iso8859-1.el x-misc.el x-mouse.el \
105 x-scrollbar.el x-select.el x-win-sun.el x-win-xfree86.el
108 ffi/ffi-curl.el ffi/ffi-gcrypt.el ffi/ffi-libc.el \
109 ffi/ffi-taglib.el ffi/ffi-wand.el ffi/ffi-magic.el \
110 ffi/ffi-dbus.el ffi/ffi-sqlite.el
112 mule/arabic.el mule/canna-leim.el mule/chinese.el \
113 mule/cyrillic.el mule/english.el mule/ethiopic.el \
114 mule/european.el mule/greek.el mule/hebrew.el mule/japanese.el \
115 mule/kinsoku.el mule/korean.el mule/latin.el mule/misc-lang.el \
116 mule/mule-category.el mule/ccl.el mule/mule-charset.el \
117 mule/mule-cmds.el mule/mule-coding.el mule/mule-help.el \
118 mule/mule-init.el mule/mule-misc.el mule/mule-tty-init.el \
119 mule/mule-x-init.el mule/thai-xtis-chars.el mule/thai-xtis.el \
120 mule/viet-chars.el mule/vietnamese.el
123 term/AT386.el term/apollo.el term/bg-mouse.el term/bobcat.el \
124 term/internal.el term/keyswap.el term/linux.el term/lk201.el \
125 term/news.el term/scoansi.el term/sun-mouse.el term/sun.el \
126 term/sup-mouse.el term/tvi970.el term/vt-control.el \
127 term/vt100-led.el term/vt100.el term/vt102.el term/vt125.el \
128 term/vt200.el term/vt201.el term/vt220.el term/vt240.el \
129 term/vt300.el term/vt320.el term/vt400.el term/vt420.el \
130 term/wyse50.el term/xterm.el
133 auto-autoloads.el custom-load.el finder-inf.el \
137 ffi/auto-autoloads.el ffi/custom-load.el \
138 ffi/custom-defines.el
141 mule/auto-autoloads.el mule/custom-load.el \
142 mule/custom-defines.el
146 builtels += $(ffibuiltels)
149 builtels += $(mulebuiltels)
153 compile_elfiles = $(compile_bldchainels) $(corelispels) $(termlispels)
155 compile_elfiles += $(ffilispels)
158 compile_elfiles += $(mulelispels)
160 elfiles = $(nocompile_elfiles) $(compile_elfiles)
162 nobase_dist_lisp_DATA = $(elfiles)
163 nobase_lisp_DATA = $(builtels) $(elfiles:.el=.elc) $(builtels:.el=.elc)
164 noinst_DATA = auto.stamp update-elc.stamp autoc.stamp
166 EXTRA_DIST = $(nocompile_bldchainels) $(compile_bldchainels)
168 BUILT_FILES = auto.stamp update-elc.stamp autoc.stamp
170 CLEANFILES = core* stage1 stage2 $(builtels) $(builtels:.el=.elc) \
171 $(lisphier:=/*.el[c~]) *.stamp ffi/$(builtels) \
172 ffi/$(builtels:.el=.elc) \
173 mule/$(builtels) mule/$(builtels:.el=.elc) \
177 SXEMACS = $(bldsrcdir)/sxemacs
178 SXEMACS_DMP = $(SXEMACS).dmp
179 AALFILE = $(bldlispdir)/auto-autoloads.el
180 BITCH = $(SXEMACS) -batch
181 SXE_DYLD_PATH = $(bldsrcdir):$(bldsrcdir)/$(LT_OBJDIR):$(bldlwlibdir):$(bldlwlibdir)/$(LT_OBJDIR):$(DESTDIR)$(libdir)
182 BATCHENV = DYLD_LIBRARY_PATH=$(SXE_DYLD_PATH):$$DYLD_LIBRARY_PATH:$(DYLD_LIBRARY_PATH) \
183 LD_LIBRARY_PATH=$(SXE_DYLD_PATH):$$LD_LIBRARY_PATH:$(LD_LIBRARY_PATH) \
184 SHLIB_PATH=$(SXE_DYLD_PATH):$$SHLIB_PATH:$(SHLIB_PATH)
185 BITCHENV = $(BATCHENV) \
187 SOURCE_TREE_ROOT=$(abs_top_srcdir) \
188 BUILD_TREE_ROOT=$(abs_top_builddir)
189 BATCH = $(BITCHENV) $(BITCH)
190 PUREBATCH = $(BATCH) -nd
201 stamps = bldchn.stamp core.stamp term.stamp
210 TAGS: $(compile_elfiles) $(TAGS_DEPENDENCIES)
211 for i in $(compile_elfiles); do unique="$$unique ${srcdir}/$$i"; done; \
214 bldchn.stamp: $(SXEMACS) $(compile_bldchainels) auto.stamp
215 $(PUREBATCH) -l compile-core.el $(compile_bldchainels)
218 core.stamp: $(SXEMACS) $(corelispels) auto.stamp
219 $(PUREBATCH) -l compile-core.el $(corelispels)
222 ffi.stamp: $(SXEMACS) $(ffilispels) auto.stamp
223 $(PUREBATCH) -l compile-core.el $(ffilispels)
226 mule.stamp: $(SXEMACS) $(mulelispels) auto.stamp
227 $(PUREBATCH) -l compile-core.el $(mulelispels)
230 term.stamp: $(SXEMACS) $(termlispels) auto.stamp
231 $(PUREBATCH) -l compile-core.el $(termlispels)
234 autoc.stamp: $(SXEMACS) auto.stamp update-elc.stamp
235 @make_ifeq@ (yes,$(shell test -e $(bldsrcdir)/sxemacs.dmp && echo "yes"))
236 @echo "Building finder database ..."
237 $(BATCH) -vanilla -no-autoloads \
238 -l finder -f finder-compile-keywords
239 @echo "Building finder database ...(done)"
240 $(BATCHENV) $(BITCH) -no-autoloads -l config \
241 -l bytecomp -f batch-byte-compile $(builtels)
245 $(builtels): auto.stamp
246 $(builtels:.el=.elc): autoc.stamp
247 $(elfiles:.el=.elc): update-elc.stamp
249 update-elc.stamp: $(SXEMACS) $(compile_elfiles) auto.stamp $(stamps)
252 auto.stamp: $(SXEMACS) $(compile_elfiles)
253 for i in $(lisphier); do mkdir -p $$i; done
254 $(PUREBATCH) -l build-autoloads.el
258 #.el.elc: $(SXEMACS) $(SXEMACS_DMP) auto.stamp update-elc.stamp
259 # $(BATCH) -l bytecomp -f batch-byte-compile-one-file-here $<
261 #stage1: auto-autoloads.el
264 #stage2: stage1 ##$(builtels)