Commit eaa380db authored by Kai Germaschewski's avatar Kai Germaschewski

Merge germaschewski.name:/home/kai/kernel/v2.5/linux-2.5

into germaschewski.name:/home/kai/kernel/v2.5/linux-2.5.make
parents 3a2b9514 5ff48e06
......@@ -2981,6 +2981,14 @@ S: #102, 686 W. Maude Ave
S: Sunyvale, CA 94086
S: USA
N: Michael Still
E: mikal@stillhq.com
W: http://www.stillhq.com
D: Various janitorial patches
D: mandocs and mandocs_install build targets
S: (Email me and ask)
S: Australia
N: Henrik Storner
E: storner@image.dk
W: http://www.image.dk/~storner/
......
......@@ -20,10 +20,11 @@ DOCBOOKS := wanbook.sgml z8530book.sgml mcabook.sgml videobook.sgml \
# file.tmpl --> file.sgml +--> file.ps (psdocs)
# +--> file.pdf (pdfdocs)
# +--> DIR=file (htmldocs)
# +--> man/ (mandocs)
###
# The targets that may be used.
.PHONY: sgmldocs psdocs pdfdocs htmldocs clean mrproper
.PHONY: sgmldocs psdocs pdfdocs htmldocs mandocs installmandocs
BOOKS := $(addprefix $(obj)/,$(DOCBOOKS))
sgmldocs: $(BOOKS)
......@@ -37,10 +38,18 @@ pdfdocs: $(PDF)
HTML := $(patsubst %.sgml, %.html, $(BOOKS))
htmldocs: $(HTML)
MAN := $(patsubst %.sgml, %.9, $(BOOKS))
mandocs: $(MAN)
installmandocs: mandocs
$(MAKEMAN) install Documentation/DocBook/man
###
#External programs used
KERNELDOC = scripts/kernel-doc
DOCPROC = scripts/docproc
SPLITMAN = $(PERL) $(srctree)/scripts/split-man
MAKEMAN = $(PERL) $(srctree)/scripts/makeman
###
# DOCPROC is used for two purposes:
......@@ -127,6 +136,13 @@ quiet_cmd_db2html = DB2HTML $@
@if [ ! -z "$(PNG-$(basename $(notdir $@)))" ]; then \
cp $(PNG-$(basename $(notdir $@))) $(patsubst %.html,%,$@); fi
###
# Rule to generate man files - output is placed in the man subdirectory
%.9: %.sgml
$(SPLITMAN) $< $(objtree)/Documentation/DocBook/man "$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)"
$(MAKEMAN) convert $(objtree)/Documentation/DocBook/man $<
###
# Rules to generate postscripts and PNG imgages from .fig format files
quiet_cmd_fig2eps = FIG2EPS $@
......@@ -157,10 +173,10 @@ quiet_cmd_fig2png = FIG2PNG $@
# Help targets as used by the top-level makefile
dochelp:
@echo ' Linux kernel internal documentation in different formats:'
@echo ' sgmldocs (SGML), psdocs (Postscript), pdfdocs (PDF), htmldocs (HTML)'
@echo ' sgmldocs (SGML), psdocs (Postscript), pdfdocs (PDF)'
@echo ' htmldocs (HTML), mandocs (man pages, use installmandocs to install)'
###
# clean and mrproper as used by the top-level makefile
# Temporary files left by various tools
clean-files := $(DOCBOOKS) \
$(patsubst %.sgml, %.dvi, $(DOCBOOKS)) \
......@@ -171,10 +187,14 @@ clean-files := $(DOCBOOKS) \
$(patsubst %.sgml, %.ps, $(DOCBOOKS)) \
$(patsubst %.sgml, %.pdf, $(DOCBOOKS)) \
$(patsubst %.sgml, %.html, $(DOCBOOKS)) \
$(patsubst %.fig,%.eps, $(IMG-parportbook)) \
$(patsubst %.fig,%.png, $(IMG-parportbook)) \
$(patsubst %.sgml, %.9, $(DOCBOOKS)) \
$(patsubst %.fig,%.eps, $(IMG-parportbook)) \
$(patsubst %.fig,%.png, $(IMG-parportbook)) \
$(C-procfs-example)
ifneq ($(wildcard $(patsubst %.html,%,$(HTML))),)
clean-rule := rm -rf $(wildcard $(patsubst %.html,%,$(HTML)))
endif
#man put files in man subdir - traverse down
subdir- := man/
# Rules are put in Documentation/DocBook
clean-files := *.9.gz *.sgml manpage.links manpage.refs
......@@ -471,8 +471,6 @@ when configuring the kernel. Build the kernel image in the usual way
</Para>
<Para><screen>
make dep
make clean
make bzlilo
......
......@@ -212,7 +212,6 @@ replacing "/usr/src" with wherever you keep your Linux kernel source tree:
patch -p0 < DAC960.patch (if DAC960.patch is included)
cd linux
make config
make depend
make bzImage (or zImage)
Then install "arch/i386/boot/bzImage" or "arch/i386/boot/zImage" as your
......
......@@ -30,9 +30,9 @@ Compilation of kernel
eg.
CROSS_COMPILE=arm-linux-
Do a 'make config', followed by 'make dep', and finally 'make Image' to
build the kernel (arch/arm/boot/Image). A compressed image can be built
by doing a 'make zImage' instead of 'make Image'.
Do a 'make config', followed by 'make Image' to build the kernel
(arch/arm/boot/Image). A compressed image can be built by doing a
'make zImage' instead of 'make Image'.
Bug reports etc
......
......@@ -16,7 +16,6 @@ To build the kernel with current defaults:
make assabet_config
make oldconfig
make dep
make zImage
The resulting kernel image should be available in linux/arch/arm/boot/zImage.
......
......@@ -8,7 +8,6 @@ To compile for Brutus, you must issue the following commands:
make brutus_config
make config
[accept all the defaults]
make dep
make zImage
The resulting kernel will end up in linux/arch/arm/boot/zImage. This file
......
......@@ -26,7 +26,6 @@ will suffice:
make cerf_config
make xconfig
make dep
make zImage
cp arch/arm/boot/zImage <TFTP directory>
......
......@@ -7,7 +7,6 @@ To build the kernel:
make huw_webpanel_config
make oldconfig
[accept all defaults]
make dep
make zImage
Mostly of the work is done by:
......
......@@ -13,7 +13,7 @@ serial console (to see what you're doing). No other devices have been
enabled.
To build, do a "make menuconfig" (or xmenuconfig) and select Itsy support.
Disable Flash and LCD support. and then do a make dep and a make zImage.
Disable Flash and LCD support. and then do a make zImage.
Finally, you will need to cd to arch/arm/boot/tools and execute a make there
to build the params-itsy program used to boot the kernel.
......
......@@ -8,7 +8,6 @@ To compile for Pangolin, you must issue the following commands:
make pangolin_config
make oldconfig
make dep
make zImage
Supported peripherals:
......
......@@ -35,7 +35,6 @@ Building the Kernel
change Linux makefile
make adi_evb_config
make oldconfig
make dep
make zImage
Loading Linux
......
......@@ -39,7 +39,6 @@ Building the Kernel
-----------------------------
make iq80310_config
make oldconfig
make dep
make zImage
This will build an image setup for BOOTP/NFS root support. To change this,
......
......@@ -37,7 +37,6 @@ Building the Kernel
-----------------------------
make iq80321_config
make oldconfig
make dep
make zImage
This will build an image setup for BOOTP/NFS root support. To change this,
......
......@@ -56,7 +56,7 @@ Compiling the kernel
2) then do a
make dep; make clean; make zImage; make modules
make clean; make zImage; make modules
3) do the usual things to install a new image (backup the old one, run
`rdev -R zImage 1', copy the new image in place, run lilo). Might
......
......@@ -37,7 +37,7 @@ configuration for your kernel. If you want to use the GoldStar driver
like a module, don't select 'GoldStar CDROM support'. By the way, you
have to include the iso9660 filesystem.
Now start compiling the kernel with 'make dep ; make zImage'.
Now start compiling the kernel with 'make zImage'.
If you want to use the driver as a module, you have to do 'make modules'
and 'make modules_install', additionally.
Install your new kernel as usual - maybe you do it with 'make zlilo'.
......
......@@ -229,7 +229,7 @@ To install:
second, third, or fourth controller installed, do not say "y" to the
secondary Matsushita CD-ROM questions.
3. Then do a "make dep", then make the kernel image ("make zlilo" or similar).
3. Then make the kernel image ("make zlilo" or similar).
4. Make the device file(s). This step usually already has been done by the
MAKEDEV script.
......
......@@ -60,12 +60,11 @@ c) Set address on ISA cards then:
or
edit /etc/modules.conf if needed (module).
or both to match this setting.
d) Run "make dep"
e) Run "make modules"
f) Run "make modules_install"
g) Run "/sbin/depmod -a"
h) install driver using `modprobe ip2 <options>` (options listed below)
i) run ip2mkdev (either the script below or the binary version)
d) Run "make modules"
e) Run "make modules_install"
f) Run "/sbin/depmod -a"
g) install driver using `modprobe ip2 <options>` (options listed below)
h) run ip2mkdev (either the script below or the binary version)
Kernel installation:
......@@ -77,13 +76,12 @@ b) Run "make config" or "make menuconfig" or "make xconfig"
c) Set address on ISA cards then:
edit /usr/src/linux/drivers/char/ip2.c
(Optional - may be specified on kernel command line now)
d) Run "make dep"
e) Run "make zImage" or whatever target you prefer.
f) mv /usr/src/linux/arch/i386/boot/zImage to /boot.
g) Add new config for this kernel into /etc/lilo.conf, run "lilo"
d) Run "make zImage" or whatever target you prefer.
e) mv /usr/src/linux/arch/i386/boot/zImage to /boot.
f) Add new config for this kernel into /etc/lilo.conf, run "lilo"
or copy to a floppy disk and boot from that floppy disk.
h) Reboot using this kernel
i) run ip2mkdev (either the script below or the binary version)
g) Reboot using this kernel
h) run ip2mkdev (either the script below or the binary version)
Kernel command line options:
......@@ -176,7 +174,6 @@ all cards will operate in polled mode.
If you select the driver as part of the kernel run :
make depend
make zlilo (or whatever you do to create a bootable kernel)
If you selected a module run :
......
......@@ -710,9 +710,8 @@ The Kernel
Finally, you need to make sure devfs is compiled into your kernel. Set
CONFIG_EXPERIMENTAL=y, CONFIG_DEVFS_FS=y and CONFIG_DEVFS_MOUNT=y by
using favourite configuration tool (i.e. make config or
make xconfig) and then make dep; make clean and then
recompile your kernel and modules. At boot, devfs will be mounted onto
/dev.
make xconfig) and then make clean and then recompile your kernel and
modules. At boot, devfs will be mounted onto /dev.
If you encounter problems booting (for example if you forgot a
configuration step), you can pass devfs=nomount at the kernel
......
......@@ -504,7 +504,7 @@ to e.g. the Internet:
cd /usr/src/linux
make menuconfig
<ISDN subsystem - ISDN support -- HiSax>
make clean; make dep; make zImage; make modules; make modules_install
make clean; make zImage; make modules; make modules_install
2. Install the new kernel
cp /usr/src/linux/arch/i386/boot/zImage /etc/kernel/linux.isdn
vi /etc/lilo.conf
......
00-INDEX
- this file: info on the kernel build process
commands.txt
- overview of kbuild commands
kconfig-language.txt
- specification of Config Language, the language in Kconfig files
random.txt
- description of generic config targets
makefiles.txt
- developer information for linux kernel makefiles
Overview of Kbuild Commands
24 January 1999
Michael Elizabeth Chastain, <mailto:mec@shout.net>
=== Introduction
Someday we'll get our arms around all this stuff and clean it up
a little! Meanwhile, this file describes the system as it is today.
=== Quick Start
If you are building a kernel for the first time, here are the commands
you need:
make config
make dep
make bzImage
Instead of 'make config', you can run 'make menuconfig' for a full-screen
text interface, or 'make xconfig' for an X interface using TCL/TK.
'make bzImage' will leave your new kernel image in arch/i386/boot/bzImage.
You can also use 'make bzdisk' or 'make bzlilo'.
See the lilo documentation for more information on how to use lilo.
You can also use the 'loadlin' program to boot Linux from MS-DOS.
Some computers won't work with 'make bzImage', either due to hardware
problems or very old versions of lilo or loadlin. If your kernel image
is small, you may use 'make zImage', 'make zdisk', or 'make zlilo'
on theses systems.
If you find a file name 'vmlinux' in the top directory of the source tree,
just ignore it. This is an intermediate file and you can't boot from it.
Other architectures: the information above is oriented towards the
i386. On other architectures, there are no 'bzImage' files; simply
use 'zImage' or 'vmlinux' as appropriate for your architecture.
Note: the difference between 'zImage' files and 'bzImage' files is that
'bzImage' uses a different layout and a different loading algorithm,
and thus has a larger capacity. Both files use gzip compression.
The 'bz' in 'bzImage' stands for 'big zImage', not for 'bzip'!
=== Top Level Makefile targets
Here are the targets available at the top level:
make config, make oldconfig, make menuconfig, make xconfig
Configure the Linux kernel. You must do this before almost
anything else.
config line-oriented interface
oldconfig line-oriented interface, re-uses old values
menuconfig curses-based full-screen interface
xconfig X window system interface
make checkconfig
This runs a little perl script that checks the source tree for
missing instances of #include <linux/config.h>. Someone needs to
do this occasionally, because the C preprocessor will silently give
bad results if these symbols haven't been included (it treats
undefined symbols in preprocessor directives as defined to 0).
Superfluous uses of #include <linux/config.h> are also reported,
but you can ignore these, because smart CONFIG_* dependencies
make them harmless.
You can run 'make checkconfig' without configuring the kernel.
Also, 'make checkconfig' does not modify any files.
make checkhelp
This runs another little perl script that checks the source tree
for options that are in Config.in files but are not documented
in scripts/Configure.help. Again, someone needs to do this
occasionally. If you are adding configuration options, it's
nice if you do it before you publish your patch!
You can run 'make checkhelp' without configuring the kernel.
Also, 'make checkhelp' does not modify any files.
make dep, make depend
'make dep' is a synonym for the long form, 'make depend'.
This command does two things. First, it computes dependency
information about which .o files depend on which .h files.
It records this information in a top-level file named .hdepend
and in one file per source directory named .depend.
Second, if you have CONFIG_MODVERSIONS enabled, 'make dep'
computes symbol version information for all of the files that
export symbols (note that both resident and modular files may
export symbols).
If you do not enable CONFIG_MODVERSIONS, you only have to run
'make dep' once, right after the first time you configure
the kernel. The .hdepend files and the .depend file are
independent of your configuration.
If you do enable CONFIG_MODVERSIONS, you must run 'make dep'
every time you change your configuration, because the module
symbol version information depends on the configuration.
[to be continued ...]
......@@ -216,8 +216,8 @@ more details, with real examples.
--- 3.5 Library file goals - lib-y
Objects listed with obj-* is used for modules or
are combined in a built-in.o for that specific directory.
Objects listed with obj-* are used for modules or
combined in a built-in.o for that specific directory.
There is also the possibility to list objects that will
be included in a library, lib.a.
All objects listed with lib-y are combined in a single
......
Code by Ghozlane Toumi <gtoumi@messel.emse.fr>, documentation by
Keith Owens <kaos@ocs.com.au>
In addition to the normal config targets you can make
randconfig random configuration.
allyes reply 'y' to all options, maximal kernel.
allno reply 'n' to all options, minimal kernel.
allmod build everything as modules where possible.
All random configurations will satisfy the config rules, that is, all
configurations should be valid. Any build errors indicate bugs in the
config dependency rules or in the Makefiles.
You can constrain the random configuration, e.g. you may want to force
the use of modules or the absence of /proc or cramfs must be a module.
If file .force_default exists then it is read to preset selected
values, all other values will be randomly selected, subject to the
config rules. The syntax of .force_default is:
CONFIG_foo=value
Force this value, for example CONFIG_MODULES=y, CONFIG_PROC_FS=n,
CONFIG_RAMFS=m.
# CONFIG_foo is not set
Equivalent to CONFIG_foo=n, supported because this is the format used
in .config. NOTE: The leading '#' is required.
# list CONFIG_foo val1,val2,val3
Pick a value for CONFIG_foo from the list. CONFIG_foo must be an int
or hex option. NOTE: The leading '#' is required.
# range CONFIG_foo min max
Pick a value for CONFIG_foo in the range min <=> max. CONFIG_foo
must be an int option. NOTE: The leading '#' is required.
If you have repeated settings of the same option in .force_default then
values take precedence over lists which take precedence over range.
Within each group the last setting for an option is used.
Answers "randomised" are bool(), tristate(), dep_tristate() and
choice(). Unless specified in .force_default, int, hex, and string
options use the default values from config.in.
......@@ -254,19 +254,18 @@ Content
a. cd /usr/src/linux
b. make clean /* take a few minutes */
c. make dep /* take a few minutes */
d. make bzImage /* take probably 10-20 minutes */
e. Backup original boot kernel. /* optional step */
f. cp /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz
g. Please make sure the boot kernel (vmlinuz) is in the
c. make bzImage /* take probably 10-20 minutes */
d. Backup original boot kernel. /* optional step */
e. cp /usr/src/linux/arch/i386/boot/bzImage /boot/vmlinuz
f. Please make sure the boot kernel (vmlinuz) is in the
correct position. If you use 'lilo' utility, you should
check /etc/lilo.conf 'image' item specified the path
which is the 'vmlinuz' path, or you will load wrong
(or old) boot kernel image (vmlinuz).
h. chmod 400 /vmlinuz
i. lilo
j. rdev -R /vmlinuz 1
k. sync
g. chmod 400 /vmlinuz
h. lilo
i. rdev -R /vmlinuz 1
j. sync
Note that if the result of "make zImage" is ERROR, then you have to
go back to Linux configuration Setup. Type "make config" in directory
......
......@@ -93,7 +93,6 @@ Released 1994-06-13
(else included in the kernel:)
# make config (answer yes on CONFIG _NET, _INET and _DE600 or _DE620)
# make clean
# make depend
# make zImage (or whatever magic you usually do)
o I use lilo to boot multiple kernels, so that I at least
......
......@@ -108,7 +108,6 @@ All you will need to do in order to install the driver is:
make config
(be sure to choose ARCnet in the network devices
and at least one chipset driver.)
make dep
make clean
make zImage
......
......@@ -437,8 +437,8 @@ Also add:
into the /usr/src/linux/drivers/net directory.
3.) Go to /usr/src/linux directory and run 'make config' followed by 'make dep'
and finally 'make' (or make bzImage) to rebuild the kernel.
3.) Go to /usr/src/linux directory and run 'make config' followed by 'make'
(or make bzImage) to rebuild the kernel.
4.) Use the DOS 'setup' utility to disable plug and play on the NIC.
......
......@@ -215,8 +215,6 @@ Building the driver into kernel
on "SiS 900/7016 PCI Fast Ethernet Adapter support" when configuring
the kernel. Build the kernel image in the usual way
make dep
make clean
make bzlilo
......
......@@ -79,7 +79,6 @@ Here are the installation steps in detail:
(If you wish to disable 3215 console support, edit
.config; change CONFIG_TN3215's value to "n";
and rerun "make oldconfig".)
make dep
make image
make modules
make modules_install
......
......@@ -597,7 +597,6 @@ replacing "/usr/src" with wherever you keep your Linux kernel source tree:
patch -p0 < BusLogic.patch (only for 2.0.33 and below)
cd linux
make config
make depend
make zImage
Then install "arch/i386/boot/zImage" as your standard kernel, run lilo if
......
......@@ -102,7 +102,6 @@ using "qa_test" (esp. io_test script) suite modified from Unix tests.
Installation:
make menuconfig
(select SCSI low-level, Compaq FC HBA)
make dep
make modules
make modules_install
......
......@@ -15,7 +15,7 @@ with this one.
Of course you should time how long each build takes :-)
Example:
make config
time -v sh -c 'make dep ; make clean install modules modules_install'
time -v sh -c 'make clean install modules modules_install'
If you are using some Compaq MP compliant machines you will need to set
the operating system in the BIOS settings to "Unixware" - don't ask me
......
......@@ -114,8 +114,7 @@ the README takes precedence.
Blaster, etc., select M (module) for OSS sound modules.
[thanks to Marvin Stodolsky <stodolsk@erols.com>]A
5. Make the kernel (e.g., make dep ; make bzImage), and install
the kernel.
5. Make the kernel (e.g., make bzImage), and install the kernel.
6. Make the modules and install them (make modules; make modules_install).
......
......@@ -722,8 +722,8 @@ To configure the driver, run "make config" in the kernel source directory
(after the questions about mouse, CD-ROM, ftape, etc. support). Questions
about options for sound will then be asked.
After configuring the kernel and sound driver, run "make dep" and compile
the kernel following instructions in the kernel README.
After configuring the kernel and sound driver and compile the kernel
following instructions in the kernel README.
The sound driver configuration dialog
-------------------------------------
......
......@@ -139,7 +139,6 @@ PART THREE: configure your kernel
soundcards you want support for)
make dep
make boot
.
.
......
......@@ -363,7 +363,7 @@ modules. The command string for the final compile looks like this:
1. cp .config /tmp
2. make mrproper
3. cp /tmp/.config .
4. make dep;make clean;make bzImage;make modules;make modules_install
4. make clean;make bzImage;make modules;make modules_install
This rebuilds both the kernel and all the modules and makes sure they all
have the same linkages. This generally solves the problem once the new
......
......@@ -50,8 +50,7 @@ configuration. The appropriate flags are:
With these flags, the kernel should compile and install the modules.
To record and monitor the compilation, I use:
(make dep; \
make zlilo ; \
(make zlilo ; \
make modules; \
make modules_install ;
depmod -a ) &>log &
......
......@@ -5,7 +5,7 @@ EXTRAVERSION = -test2
# *DOCUMENTATION*
# To see a list of typical targets execute "make help"
# More info can be located in ./Documentation/kbuild
# More info can be located in ./README
# Comments in this file are targeted only to the developer, do not
# expect to learn how to build the kernel reading this file.
......@@ -112,22 +112,8 @@ endif
export KBUILD_MODULES KBUILD_BUILTIN KBUILD_VERBOSE KBUILD_CHECKSRC
# Beautify output
# ---------------------------------------------------------------------------
#
# Normally, we echo the whole command before executing it. By making
# that echo $($(quiet)$(cmd)), we now have the possibility to set
# $(quiet) to choose other forms of output instead, e.g.
#
# quiet_cmd_cc_o_c = Compiling $(RELDIR)/$@
# cmd_cc_o_c = $(CC) $(c_flags) -c -o $@ $<
#
# If $(quiet) is empty, the whole command will be printed.
# If it is set to "quiet_", only the short version will be printed.
# If it is set to "silent_", nothing wil be printed at all, since
# the variable $(silent_cmd_cc_o_c) doesn't exist.
# To put more focus on warnings, less verbose as default
# Use 'make V=1' to see the full commands
ifdef V
ifeq ("$(origin V)", "command line")
......@@ -138,6 +124,9 @@ ifndef KBUILD_VERBOSE
KBUILD_VERBOSE = 0
endif
# Call sparse as part of compilation of C files
# Use 'make C=1' to enable sparse checking
ifdef C
ifeq ("$(origin C)", "command line")
KBUILD_CHECKSRC = $(C)
......@@ -147,6 +136,7 @@ ifndef KBUILD_CHECKSRC
KBUILD_CHECKSRC = 0
endif
# Do not print 'Entering directory ...'
MAKEFLAGS += --no-print-directory
......@@ -155,8 +145,28 @@ MAKEFLAGS += --no-print-directory
#MAKEFLAGS += -rR
# If the user wants quiet mode, echo short versions of the commands
# only
# Beautify output
# ---------------------------------------------------------------------------
#
# Normally, we echo the whole command before executing it. By making
# that echo $($(quiet)$(cmd)), we now have the possibility to set
# $(quiet) to choose other forms of output instead, e.g.
#
# quiet_cmd_cc_o_c = Compiling $(RELDIR)/$@
# cmd_cc_o_c = $(CC) $(c_flags) -c -o $@ $<
#
# If $(quiet) is empty, the whole command will be printed.
# If it is set to "quiet_", only the short version will be printed.
# If it is set to "silent_", nothing wil be printed at all, since
# the variable $(silent_cmd_cc_o_c) doesn't exist.
#
# A simple variant is to prefix commands with $(Q) - that's usefull
# for commands that shall be hidden in non-verbose mode.
#
# $(Q)ln $@ :<
#
# If KBUILD_VERBOSE equals 0 then the above command will be hidden.
# If KBUILD_VERBOSE equals 1 then the above command is displayed.
ifeq ($(KBUILD_VERBOSE),1)
quiet =
......@@ -166,8 +176,8 @@ else
Q = @
endif
# If the user is running make -s (silent mode), suppress echoing of
# commands
# If the user is running make -s (silent mode), suppress echoing of
# commands
ifneq ($(findstring s,$(MAKEFLAGS)),)
quiet=silent_
......@@ -175,7 +185,7 @@ endif
export quiet Q KBUILD_VERBOSE
# Paths to obj / src tree
# Paths to obj / src tree
src := .
obj := .
......@@ -184,7 +194,7 @@ objtree := .
export srctree objtree
# Make variables (CC, etc...)
# Make variables (CC, etc...)
AS = $(CROSS_COMPILE)as
LD = $(CROSS_COMPILE)ld
......@@ -213,9 +223,9 @@ AFLAGS_KERNEL =
NOSTDINC_FLAGS = -nostdinc -iwithprefix include
CPPFLAGS := -D__KERNEL__ -Iinclude
CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
CFLAGS := -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
-fno-strict-aliasing -fno-common
AFLAGS := -D__ASSEMBLY__ $(CPPFLAGS)
AFLAGS := -D__ASSEMBLY__
export VERSION PATCHLEVEL SUBLEVEL EXTRAVERSION KERNELRELEASE ARCH \
CONFIG_SHELL TOPDIR HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC \
......@@ -236,7 +246,7 @@ depfile = $(subst $(comma),_,$(@D)/.$(@F).d)
noconfig_targets := xconfig gconfig menuconfig config oldconfig randconfig \
defconfig allyesconfig allnoconfig allmodconfig \
clean mrproper distclean rpm \
help tags TAGS cscope sgmldocs psdocs pdfdocs htmldocs \
help tags TAGS cscope %docs \
checkconfig checkhelp checkincludes
RCS_FIND_IGNORE := \( -name SCCS -o -name BitKeeper -o -name .svn -o -name CVS \) -prune -o
......@@ -271,6 +281,10 @@ endif
include arch/$(ARCH)/Makefile
# Let architecture Makefiles change CPPFLAGS if needed
CFLAGS += $(CPPFLAGS) $(CFLAGS)
AFLAGS += $(CPPFLAGS) $(AFLAGS)
core-y += kernel/ mm/ fs/ ipc/ security/ crypto/
SUBDIRS += $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
......@@ -308,6 +322,10 @@ ifndef CONFIG_FRAME_POINTER
CFLAGS += -fomit-frame-pointer
endif
ifdef CONFIG_DEBUG_INFO
CFLAGS += -g
endif
#
# INSTALL_PATH specifies where to place the updated kernel and system map
# images. Uncomment if you want to place them anywhere other than root.
......@@ -352,7 +370,7 @@ endef
# set -e makes the rule exit immediately on error
define rule_vmlinux__
set -e; \
+set -e; \
$(if $(filter .tmp_kallsyms%,$^),, \
echo ' GEN .version'; \
. $(srctree)/scripts/mkversion > .tmp_version; \
......@@ -825,12 +843,12 @@ help:
@echo ' make C=1 [targets] Check all c source with checker tool'
@echo ''
@echo 'Execute "make" or "make all" to build all targets marked with [*] '
@echo 'For further info browse Documentation/kbuild/*'
@echo 'For further info see the ./README file'
# Documentation targets
# ---------------------------------------------------------------------------
sgmldocs psdocs pdfdocs htmldocs: scripts/docproc FORCE
%docs: scripts/docproc FORCE
$(Q)$(MAKE) $(build)=Documentation/DocBook $@
# Scripts to check various things for consistency
......
......@@ -802,6 +802,15 @@ config DEBUG_SEMAPHORE
verbose debugging messages. If you suspect a semaphore problem or a
kernel hacker asks for this option then say Y. Otherwise say N.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
endmenu
source "security/Kconfig"
......
......@@ -1061,6 +1061,15 @@ config DEBUG_ERRORS
you are concerned with the code size or don't want to see these
messages.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
# These options are only for real kernel hackers who want to get their hands dirty.
config DEBUG_LL
bool "Kernel low-level debugging functions"
......
......@@ -391,6 +391,15 @@ config DEBUG_ERRORS
you are concerned with the code size or don't want to see these
messages.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
# These options are only for real kernel hackers who want to get their hands dirty.
config DEBUG_LL
bool "Kernel low-level debugging functions"
......
......@@ -1354,6 +1354,15 @@ config DEBUG_HIGHMEM
This options enables addition error checking for high memory systems.
Disable for production systems.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
config DEBUG_SPINLOCK_SLEEP
bool "Sleep-inside-spinlock checking"
help
......
......@@ -740,6 +740,15 @@ config IA64_DEBUG_IRQ
and restore instructions. It's useful for tracking down spinlock
problems, but slow! If you're unsure, select N.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
endmenu
source "security/Kconfig"
......
......@@ -27,9 +27,7 @@ GCC_MINOR_VERSION=$(shell $(CC) -v 2>&1 | fgrep 'gcc version' | cut -f3 -d' ' |
GAS_STATUS=$(shell arch/ia64/scripts/check-gas $(CC) $(OBJDUMP))
arch-cppflags := $(shell arch/ia64/scripts/toolchain-flags $(CC) $(OBJDUMP))
cflags-y += $(arch-cppflags)
AFLAGS += $(arch-cppflags)
CPPFLAGS += $(shell arch/ia64/scripts/toolchain-flags $(CC) $(OBJDUMP))
ifeq ($(GAS_STATUS),buggy)
$(error Sorry, you need a newer version of the assember, one that is built from \
......
......@@ -1240,6 +1240,15 @@ config DEBUG_BUGVERBOSE
bool "Verbose BUG() reporting"
depends on DEBUG_KERNEL
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
endmenu
source "security/Kconfig"
......
......@@ -295,6 +295,15 @@ config FRAME_POINTER
If you don't debug the kernel, you can say N, but we may not be able
to solve problems without frame pointers.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
endmenu
source "security/Kconfig"
......
......@@ -1464,6 +1464,15 @@ config KGDB
debugger. See <http://kgdb.sourceforge.net/> for more information.
Unless you are intending to debug the kernel, say N here.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
choice
prompt "Serial Port"
depends on KGDB
......
......@@ -421,6 +421,15 @@ config PPCDBG
bool "Include PPCDBG realtime debugging"
depends on DEBUG_KERNEL
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
endmenu
source "security/Kconfig"
......
......@@ -306,6 +306,15 @@ config KALLSYMS
symbolic stack backtraces. This increases the size of the kernel
somewhat, as all symbols have to be loaded into the kernel image.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
config DEBUG_SPINLOCK_SLEEP
bool "Sleep-inside-spinlock checking"
help
......
......@@ -947,6 +947,15 @@ config DEBUG_DCFLUSH
bool "D-cache flush debugging"
depends on DEBUG_KERNEL
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
config STACK_DEBUG
bool "Stack Overflow Detection Support"
......
......@@ -221,7 +221,7 @@ config DEBUG_SLAB
config DEBUG_SPINLOCK
bool "Debug spinlocks usage"
config DEBUGSYM
config DEBUG_INFO
bool "Enable kernel debugging symbols"
help
When this is enabled, the User-Mode Linux binary will include
......@@ -234,15 +234,15 @@ config DEBUGSYM
config FRAME_POINTER
bool
default y if DEBUGSYM
default y if DEBUG_INFO
config PT_PROXY
bool "Enable ptrace proxy"
depends on XTERM_CHAN && DEBUGSYM
depends on XTERM_CHAN && DEBUG_INFO
config GPROF
bool "Enable gprof support"
depends on DEBUGSYM
depends on DEBUG_INFO
help
This allows profiling of a User-Mode Linux kernel with the gprof
utility.
......@@ -255,7 +255,7 @@ config GPROF
config GCOV
bool "Enable gcov support"
depends on DEBUGSYM
depends on DEBUG_INFO
help
This option allows developers to retrieve coverage data from a UML
session.
......
......@@ -13,12 +13,10 @@ OS := $(shell uname -s)
# EXTRAVERSION...
MODLIB := $(INSTALL_MOD_PATH)/lib/modules/$(KERNELRELEASE)
ifeq ($(CONFIG_DEBUGSYM),y)
ifeq ($(CONFIG_DEBUG_INFO),y)
CFLAGS := $(subst -fomit-frame-pointer,,$(CFLAGS))
endif
CFLAGS-$(CONFIG_DEBUGSYM) += -g
core-y += $(ARCH_DIR)/kernel/ \
$(ARCH_DIR)/drivers/ \
$(ARCH_DIR)/sys-$(SUBARCH)/
......
......@@ -329,7 +329,7 @@ CONFIG_NLS_DEFAULT="iso8859-1"
# Kernel hacking
#
# CONFIG_DEBUG_SLAB is not set
# CONFIG_DEBUGSYM is not set
# CONFIG_DEBUG_INFO is not set
# CONFIG_PT_PROXY is not set
# CONFIG_GPROF is not set
# CONFIG_GCOV is not set
......@@ -399,7 +399,7 @@ CONFIG_MTD_BLKMTD=m
#
# CONFIG_DEBUG_SLAB is not set
# CONFIG_DEBUG_SPINLOCK is not set
CONFIG_DEBUGSYM=y
CONFIG_DEBUG_INFO=y
CONFIG_FRAME_POINTER=y
CONFIG_PT_PROXY=y
# CONFIG_GPROF is not set
......
......@@ -540,6 +540,15 @@ config INIT_DEBUG
Fill __init and __initdata at the end of boot. This helps debugging
illegal uses of __init and __initdata after initialization.
config DEBUG_INFO
bool "Compile the kernel with debug info"
depends on DEBUG_KERNEL
help
If you say Y here the resulting kernel image will include
debugging info resulting in a larger kernel image.
Say Y here only if you plan to use gdb to debug the kernel.
If you don't debug the kernel, you can say N.
config FRAME_POINTER
bool "Compile the kernel with frame pointers"
help
......
......@@ -13,6 +13,18 @@ obj-$(CONFIG_LOGO_SUPERH_MONO) += logo_superh_mono.o
obj-$(CONFIG_LOGO_SUPERH_VGA16) += logo_superh_vga16.o
obj-$(CONFIG_LOGO_SUPERH_CLUT224) += logo_superh_clut224.o
# Dependencies on generated files need to be listed explicitly
$(obj)/%_mono.o: $(src)/%_mono.c
$(obj)/%_vga16.o: $(src)/%_vga16.c
$(obj)/%_clut224.o: $(src)/%_clut224.c
$(obj)/%_gray256.o: $(src)/%_gray256.c
# How to generate them
$(obj)/%_mono.c: $(src)/%_mono.pbm
$(objtree)/scripts/pnmtologo -t mono -n $*_mono -o $@ $<
......
......@@ -12,15 +12,11 @@ obj-y := open.o read_write.o file_table.o buffer.o \
filesystems.o namespace.o seq_file.o xattr.o libfs.o \
fs-writeback.o mpage.o direct-io.o aio.o
obj-$(CONFIG_EPOLL) += eventpoll.o
obj-$(CONFIG_EPOLL) += eventpoll.o
obj-$(CONFIG_COMPAT) += compat.o
obj-$(CONFIG_COMPAT) += compat.o
ifneq ($(CONFIG_NFSD),n)
ifneq ($(CONFIG_NFSD),)
obj-y += nfsctl.o
endif
endif
nfsd-$(CONFIG_NFSD) := nfsctl.o
obj-y += $(nfsd-y) $(nfsd-m)
obj-$(CONFIG_BINFMT_AOUT) += binfmt_aout.o
obj-$(CONFIG_BINFMT_EM86) += binfmt_em86.o
......@@ -74,7 +70,7 @@ obj-$(CONFIG_LOCKD) += lockd/
obj-$(CONFIG_NLS) += nls/
obj-$(CONFIG_SYSV_FS) += sysv/
obj-$(CONFIG_SMB_FS) += smbfs/
obj-$(CONFIG_CIFS) += cifs/
obj-$(CONFIG_CIFS) += cifs/
obj-$(CONFIG_NCP_FS) += ncpfs/
obj-$(CONFIG_HPFS_FS) += hpfs/
obj-$(CONFIG_NTFS_FS) += ntfs/
......
/*
initramfs_data includes the compressed binary that is the
filesystem used for early user space.
Note: Older versions of "as" (prior to binutils 2.11.90.0.23
released on 2001-07-14) dit not support .incbin.
If you are forced to use older binutils than that then the
following trick can be applied to create the resulting binary:
ld -m elf_i386 --format binary --oformat elf32-i386 -r \
-T initramfs_data.scr initramfs_data.cpio.gz -o initramfs_data.o
ld -m elf_i386 -r -o built-in.o initramfs_data.o
initramfs_data.scr looks like this:
SECTIONS
{
.init.ramfs : { *(.data) }
}
The above example is for i386 - the parameters vary from architectures.
Eventually look up LDFLAGS_BLOB in an older version of the
arch/$(ARCH)/Makefile to see the flags used before .incbin was introduced.
Using .incbin has the advantage over ld that the correct flags are set
in the ELF header, as required by certain architectures.
*/
.section .init.ramfs,"a"
.incbin "usr/initramfs_data.cpio.gz"
This diff is collapsed.
......@@ -37,7 +37,7 @@
%}
IDENT [A-Za-z_][A-Za-z0-9_]*
IDENT [A-Za-z_\$][A-Za-z0-9_\$]*
O_INT 0[0-7]*
D_INT [1-9][0-9]*
......
......@@ -28,4 +28,4 @@ if [ -n "$t1" ]; then
else
t7=0
fi
$3 --source --adjust-vma=$t7 $1
$3 -r --source --adjust-vma=$t7 $1
#!/usr/bin/perl
use strict;
## Copyright (C) Michael Still (mikal@stillhq.com)
## Released under the terms of the GNU GPL
##
## A script to make or install the manpages extracted by split-man
##
## Arguements: $1 -- the word "convert" or "install"
## $2 -- the directory containing the SGML files for the manpages
## $3 -- the filename which contained the sgmldoc output
## (I need this so I know which manpages to convert)
my($LISTING);
if($ARGV[0] eq ""){
die "Usage: makeman [convert | install] <dir> <file>\n";
}
if( ! -d "$ARGV[1]" ){
die "Output directory \"$ARGV[1]\" does not exist\n";
}
if($ARGV[0] eq "convert"){
open LISTING, "grep \"<refentrytitle>\" $ARGV[2] |";
while(<LISTING>){
s/<\/.*$//;
s/^.*>//;
s/\.sgml//;
s/struct //;
s/typedef //;
chomp;
print "Processing $_\n";
system("cd $ARGV[1]; docbook2man $_.sgml; gzip -f $_.9\n");
}
}
elsif($ARGV[0] eq "install"){
system("mkdir -p /usr/local/man/man9/; install $ARGV[1]/*.9.gz /usr/local/man/man9/");
}
else{
die "Usage: makeman [convert | install] <dir> <file>\n";
}
print "Done\n";
#!/usr/bin/perl
use strict;
## Copyright (C) Michael Still (mikal@stillhq.com)
## Released under the terms of the GNU GPL
##
## Hoon through the specified DocBook SGML file, and split out the
## man pages. These can then be processed into groff format, and
## installed if desired...
##
## Arguements: $1 -- the name of the sgml file
## $2 -- the directory to put the generated SGML files in
## $3 -- kernel version
my($SGML, $REF, $front, $refdata, $mode, $filename);
if(($ARGV[0] eq "") || ($ARGV[1] eq "") || ($ARGV[2] eq "")){
die "Usage: split-man <sgml file> <output dir> <kernel version>\n";
}
open SGML, "< $ARGV[0]" or die "Could not open input file \"$ARGV[0]\"\n";
if( ! -d "$ARGV[1]" ){
die "Output directory \"$ARGV[1]\" does not exist\n";
}
# Possible modes:
# 0: Looking for input I care about
# 1: Inside book front matter
# 2: Inside a refentry
# 3: Inside a refentry, and we know the filename
$mode = 0;
$refdata = "";
$front = "";
while(<SGML>){
# Starting modes
if(/<legalnotice>/){
$mode = 1;
}
elsif(/<refentry>/){
$mode = 2;
}
elsif(/<refentrytitle><phrase[^>]*>([^<]*)<.*$/){
$mode = 3;
$filename = $1;
$filename =~ s/struct //;
$filename =~ s/typedef //;
print "Found manpage for $filename\n";
open REF, "> $ARGV[1]/$filename.sgml" or
die "Couldn't open output file \"$ARGV[1]/$filename.sgml\": $!\n";
print REF "<!DOCTYPE refentry PUBLIC \"-//Davenport//DTD DocBook V3.0//EN\">\n\n";
print REF "$refdata";
$refdata = "";
}
# Extraction
if($mode == 1){
$front = "$front$_";
}
elsif($mode == 2){
$refdata = "$refdata$_";
}
elsif($mode == 3){
# There are some fixups which need to be applied
if(/<\/refmeta>/){
print REF "<manvolnum>9</manvolnum>\n";
}
if(/<\/refentry>/){
$front =~ s/<legalnotice>//;
$front =~ s/<\/legalnotice>//;
print REF <<EOF;
<refsect1><title>About this document</title>
$front
<para>
If you have comments on the formatting of this manpage, then please contact
Michael Still (mikal\@stillhq.com).
</para>
<para>
This documentation was generated with kernel version $ARGV[2].
</para>
</refsect1>
EOF
}
# For some reason, we title the synopsis twice in the main DocBook
if(! /<title>Synopsis<\/title>/){
if(/<refentrytitle>/){
s/struct //;
s/typedef //;
}
print REF "$_";
}
}
# Ending modes
if(/<\/legalnotice>/){
$mode = 0;
}
elsif(/<\/refentry>/){
$mode = 0;
close REF;
}
}
# And make sure we don't process this unnessesarily
$ARGV[0] =~ s/\.sgml/.9/;
`touch $ARGV[0]`;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment