direct-io.hg

view xenolinux-2.4.16-sparse/Makefile @ 204:0e45b167992d

bitkeeper revision 1.65 (3e536858YdNPGFSv3J35Fl8zAGLJjQ)

sched.h, xen_block.c, domain.c:
Now have per-domain IO completion queue.
author kaf24@labyrinth.cl.cam.ac.uk
date Wed Feb 19 11:19:52 2003 +0000 (2003-02-19)
parents 243ed70f18a7
children 4e2e24ecaab0
line source
1 VERSION = 2
2 PATCHLEVEL = 4
3 SUBLEVEL = 16
4 EXTRAVERSION = -kdb-xeno
6 KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)
8 HW_ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/)
9 ifndef ARCH
10 ARCH := $(HW_ARCH)
11 endif
13 ARCH=xeno
15 KERNELPATH=kernel-$(shell echo $(KERNELRELEASE) | sed -e "s/-//")
17 CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
18 else if [ -x /bin/bash ]; then echo /bin/bash; \
19 else echo sh; fi ; fi)
20 TOPDIR := $(shell /bin/pwd)
22 HPATH = $(TOPDIR)/include
23 FINDHPATH = $(HPATH)/asm $(HPATH)/linux $(HPATH)/scsi $(HPATH)/net
25 HOSTCC = gcc
26 HOSTCFLAGS = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer
28 CROSS_COMPILE =
30 #
31 # Include the make variables (CC, etc...)
32 #
34 AS = $(CROSS_COMPILE)as
35 LD = $(CROSS_COMPILE)ld
36 CC = $(CROSS_COMPILE)gcc
37 CPP = $(CC) -E
38 AR = $(CROSS_COMPILE)ar
39 NM = $(CROSS_COMPILE)nm
40 STRIP = $(CROSS_COMPILE)strip
41 OBJCOPY = $(CROSS_COMPILE)objcopy
42 OBJDUMP = $(CROSS_COMPILE)objdump
43 MAKEFILES = $(TOPDIR)/.config
44 GENKSYMS = /sbin/genksyms
45 DEPMOD = /sbin/depmod
46 KALLSYMS = /sbin/kallsyms
47 MODFLAGS = -DMODULE
48 CFLAGS_KERNEL =
49 PERL = perl
50 AWK = awk
51 TMPPREFIX =
53 export VERSION PATCHLEVEL SUBLEVEL EXTRAVERSION KERNELRELEASE ARCH \
54 CONFIG_SHELL TOPDIR HPATH HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC \
55 CPP AR NM STRIP OBJCOPY OBJDUMP MAKE MAKEFILES GENKSYMS MODFLAGS PERL AWK
57 all: do-it-all
59 #
60 # Make "config" the default target if there is no configuration file or
61 # "depend" the target if there is no top-level dependency information.
62 #
64 ifeq (.config,$(wildcard .config))
65 include .config
66 ifeq (.depend,$(wildcard .depend))
67 include .depend
68 do-it-all: Version vmlinux
69 else
70 CONFIGURATION = depend
71 do-it-all: depend
72 endif
73 else
74 CONFIGURATION = config
75 do-it-all: config
76 endif
78 #
79 # INSTALL_PATH specifies where to place the updated kernel and system map
80 # images. Uncomment if you want to place them anywhere other than root.
81 #
83 #export INSTALL_PATH=/boot
85 #
86 # INSTALL_MOD_PATH specifies a prefix to MODLIB for module directory
87 # relocations required by build roots. This is not defined in the
88 # makefile but the arguement can be passed to make if needed.
89 #
91 MODLIB := $(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE)
92 export MODLIB
94 #
95 # standard CFLAGS
96 #
98 CPPFLAGS := -D__KERNEL__ -I$(HPATH)
99 CPPFLAGS += $(patsubst %,-I%,$(CROSS_COMPILE_INC))
101 CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
102 -fno-strict-aliasing -fno-common
103 ifndef CONFIG_FRAME_POINTER
104 CFLAGS += -fomit-frame-pointer
105 endif
106 AFLAGS := -D__ASSEMBLY__ $(CPPFLAGS)
108 #
109 # ROOT_DEV specifies the default root-device when making the image.
110 # This can be either FLOPPY, CURRENT, /dev/xxxx or empty, in which case
111 # the default of FLOPPY is used by 'build'.
112 # This is i386 specific.
113 #
115 export ROOT_DEV = CURRENT
117 #
118 # If you want to preset the SVGA mode, uncomment the next line and
119 # set SVGA_MODE to whatever number you want.
120 # Set it to -DSVGA_MODE=NORMAL_VGA if you just want the EGA/VGA mode.
121 # The number is the same as you would ordinarily press at bootup.
122 # This is i386 specific.
123 #
125 export SVGA_MODE = -DSVGA_MODE=NORMAL_VGA
127 #
128 # If you want the RAM disk device, define this to be the size in blocks.
129 # This is i386 specific.
130 #
132 #export RAMDISK = -DRAMDISK=512
134 CORE_FILES =kernel/kernel.o mm/mm.o fs/fs.o ipc/ipc.o
135 NETWORKS =net/network.o
137 LIBS =$(TOPDIR)/lib/lib.a
138 SUBDIRS =kernel drivers mm fs net ipc lib
140 ifeq ($(CONFIG_KDB),y)
141 CORE_FILES += kdb/kdb.o
142 SUBDIRS += kdb
143 endif
145 DRIVERS-n :=
146 DRIVERS-y :=
147 DRIVERS-m :=
148 DRIVERS- :=
150 DRIVERS-$(CONFIG_ACPI) += drivers/acpi/acpi.o
151 DRIVERS-$(CONFIG_PARPORT) += drivers/parport/driver.o
152 DRIVERS-y += drivers/char/char.o \
153 drivers/block/block.o \
154 drivers/misc/misc.o \
155 drivers/net/net.o \
156 drivers/media/media.o
157 DRIVERS-$(CONFIG_AGP) += drivers/char/agp/agp.o
158 DRIVERS-$(CONFIG_DRM) += drivers/char/drm/drm.o
159 DRIVERS-$(CONFIG_NUBUS) += drivers/nubus/nubus.a
160 DRIVERS-$(CONFIG_ISDN) += drivers/isdn/isdn.a
161 DRIVERS-$(CONFIG_NET_FC) += drivers/net/fc/fc.o
162 DRIVERS-$(CONFIG_APPLETALK) += drivers/net/appletalk/appletalk.o
163 DRIVERS-$(CONFIG_TR) += drivers/net/tokenring/tr.o
164 DRIVERS-$(CONFIG_WAN) += drivers/net/wan/wan.o
165 DRIVERS-$(CONFIG_ARCNET) += drivers/net/arcnet/arcnetdrv.o
166 DRIVERS-$(CONFIG_ATM) += drivers/atm/atm.o
167 DRIVERS-$(CONFIG_IDE) += drivers/ide/idedriver.o
168 DRIVERS-$(CONFIG_FC4) += drivers/fc4/fc4.a
169 DRIVERS-$(CONFIG_SCSI) += drivers/scsi/scsidrv.o
170 DRIVERS-$(CONFIG_FUSION_BOOT) += drivers/message/fusion/fusion.o
171 DRIVERS-$(CONFIG_IEEE1394) += drivers/ieee1394/ieee1394drv.o
173 ifneq ($(CONFIG_CD_NO_IDESCSI)$(CONFIG_BLK_DEV_IDECD)$(CONFIG_BLK_DEV_SR)$(CONFIG_PARIDE_PCD),)
174 DRIVERS-y += drivers/cdrom/driver.o
175 endif
177 DRIVERS-$(CONFIG_SOUND) += drivers/sound/sounddrivers.o
178 DRIVERS-$(CONFIG_PCI) += drivers/pci/driver.o
179 DRIVERS-$(CONFIG_MTD) += drivers/mtd/mtdlink.o
180 DRIVERS-$(CONFIG_PCMCIA) += drivers/pcmcia/pcmcia.o
181 DRIVERS-$(CONFIG_NET_PCMCIA) += drivers/net/pcmcia/pcmcia_net.o
182 DRIVERS-$(CONFIG_NET_WIRELESS) += drivers/net/wireless/wireless_net.o
183 DRIVERS-$(CONFIG_PCMCIA_CHRDEV) += drivers/char/pcmcia/pcmcia_char.o
184 DRIVERS-$(CONFIG_DIO) += drivers/dio/dio.a
185 DRIVERS-$(CONFIG_SBUS) += drivers/sbus/sbus_all.o
186 DRIVERS-$(CONFIG_ZORRO) += drivers/zorro/driver.o
187 DRIVERS-$(CONFIG_FC4) += drivers/fc4/fc4.a
188 DRIVERS-$(CONFIG_ALL_PPC) += drivers/macintosh/macintosh.o
189 DRIVERS-$(CONFIG_MAC) += drivers/macintosh/macintosh.o
190 DRIVERS-$(CONFIG_ISAPNP) += drivers/pnp/pnp.o
191 DRIVERS-$(CONFIG_SGI_IP22) += drivers/sgi/sgi.a
192 DRIVERS-$(CONFIG_VT) += drivers/video/video.o
193 DRIVERS-$(CONFIG_PARIDE) += drivers/block/paride/paride.a
194 DRIVERS-$(CONFIG_HAMRADIO) += drivers/net/hamradio/hamradio.o
195 DRIVERS-$(CONFIG_TC) += drivers/tc/tc.a
196 DRIVERS-$(CONFIG_USB) += drivers/usb/usbdrv.o
197 DRIVERS-$(CONFIG_INPUT) += drivers/input/inputdrv.o
198 DRIVERS-$(CONFIG_I2O) += drivers/message/i2o/i2o.o
199 DRIVERS-$(CONFIG_IRDA) += drivers/net/irda/irda.o
200 DRIVERS-$(CONFIG_I2C) += drivers/i2c/i2c.o
201 DRIVERS-$(CONFIG_PHONE) += drivers/telephony/telephony.o
202 DRIVERS-$(CONFIG_MD) += drivers/md/mddev.o
203 DRIVERS-$(CONFIG_BLUEZ) += drivers/bluetooth/bluetooth.o
204 DRIVERS-$(CONFIG_HOTPLUG_PCI) += drivers/hotplug/vmlinux-obj.o
206 DRIVERS := $(DRIVERS-y)
209 # files removed with 'make clean'
210 CLEAN_FILES = \
211 kernel/ksyms.lst include/linux/compile.h \
212 vmlinux System.map \
213 $(TMPPREFIX).tmp* \
214 drivers/char/consolemap_deftbl.c drivers/video/promcon_tbl.c \
215 drivers/char/conmakehash \
216 drivers/char/drm/*-mod.c \
217 drivers/pci/devlist.h drivers/pci/classlist.h drivers/pci/gen-devlist \
218 drivers/zorro/devlist.h drivers/zorro/gen-devlist \
219 drivers/sound/bin2hex drivers/sound/hex2hex \
220 drivers/atm/fore200e_mkfirm drivers/atm/{pca,sba}*{.bin,.bin1,.bin2} \
221 drivers/scsi/aic7xxx/aicasm/aicasm_gram.c \
222 drivers/scsi/aic7xxx/aicasm/aicasm_scan.c \
223 drivers/scsi/aic7xxx/aicasm/y.tab.h \
224 drivers/scsi/aic7xxx/aicasm/aicasm \
225 drivers/scsi/53c700-mem.c \
226 net/khttpd/make_times_h \
227 net/khttpd/times.h \
228 submenu*
229 # directories removed with 'make clean'
230 CLEAN_DIRS = \
231 modules
233 # files removed with 'make mrproper'
234 MRPROPER_FILES = \
235 include/linux/autoconf.h include/linux/version.h \
236 drivers/net/hamradio/soundmodem/sm_tbl_{afsk1200,afsk2666,fsk9600}.h \
237 drivers/net/hamradio/soundmodem/sm_tbl_{hapn4800,psk4800}.h \
238 drivers/net/hamradio/soundmodem/sm_tbl_{afsk2400_7,afsk2400_8}.h \
239 drivers/net/hamradio/soundmodem/gentbl \
240 drivers/sound/*_boot.h drivers/sound/.*.boot \
241 drivers/sound/msndinit.c \
242 drivers/sound/msndperm.c \
243 drivers/sound/pndsperm.c \
244 drivers/sound/pndspini.c \
245 drivers/atm/fore200e_*_fw.c drivers/atm/.fore200e_*.fw \
246 .version .config* config.in config.old \
247 scripts/tkparse scripts/kconfig.tk scripts/kconfig.tmp \
248 scripts/lxdialog/*.o scripts/lxdialog/lxdialog \
249 .menuconfig.log \
250 include/asm \
251 kdb/gen-kdb_cmds.c \
252 .hdepend scripts/mkdep scripts/split-include scripts/docproc \
253 $(TOPDIR)/include/linux/modversions.h \
254 kernel.spec
256 # directories removed with 'make mrproper'
257 MRPROPER_DIRS = \
258 include/config \
259 $(TOPDIR)/include/linux/modules
262 include arch/$(ARCH)/Makefile
264 export CPPFLAGS CFLAGS CFLAGS_KERNEL AFLAGS AFLAGS_KERNEL
266 export NETWORKS DRIVERS LIBS HEAD LDFLAGS LINKFLAGS MAKEBOOT ASFLAGS
268 .S.s:
269 $(CPP) $(AFLAGS) $(AFLAGS_KERNEL) -traditional -o $*.s $<
270 .S.o:
271 $(CC) $(AFLAGS) $(AFLAGS_KERNEL) -traditional -c -o $*.o $<
273 Version: dummy
274 @rm -f include/linux/compile.h
276 boot: vmlinux
277 @$(MAKE) CFLAGS="$(CFLAGS) $(CFLAGS_KERNEL)" -C arch/$(ARCH)/boot
279 LD_VMLINUX := $(LD) $(LINKFLAGS) $(HEAD) init/main.o init/version.o \
280 --start-group \
281 $(CORE_FILES) \
282 $(DRIVERS) \
283 $(NETWORKS) \
284 $(LIBS) \
285 --end-group
286 ifeq ($(CONFIG_KALLSYMS),y)
287 LD_VMLINUX_KALLSYMS := $(TMPPREFIX).tmp_kallsyms3.o
288 else
289 LD_VMLINUX_KALLSYMS :=
290 endif
292 vmlinux: include/linux/version.h $(CONFIGURATION) init/main.o init/version.o linuxsubdirs
293 @$(MAKE) CFLAGS="$(CFLAGS) $(CFLAGS_KERNEL)" kallsyms
295 .PHONY: kallsyms
297 kallsyms:
298 ifeq ($(CONFIG_KALLSYMS),y)
299 @echo kallsyms pass 1
300 $(LD_VMLINUX) -o $(TMPPREFIX).tmp_vmlinux1
301 @$(KALLSYMS) $(TMPPREFIX).tmp_vmlinux1 > $(TMPPREFIX).tmp_kallsyms1.o
302 @echo kallsyms pass 2
303 @$(LD_VMLINUX) $(TMPPREFIX).tmp_kallsyms1.o -o $(TMPPREFIX).tmp_vmlinux2
304 @$(KALLSYMS) $(TMPPREFIX).tmp_vmlinux2 > $(TMPPREFIX).tmp_kallsyms2.o
305 @echo kallsyms pass 3
306 @$(LD_VMLINUX) $(TMPPREFIX).tmp_kallsyms2.o -o $(TMPPREFIX).tmp_vmlinux3
307 @$(KALLSYMS) $(TMPPREFIX).tmp_vmlinux3 > $(TMPPREFIX).tmp_kallsyms3.o
308 endif
309 $(LD_VMLINUX) $(LD_VMLINUX_KALLSYMS) -o $(TMPPREFIX)vmlinux
310 ifneq ($(TMPPREFIX),)
311 mv $(TMPPREFIX)vmlinux vmlinux
312 endif
313 $(NM) vmlinux | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map
314 @rm -f $(TMPPREFIX).tmp_vmlinux* $(TMPPREFIX).tmp_kallsyms*
316 symlinks:
317 rm -f include/asm
318 ( cd include ; ln -sf asm-$(ARCH) asm)
319 @if [ ! -d include/linux/modules ]; then \
320 mkdir include/linux/modules; \
321 fi
323 oldconfig: symlinks
324 $(CONFIG_SHELL) scripts/Configure -d arch/$(ARCH)/config.in
326 xconfig: symlinks
327 $(MAKE) -C scripts kconfig.tk
328 wish -f scripts/kconfig.tk
330 menuconfig: include/linux/version.h symlinks
331 $(MAKE) -C scripts/lxdialog all
332 $(CONFIG_SHELL) scripts/Menuconfig arch/$(ARCH)/config.in
334 config: symlinks
335 $(CONFIG_SHELL) scripts/Configure arch/$(ARCH)/config.in
337 include/config/MARKER: scripts/split-include include/linux/autoconf.h
338 scripts/split-include include/linux/autoconf.h include/config
339 @ touch include/config/MARKER
341 linuxsubdirs: $(patsubst %, _dir_%, $(SUBDIRS))
343 $(patsubst %, _dir_%, $(SUBDIRS)) : dummy include/linux/version.h include/config/MARKER
344 $(MAKE) CFLAGS="$(CFLAGS) $(CFLAGS_KERNEL)" -C $(patsubst _dir_%, %, $@)
346 $(TOPDIR)/include/linux/version.h: include/linux/version.h
347 $(TOPDIR)/include/linux/compile.h: include/linux/compile.h
349 newversion:
350 . scripts/mkversion > .tmpversion
351 @mv -f .tmpversion .version
353 include/linux/compile.h: $(CONFIGURATION) include/linux/version.h newversion
354 @echo -n \#define UTS_VERSION \"\#`cat .version` > .ver
355 @if [ -n "$(CONFIG_SMP)" ] ; then echo -n " SMP" >> .ver; fi
356 @if [ -f .name ]; then echo -n \-`cat .name` >> .ver; fi
357 @echo ' '`date`'"' >> .ver
358 @echo \#define LINUX_COMPILE_TIME \"`date +%T`\" >> .ver
359 @echo \#define LINUX_COMPILE_BY \"`whoami`\" >> .ver
360 @echo \#define LINUX_COMPILE_HOST \"`hostname`\" >> .ver
361 @if [ -x /bin/dnsdomainname ]; then \
362 echo \#define LINUX_COMPILE_DOMAIN \"`dnsdomainname`\"; \
363 elif [ -x /bin/domainname ]; then \
364 echo \#define LINUX_COMPILE_DOMAIN \"`domainname`\"; \
365 else \
366 echo \#define LINUX_COMPILE_DOMAIN ; \
367 fi >> .ver
368 @echo \#define LINUX_COMPILER \"`$(CC) $(CFLAGS) -v 2>&1 | tail -1`\" >> .ver
369 @mv -f .ver $@
371 include/linux/version.h: ./Makefile
372 @echo \#define UTS_RELEASE \"$(KERNELRELEASE)\" > .ver
373 @echo \#define LINUX_VERSION_CODE `expr $(VERSION) \\* 65536 + $(PATCHLEVEL) \\* 256 + $(SUBLEVEL)` >> .ver
374 @echo '#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))' >>.ver
375 @mv -f .ver $@
377 init/version.o: init/version.c include/linux/compile.h include/config/MARKER
378 $(CC) $(CFLAGS) $(CFLAGS_KERNEL) -DUTS_MACHINE='"$(HW_ARCH)"' -c -o init/version.o init/version.c
380 init/main.o: init/main.c include/config/MARKER
381 $(CC) $(CFLAGS) $(CFLAGS_KERNEL) $(PROFILING) -c -o $*.o $<
383 fs lib mm ipc kernel drivers net: dummy
384 $(MAKE) CFLAGS="$(CFLAGS) $(CFLAGS_KERNEL)" $(subst $@, _dir_$@, $@)
386 TAGS: dummy
387 etags `find include/asm-$(ARCH) -name '*.h'`
388 find include -type d \( -name "asm-*" -o -name config \) -prune -o -name '*.h' -print | xargs etags -a
389 find $(SUBDIRS) init -name '*.[ch]' | xargs etags -a
391 # Exuberant ctags works better with -I
392 tags: dummy
393 CTAGSF=`ctags --version | grep -i exuberant >/dev/null && echo "-I __initdata,__exitdata,EXPORT_SYMBOL,EXPORT_SYMBOL_NOVERS"`; \
394 ctags $$CTAGSF `find include/asm-$(ARCH) -name '*.h'` && \
395 find include -type d \( -name "asm-*" -o -name config \) -prune -o -name '*.h' -print | xargs ctags $$CTAGSF -a && \
396 find $(SUBDIRS) init -name '*.[ch]' | xargs ctags $$CTAGSF -a
398 ifdef CONFIG_MODULES
399 ifdef CONFIG_MODVERSIONS
400 MODFLAGS += -DMODVERSIONS -include $(HPATH)/linux/modversions.h
401 endif
403 .PHONY: modules
404 modules: $(patsubst %, _mod_%, $(SUBDIRS))
406 .PHONY: $(patsubst %, _mod_%, $(SUBDIRS))
407 $(patsubst %, _mod_%, $(SUBDIRS)) : include/linux/version.h include/config/MARKER
408 $(MAKE) -C $(patsubst _mod_%, %, $@) CFLAGS="$(CFLAGS) $(MODFLAGS)" MAKING_MODULES=1 modules
410 .PHONY: modules_install
411 modules_install: _modinst_ $(patsubst %, _modinst_%, $(SUBDIRS)) _modinst_post
413 .PHONY: _modinst_
414 _modinst_:
415 @rm -rf $(MODLIB)/kernel
416 @rm -f $(MODLIB)/build
417 @mkdir -p $(MODLIB)/kernel
418 @ln -s $(TOPDIR) $(MODLIB)/build
420 # If System.map exists, run depmod. This deliberately does not have a
421 # dependency on System.map since that would run the dependency tree on
422 # vmlinux. This depmod is only for convenience to give the initial
423 # boot a modules.dep even before / is mounted read-write. However the
424 # boot script depmod is the master version.
425 ifeq "$(strip $(INSTALL_MOD_PATH))" ""
426 depmod_opts :=
427 else
428 depmod_opts := -b $(INSTALL_MOD_PATH) -r
429 endif
430 .PHONY: _modinst_post
431 _modinst_post: _modinst_post_pcmcia
432 # if [ -r System.map ]; then $(DEPMOD) -ae -F System.map $(depmod_opts) $(KERNELRELEASE); fi
434 # Backwards compatibilty symlinks for people still using old versions
435 # of pcmcia-cs with hard coded pathnames on insmod. Remove
436 # _modinst_post_pcmcia for kernel 2.4.1.
437 .PHONY: _modinst_post_pcmcia
438 _modinst_post_pcmcia:
439 cd $(MODLIB); \
440 mkdir -p pcmcia; \
441 find kernel -path '*/pcmcia/*' -name '*.o' | xargs -i -r ln -sf ../{} pcmcia
443 .PHONY: $(patsubst %, _modinst_%, $(SUBDIRS))
444 $(patsubst %, _modinst_%, $(SUBDIRS)) :
445 $(MAKE) -C $(patsubst _modinst_%, %, $@) modules_install
447 # modules disabled....
449 else
450 modules modules_install: dummy
451 @echo
452 @echo "The present kernel configuration has modules disabled."
453 @echo "Type 'make config' and enable loadable module support."
454 @echo "Then build a kernel with module support enabled."
455 @echo
456 @exit 1
457 endif
459 clean: archclean
460 find . \( -name '*.[oas]' -o -name core -o -name '.*.flags' \) -type f -print \
461 | grep -v lxdialog/ | xargs rm -f
462 rm -f $(CLEAN_FILES)
463 rm -rf $(CLEAN_DIRS)
464 $(MAKE) -C Documentation/DocBook clean
466 mrproper: clean archmrproper
467 find . \( -size 0 -o -name .depend \) -type f -print | xargs rm -f
468 rm -f $(MRPROPER_FILES)
469 rm -rf $(MRPROPER_DIRS)
470 $(MAKE) -C Documentation/DocBook mrproper
472 distclean: mrproper
473 rm -f core `find . \( -not -type d \) -and \
474 \( -name '*.orig' -o -name '*.rej' -o -name '*~' \
475 -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \
476 -o -name '.*.rej' -o -name '.SUMS' -o -size 0 \) -type f -print` TAGS tags
478 backup: mrproper
479 cd .. && tar cf - linux/ | gzip -9 > backup.gz
480 sync
482 sgmldocs:
483 chmod 755 $(TOPDIR)/scripts/docgen
484 chmod 755 $(TOPDIR)/scripts/gen-all-syms
485 chmod 755 $(TOPDIR)/scripts/kernel-doc
486 $(MAKE) -C $(TOPDIR)/Documentation/DocBook books
488 psdocs: sgmldocs
489 $(MAKE) -C Documentation/DocBook ps
491 pdfdocs: sgmldocs
492 $(MAKE) -C Documentation/DocBook pdf
494 htmldocs: sgmldocs
495 $(MAKE) -C Documentation/DocBook html
497 sums:
498 find . -type f -print | sort | xargs sum > .SUMS
500 dep-files: scripts/mkdep archdep include/linux/version.h
501 scripts/mkdep -- init/*.c > .depend
502 scripts/mkdep -- `find $(FINDHPATH) -name SCCS -prune -o -follow -name \*.h ! -name modversions.h -print` > .hdepend
503 $(MAKE) $(patsubst %,_sfdep_%,$(SUBDIRS)) _FASTDEP_ALL_SUB_DIRS="$(SUBDIRS)"
504 ifdef CONFIG_MODVERSIONS
505 $(MAKE) update-modverfile
506 endif
508 ifdef CONFIG_MODVERSIONS
509 MODVERFILE := $(TOPDIR)/include/linux/modversions.h
510 else
511 MODVERFILE :=
512 endif
513 export MODVERFILE
515 depend dep: dep-files
517 checkconfig:
518 find * -name '*.[hcS]' -type f -print | sort | xargs $(PERL) -w scripts/checkconfig.pl
520 checkhelp:
521 find * -name [cC]onfig.in -print | sort | xargs $(PERL) -w scripts/checkhelp.pl
523 checkincludes:
524 find * -name '*.[hcS]' -type f -print | sort | xargs $(PERL) -w scripts/checkincludes.pl
526 ifdef CONFIGURATION
527 ..$(CONFIGURATION):
528 @echo
529 @echo "You have a bad or nonexistent" .$(CONFIGURATION) ": running 'make" $(CONFIGURATION)"'"
530 @echo
531 $(MAKE) $(CONFIGURATION)
532 @echo
533 @echo "Successful. Try re-making (ignore the error that follows)"
534 @echo
535 exit 1
537 #dummy: ..$(CONFIGURATION)
538 dummy:
540 else
542 dummy:
544 endif
546 include Rules.make
548 #
549 # This generates dependencies for the .h files.
550 #
552 scripts/mkdep: scripts/mkdep.c
553 $(HOSTCC) $(HOSTCFLAGS) -o scripts/mkdep scripts/mkdep.c
555 scripts/split-include: scripts/split-include.c
556 $(HOSTCC) $(HOSTCFLAGS) -o scripts/split-include scripts/split-include.c
558 #
559 # RPM target
560 #
561 # If you do a make spec before packing the tarball you can rpm -ta it
562 #
563 spec:
564 . scripts/mkspec >kernel.spec
566 #
567 # Build a tar ball, generate an rpm from it and pack the result
568 # There arw two bits of magic here
569 # 1) The use of /. to avoid tar packing just the symlink
570 # 2) Removing the .dep files as they have source paths in them that
571 # will become invalid
572 #
573 rpm: clean spec
574 find . \( -size 0 -o -name .depend -o -name .hdepend \) -type f -print | xargs rm -f
575 set -e; \
576 cd $(TOPDIR)/.. ; \
577 ln -sf $(TOPDIR) $(KERNELPATH) ; \
578 tar -cvz --exclude CVS -f $(KERNELPATH).tar.gz $(KERNELPATH)/. ; \
579 rm $(KERNELPATH) ; \
580 cd $(TOPDIR) ; \
581 . scripts/mkversion > .version ; \
582 rpm -ta $(TOPDIR)/../$(KERNELPATH).tar.gz ; \
583 rm $(TOPDIR)/../$(KERNELPATH).tar.gz