6 KERNELRELEASE
=$(VERSION
).
$(PATCHLEVEL
).
$(SUBLEVEL
)$(EXTRAVERSION
)
8 ARCH
:= $(shell uname
-m | sed
-e s
/i
.86/i386
/ -e s
/sun4u
/sparc64
/ -e s
/arm.
*/arm
/ -e s
/sa110
/arm
/)
9 KERNELPATH
=kernel-
$(shell echo
$(KERNELRELEASE
) | sed
-e
"s/-//")
11 CONFIG_SHELL
:= $(shell if
[ -x
"$$BASH" ]; then echo
$$BASH; \
12 else if
[ -x
/bin
/bash
]; then echo
/bin
/bash
; \
13 else echo sh
; fi
; fi
)
14 TOPDIR
:= $(shell /bin
/pwd
)
16 HPATH
= $(TOPDIR
)/include
17 FINDHPATH
= $(HPATH
)/asm
$(HPATH
)/linux
$(HPATH
)/scsi
$(HPATH
)/net
20 HOSTCFLAGS
= -Wall
-Wstrict-prototypes
-O2
-fomit-frame-pointer
25 # Include the make variables (CC, etc...)
28 AS
= $(CROSS_COMPILE
)as
29 LD
= $(CROSS_COMPILE
)ld
30 CC
= $(CROSS_COMPILE
)gcc
32 AR
= $(CROSS_COMPILE
)ar
33 NM
= $(CROSS_COMPILE
)nm
34 STRIP
= $(CROSS_COMPILE
)strip
35 OBJCOPY
= $(CROSS_COMPILE
)objcopy
36 OBJDUMP
= $(CROSS_COMPILE
)objdump
37 MAKEFILES
= $(TOPDIR
)/.config
38 GENKSYMS
= /sbin
/genksyms
44 export VERSION PATCHLEVEL SUBLEVEL EXTRAVERSION KERNELRELEASE ARCH \
45 CONFIG_SHELL TOPDIR HPATH HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC \
46 CPP AR NM STRIP OBJCOPY OBJDUMP MAKE MAKEFILES GENKSYMS MODFLAGS PERL
51 # Make "config" the default target if there is no configuration file or
52 # "depend" the target if there is no top-level dependency information.
55 ifeq (.config
,$(wildcard .config
))
57 ifeq (.depend
,$(wildcard .depend
))
59 do-it-all
: Version vmlinux
61 CONFIGURATION
= depend
65 CONFIGURATION
= config
70 # INSTALL_PATH specifies where to place the updated kernel and system map
71 # images. Uncomment if you want to place them anywhere other than root.
74 #export INSTALL_PATH=/boot
77 # INSTALL_MOD_PATH specifies a prefix to MODLIB for module directory
78 # relocations required by build roots. This is not defined in the
79 # makefile but the arguement can be passed to make if needed.
82 MODLIB
:= $(INSTALL_MOD_PATH
)/lib
/modules
/$(KERNELRELEASE
)
89 CPPFLAGS
:= -D__KERNEL__
-I
$(HPATH
)
91 CFLAGS
:= $(CPPFLAGS
) -Wall
-Wstrict-prototypes
-Wno-trigraphs
-O2 \
92 -fomit-frame-pointer
-fno-strict-aliasing
-fno-common
93 AFLAGS
:= -D__ASSEMBLY__
$(CPPFLAGS
)
96 # ROOT_DEV specifies the default root-device when making the image.
97 # This can be either FLOPPY, CURRENT, /dev/xxxx or empty, in which case
98 # the default of FLOPPY is used by 'build'.
99 # This is i386 specific.
102 export ROOT_DEV
= CURRENT
105 # If you want to preset the SVGA mode, uncomment the next line and
106 # set SVGA_MODE to whatever number you want.
107 # Set it to -DSVGA_MODE=NORMAL_VGA if you just want the EGA/VGA mode.
108 # The number is the same as you would ordinarily press at bootup.
109 # This is i386 specific.
112 export SVGA_MODE
= -DSVGA_MODE
=NORMAL_VGA
115 # If you want the RAM disk device, define this to be the size in blocks.
116 # This is i386 specific.
119 #export RAMDISK = -DRAMDISK=512
121 CORE_FILES
=kernel
/kernel.o mm
/mm.o fs
/fs.o ipc
/ipc.o
122 NETWORKS
=net
/network.o
124 LIBS
=$(TOPDIR
)/lib
/lib.a
125 SUBDIRS
=kernel lib drivers mm fs net ipc sound
132 DRIVERS-
$(CONFIG_ACPI
) += drivers
/acpi
/acpi.o
133 DRIVERS-
$(CONFIG_PARPORT
) += drivers
/parport
/driver.o
134 DRIVERS-y
+= drivers
/base
/base.o \
135 drivers
/char
/char.o \
136 drivers
/block
/block.o \
137 drivers
/misc
/misc.o \
139 drivers
/media
/media.o
140 DRIVERS-
$(CONFIG_AGP
) += drivers
/char
/agp
/agp.o
141 DRIVERS-
$(CONFIG_DRM
) += drivers
/char
/drm
/drm.o
142 DRIVERS-
$(CONFIG_NUBUS
) += drivers
/nubus
/nubus.a
143 DRIVERS-
$(CONFIG_NET_FC
) += drivers
/net
/fc/fc.o
144 DRIVERS-
$(CONFIG_APPLETALK
) += drivers
/net
/appletalk
/appletalk.o
145 DRIVERS-
$(CONFIG_TR
) += drivers
/net
/tokenring
/tr.o
146 DRIVERS-
$(CONFIG_WAN
) += drivers
/net
/wan
/wan.o
147 DRIVERS-
$(CONFIG_ARCNET
) += drivers
/net
/arcnet
/arcnetdrv.o
148 DRIVERS-
$(CONFIG_ATM
) += drivers
/atm
/atm.o
149 DRIVERS-
$(CONFIG_IDE
) += drivers
/ide
/idedriver.o
150 DRIVERS-
$(CONFIG_FC4
) += drivers
/fc4
/fc4.a
151 DRIVERS-
$(CONFIG_SCSI
) += drivers
/scsi
/scsidrv.o
152 DRIVERS-
$(CONFIG_FUSION_BOOT
) += drivers
/message
/fusion
/fusion.o
153 DRIVERS-
$(CONFIG_IEEE1394
) += drivers
/ieee1394
/ieee1394drv.o
155 ifneq ($(CONFIG_CD_NO_IDESCSI
)$(CONFIG_BLK_DEV_IDECD
)$(CONFIG_BLK_DEV_SR
)$(CONFIG_PARIDE_PCD
),)
156 DRIVERS-y
+= drivers
/cdrom
/driver.o
159 DRIVERS-
$(CONFIG_SOUND
) += sound
/sound.o
160 DRIVERS-
$(CONFIG_PCI
) += drivers
/pci
/driver.o
161 DRIVERS-
$(CONFIG_MTD
) += drivers
/mtd
/mtdlink.o
162 DRIVERS-
$(CONFIG_PCMCIA
) += drivers
/pcmcia
/pcmcia.o
163 DRIVERS-
$(CONFIG_NET_PCMCIA
) += drivers
/net
/pcmcia
/pcmcia_net.o
164 DRIVERS-
$(CONFIG_NET_WIRELESS
) += drivers
/net
/wireless
/wireless_net.o
165 DRIVERS-
$(CONFIG_NET_TULIP
) += drivers
/net
/tulip
/tulip_net.o
166 DRIVERS-
$(CONFIG_PCMCIA_CHRDEV
) += drivers
/char
/pcmcia
/pcmcia_char.o
167 DRIVERS-
$(CONFIG_DIO
) += drivers
/dio
/dio.a
168 DRIVERS-
$(CONFIG_SBUS
) += drivers
/sbus
/sbus_all.o
169 DRIVERS-
$(CONFIG_ZORRO
) += drivers
/zorro
/driver.o
170 DRIVERS-
$(CONFIG_FC4
) += drivers
/fc4
/fc4.a
171 DRIVERS-
$(CONFIG_ALL_PPC
) += drivers
/macintosh
/macintosh.o
172 DRIVERS-
$(CONFIG_MAC
) += drivers
/macintosh
/macintosh.o
173 DRIVERS-
$(CONFIG_PNP
) += drivers
/pnp
/pnp.o
174 DRIVERS-
$(CONFIG_SGI_IP22
) += drivers
/sgi
/sgi.a
175 DRIVERS-
$(CONFIG_VT
) += drivers
/video
/video.o
176 DRIVERS-
$(CONFIG_PARIDE
) += drivers
/block
/paride
/paride.a
177 DRIVERS-
$(CONFIG_HAMRADIO
) += drivers
/net
/hamradio
/hamradio.o
178 DRIVERS-
$(CONFIG_TC
) += drivers
/tc
/tc.a
179 DRIVERS-
$(CONFIG_USB
) += drivers
/usb
/usbdrv.o
180 DRIVERS-
$(CONFIG_INPUT
) += drivers
/input
/inputdrv.o
181 DRIVERS-
$(CONFIG_GAMEPORT
) += drivers
/input
/gameport
/gamedrv.o
182 DRIVERS-
$(CONFIG_SERIO
) += drivers
/input
/serio
/seriodrv.o
183 DRIVERS-
$(CONFIG_I2O
) += drivers
/message
/i2o
/i2o.o
184 DRIVERS-
$(CONFIG_IRDA
) += drivers
/net
/irda
/irda.o
185 DRIVERS-
$(CONFIG_I2C
) += drivers
/i2c
/i2c.o
186 DRIVERS-
$(CONFIG_PHONE
) += drivers
/telephony
/telephony.o
187 DRIVERS-
$(CONFIG_MD
) += drivers
/md
/mddev.o
188 DRIVERS-
$(CONFIG_BLUEZ
) += drivers
/bluetooth
/bluetooth.o
189 DRIVERS-
$(CONFIG_HOTPLUG_PCI
) += drivers
/hotplug
/vmlinux-obj.o
190 DRIVERS-
$(CONFIG_ISDN
) += drivers
/isdn
/vmlinux-obj.o
192 DRIVERS
:= $(DRIVERS-y
)
195 # files removed with 'make clean'
197 kernel
/ksyms.lst
include/linux
/compile.h \
200 drivers
/char
/consolemap_deftbl.c drivers
/video
/promcon_tbl.c \
201 drivers
/char
/conmakehash \
202 drivers
/char
/drm
/*-mod.c \
203 drivers
/pci
/devlist.h drivers
/pci
/classlist.h drivers
/pci
/gen-devlist \
204 drivers
/zorro
/devlist.h drivers
/zorro
/gen-devlist \
205 sound
/oss
/bin2hex sound
/oss
/hex2hex \
206 drivers
/atm
/fore200e_mkfirm drivers
/atm
/{pca
,sba
}*{.bin
,.bin1
,.bin2
} \
207 drivers
/scsi
/aic7xxx
/aicasm
/aicasm_gram.c \
208 drivers
/scsi
/aic7xxx
/aicasm
/aicasm_scan.c \
209 drivers
/scsi
/aic7xxx
/aicasm
/y.tab.h \
210 drivers
/scsi
/aic7xxx
/aicasm
/aicasm \
211 drivers
/scsi
/53c700_d.h \
212 net
/khttpd
/make_times_h \
215 # directories removed with 'make clean'
219 # files removed with 'make mrproper'
221 include/linux
/autoconf.h
include/linux
/version.h \
222 drivers
/net
/hamradio
/soundmodem
/sm_tbl_
{afsk1200
,afsk2666
,fsk9600
}.h \
223 drivers
/net
/hamradio
/soundmodem
/sm_tbl_
{hapn4800
,psk4800
}.h \
224 drivers
/net
/hamradio
/soundmodem
/sm_tbl_
{afsk2400_7
,afsk2400_8
}.h \
225 drivers
/net
/hamradio
/soundmodem
/gentbl \
226 sound
/oss
/*_boot.h sound
/oss
/.
*.boot \
227 sound
/oss
/msndinit.c \
228 sound
/oss
/msndperm.c \
229 sound
/oss
/pndsperm.c \
230 sound
/oss
/pndspini.c \
231 drivers
/atm
/fore200e_
*_fw.c drivers
/atm
/.fore200e_
*.fw \
232 .version .config
* config.in config.old \
233 scripts
/tkparse scripts
/kconfig.tk scripts
/kconfig.tmp \
234 scripts
/lxdialog
/*.o scripts
/lxdialog
/lxdialog \
237 .hdepend scripts
/mkdep scripts
/split-include scripts
/docproc \
238 $(TOPDIR
)/include/linux
/modversions.h \
241 # directories removed with 'make mrproper'
244 $(TOPDIR
)/include/linux
/modules
247 include arch
/$(ARCH
)/Makefile
249 export CPPFLAGS CFLAGS CFLAGS_KERNEL AFLAGS AFLAGS_KERNEL
251 export NETWORKS DRIVERS LIBS HEAD LDFLAGS LINKFLAGS MAKEBOOT ASFLAGS
254 $(CPP
) $(AFLAGS
) $(AFLAGS_KERNEL
) -traditional
-o
$*.s
$<
256 $(CC
) $(AFLAGS
) $(AFLAGS_KERNEL
) -traditional
-c
-o
$*.o
$<
259 @
rm -f
include/linux
/compile.h
262 @
$(MAKE
) CFLAGS
="$(CFLAGS) $(CFLAGS_KERNEL)" -C arch
/$(ARCH
)/boot
264 vmlinux
: include/linux
/version.h
$(CONFIGURATION
) init
/main.o init
/version.o init
/do_mounts.o linuxsubdirs
265 $(LD
) $(LINKFLAGS
) $(HEAD
) init
/main.o init
/version.o init
/do_mounts.o \
273 $(NM
) vmlinux | grep
-v
'\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' |
sort > System.map
277 ( cd
include ; ln
-sf asm-
$(ARCH
) asm
)
278 @if
[ ! -d
include/linux
/modules
]; then \
279 mkdir
include/linux
/modules
; \
283 $(CONFIG_SHELL
) scripts
/Configure
-d arch
/$(ARCH
)/config.in
286 $(MAKE
) -C scripts kconfig.tk
287 wish
-f scripts
/kconfig.tk
289 menuconfig
: include/linux
/version.h symlinks
290 $(MAKE
) -C scripts
/lxdialog
all
291 $(CONFIG_SHELL
) scripts
/Menuconfig arch
/$(ARCH
)/config.in
294 $(CONFIG_SHELL
) scripts
/Configure arch
/$(ARCH
)/config.in
296 include/config
/MARKER
: scripts
/split-include
include/linux
/autoconf.h
297 scripts
/split-include
include/linux
/autoconf.h
include/config
298 @ touch
include/config
/MARKER
300 linuxsubdirs
: $(patsubst %, _dir_
%, $(SUBDIRS
))
302 $(patsubst %, _dir_
%, $(SUBDIRS
)) : dummy
include/linux
/version.h
include/config
/MARKER
303 $(MAKE
) CFLAGS
="$(CFLAGS) $(CFLAGS_KERNEL)" -C
$(patsubst _dir_
%, %, $@
)
305 $(TOPDIR
)/include/linux
/version.h
: include/linux
/version.h
306 $(TOPDIR
)/include/linux
/compile.h
: include/linux
/compile.h
309 . scripts
/mkversion
> .tmpversion
310 @mv
-f .tmpversion .version
312 include/linux
/compile.h
: $(CONFIGURATION
) include/linux
/version.h newversion
313 @echo
-n \
#define UTS_VERSION \"\#`cat .version` > .ver
314 @if
[ -n
"$(CONFIG_SMP)" ] ; then echo
-n
" SMP" >> .ver
; fi
315 @if
[ -f .name
]; then echo
-n \
-`cat .name` >> .ver
; fi
316 @echo
' '`date`'"' >> .ver
317 @echo \
#define LINUX_COMPILE_TIME \"`date +%T`\" >> .ver
318 @echo \
#define LINUX_COMPILE_BY \"`whoami`\" >> .ver
319 @echo \
#define LINUX_COMPILE_HOST \"`hostname`\" >> .ver
320 @if
[ -x
/bin
/dnsdomainname
]; then \
321 echo \
#define LINUX_COMPILE_DOMAIN \"`dnsdomainname`\"; \
322 elif
[ -x
/bin
/domainname
]; then \
323 echo \
#define LINUX_COMPILE_DOMAIN \"`domainname`\"; \
325 echo \
#define LINUX_COMPILE_DOMAIN ; \
327 @echo \
#define LINUX_COMPILER \"`$(CC) $(CFLAGS) -v 2>&1 | tail -1`\" >> .ver
330 include/linux
/version.h
: .
/Makefile
331 @echo \
#define UTS_RELEASE \"$(KERNELRELEASE)\" > .ver
332 @echo \
#define LINUX_VERSION_CODE `expr $(VERSION) \\* 65536 + $(PATCHLEVEL) \\* 256 + $(SUBLEVEL)` >> .ver
333 @echo
'#define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))' >>.ver
338 init
/version.o
: init
/version.c
include/linux
/compile.h
include/config
/MARKER
339 $(CC
) $(CFLAGS
) $(CFLAGS_KERNEL
) -DUTS_MACHINE
='"$(ARCH)"' -DKBUILD_BASENAME
=$(subst $(comma
),_
,$(subst -,_
,$(*F
))) -c
-o init
/version.o init
/version.c
341 init
/main.o
: init
/main.c
include/config
/MARKER
342 $(CC
) $(CFLAGS
) $(CFLAGS_KERNEL
) $(PROFILING
) -DKBUILD_BASENAME
=$(subst $(comma
),_
,$(subst -,_
,$(*F
))) -c
-o
$*.o
$<
344 init
/do_mounts.o
: init
/do_mounts.c
include/config
/MARKER
345 $(CC
) $(CFLAGS
) $(CFLAGS_KERNEL
) $(PROFILING
) -c
-o
$*.o
$<
347 fs lib mm ipc kernel drivers net sound
: dummy
348 $(MAKE
) CFLAGS
="$(CFLAGS) $(CFLAGS_KERNEL)" $(subst $@
, _dir_
$@
, $@
)
351 etags
`find include/asm-$(ARCH) -name '*.h'`
352 find
include -type d \
( -name
"asm-*" -o
-name config \
) -prune
-o
-name
'*.h' -print | xargs etags
-a
353 find
$(SUBDIRS
) init
-name
'*.[ch]' | xargs etags
-a
355 # Exuberant ctags works better with -I
357 CTAGSF
=`ctags --version | grep -i exuberant >/dev/null && echo "-I __initdata,__exitdata,EXPORT_SYMBOL,EXPORT_SYMBOL_NOVERS"`; \
358 ctags
$$CTAGSF `find include/asm-$(ARCH) -name '*.h'` && \
359 find
include -type d \
( -name
"asm-*" -o
-name config \
) -prune
-o
-name
'*.h' -print | xargs ctags
$$CTAGSF -a
&& \
360 find
$(SUBDIRS
) init
-name
'*.[ch]' | xargs ctags
$$CTAGSF -a
363 ifdef CONFIG_MODVERSIONS
364 MODFLAGS
+= -DMODVERSIONS
-include $(HPATH
)/linux
/modversions.h
368 modules
: $(patsubst %, _mod_
%, $(SUBDIRS
))
370 .PHONY
: $(patsubst %, _mod_
%, $(SUBDIRS
))
371 $(patsubst %, _mod_
%, $(SUBDIRS
)) : include/linux
/version.h
include/config
/MARKER
372 $(MAKE
) -C
$(patsubst _mod_
%, %, $@
) CFLAGS
="$(CFLAGS) $(MODFLAGS)" MAKING_MODULES
=1 modules
374 .PHONY
: modules_install
375 modules_install
: _modinst_
$(patsubst %, _modinst_
%, $(SUBDIRS
)) _modinst_post
379 @
rm -rf
$(MODLIB
)/kernel
380 @
rm -f
$(MODLIB
)/build
381 @mkdir
-p
$(MODLIB
)/kernel
382 @ln
-s
$(TOPDIR
) $(MODLIB
)/build
384 # If System.map exists, run depmod. This deliberately does not have a
385 # dependency on System.map since that would run the dependency tree on
386 # vmlinux. This depmod is only for convenience to give the initial
387 # boot a modules.dep even before / is mounted read-write. However the
388 # boot script depmod is the master version.
389 ifeq "$(strip $(INSTALL_MOD_PATH))" ""
392 depmod_opts
:= -b
$(INSTALL_MOD_PATH
) -r
394 .PHONY
: _modinst_post
395 _modinst_post
: _modinst_post_pcmcia
396 if
[ -r System.map
]; then
$(DEPMOD
) -ae
-F System.map
$(depmod_opts
) $(KERNELRELEASE
); fi
398 # Backwards compatibilty symlinks for people still using old versions
399 # of pcmcia-cs with hard coded pathnames on insmod. Remove
400 # _modinst_post_pcmcia for kernel 2.4.1.
401 .PHONY
: _modinst_post_pcmcia
402 _modinst_post_pcmcia
:
405 find kernel
-path
'*/pcmcia/*' -name
'*.o' | xargs
-i
-r ln
-sf ..
/{} pcmcia
407 .PHONY
: $(patsubst %, _modinst_
%, $(SUBDIRS
))
408 $(patsubst %, _modinst_
%, $(SUBDIRS
)) :
409 $(MAKE
) -C
$(patsubst _modinst_
%, %, $@
) modules_install
411 # modules disabled....
414 modules modules_install
: dummy
416 @echo
"The present kernel configuration has modules disabled."
417 @echo
"Type 'make config' and enable loadable module support."
418 @echo
"Then build a kernel with module support enabled."
424 find . \
( -name
'*.[oas]' -o
-name core
-o
-name
'.*.flags' \
) -type f
-print \
425 | grep
-v lxdialog
/ | xargs
rm -f
428 $(MAKE
) -C Documentation
/DocBook
clean
430 mrproper
: clean archmrproper
431 find . \
( -size
0 -o
-name .depend \
) -type f
-print | xargs
rm -f
432 rm -f
$(MRPROPER_FILES
)
433 rm -rf
$(MRPROPER_DIRS
)
434 $(MAKE
) -C Documentation
/DocBook mrproper
437 rm -f core
`find . \( -not -type d \) -and \
438 \( -name '*.orig' -o -name '*.rej' -o -name '*~' \
439 -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \
440 -o -name '.*.rej' -o -name '.SUMS' -o -size 0 \) -type f -print` TAGS
tags
443 cd ..
&& tar cf
- linux
/ | gzip
-9 > backup.gz
447 chmod
755 $(TOPDIR
)/scripts
/docgen
448 chmod
755 $(TOPDIR
)/scripts
/gen-all-syms
449 chmod
755 $(TOPDIR
)/scripts
/kernel-doc
450 $(MAKE
) -C
$(TOPDIR
)/Documentation
/DocBook books
453 $(MAKE
) -C Documentation
/DocBook ps
456 $(MAKE
) -C Documentation
/DocBook pdf
459 $(MAKE
) -C Documentation
/DocBook html
462 find .
-type f
-print |
sort | xargs sum
> .SUMS
464 dep-files
: scripts
/mkdep archdep
include/linux
/version.h
465 scripts
/mkdep
-- init
/*.c
> .depend
466 scripts
/mkdep
-- `find $(FINDHPATH) -name SCCS -prune -o -follow -name \*.h ! -name modversions.h -print` > .hdepend
467 $(MAKE
) $(patsubst %,_sfdep_
%,$(SUBDIRS
)) _FASTDEP_ALL_SUB_DIRS
="$(SUBDIRS)"
468 ifdef CONFIG_MODVERSIONS
469 $(MAKE
) update-modverfile
472 ifdef CONFIG_MODVERSIONS
473 MODVERFILE
:= $(TOPDIR
)/include/linux
/modversions.h
479 depend dep
: dep-files
482 find
* -name
'*.[hcS]' -type f
-print |
sort | xargs
$(PERL
) -w scripts
/checkconfig.pl
485 find
* -name
[cC
]onfig.in
-print |
sort | xargs
$(PERL
) -w scripts
/checkhelp.pl
488 find
* -name
'*.[hcS]' -type f
-print |
sort | xargs
$(PERL
) -w scripts
/checkincludes.pl
493 @echo
"You have a bad or nonexistent" .
$(CONFIGURATION
) ": running 'make" $(CONFIGURATION
)"'"
495 $(MAKE
) $(CONFIGURATION
)
497 @echo
"Successful. Try re-making (ignore the error that follows)"
501 #dummy: ..$(CONFIGURATION)
513 # This generates dependencies for the .h files.
516 scripts
/mkdep
: scripts
/mkdep.c
517 $(HOSTCC
) $(HOSTCFLAGS
) -o scripts
/mkdep scripts
/mkdep.c
519 scripts
/split-include
: scripts
/split-include.c
520 $(HOSTCC
) $(HOSTCFLAGS
) -o scripts
/split-include scripts
/split-include.c
525 # If you do a make spec before packing the tarball you can rpm -ta it
528 . scripts
/mkspec
>kernel.spec
531 # Build a tar ball, generate an rpm from it and pack the result
532 # There arw two bits of magic here
533 # 1) The use of /. to avoid tar packing just the symlink
534 # 2) Removing the .dep files as they have source paths in them that
535 # will become invalid
538 find . \
( -size
0 -o
-name .depend
-o
-name .hdepend \
) -type f
-print | xargs
rm -f
541 ln
-sf
$(TOPDIR
) $(KERNELPATH
) ; \
542 tar -cvz
--exclude CVS
-f
$(KERNELPATH
).
tar.gz
$(KERNELPATH
)/.
; \
545 . scripts
/mkversion
> .version
; \
546 rpm
-ta
$(TOPDIR
)/..
/$(KERNELPATH
).
tar.gz
; \
547 rm $(TOPDIR
)/..
/$(KERNELPATH
).
tar.gz