diff options
Diffstat (limited to 'arch/i386')
-rw-r--r-- | arch/i386/Makefile | 10 | ||||
-rw-r--r-- | arch/i386/boot/Makefile | 2 | ||||
-rw-r--r-- | arch/i386/boot/install.sh | 14 |
3 files changed, 21 insertions, 5 deletions
diff --git a/arch/i386/Makefile b/arch/i386/Makefile index b84119f9cc63..d3c0409d201c 100644 --- a/arch/i386/Makefile +++ b/arch/i386/Makefile | |||
@@ -37,7 +37,10 @@ CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) | |||
37 | # CPU-specific tuning. Anything which can be shared with UML should go here. | 37 | # CPU-specific tuning. Anything which can be shared with UML should go here. |
38 | include $(srctree)/arch/i386/Makefile.cpu | 38 | include $(srctree)/arch/i386/Makefile.cpu |
39 | 39 | ||
40 | cflags-$(CONFIG_REGPARM) += -mregparm=3 | 40 | # -mregparm=3 works ok on gcc-3.0 and later |
41 | # | ||
42 | cflags-$(CONFIG_REGPARM) += $(shell if [ $(call cc-version) -ge 0300 ] ; then \ | ||
43 | echo "-mregparm=3"; fi ;) | ||
41 | 44 | ||
42 | # Disable unit-at-a-time mode, it makes gcc use a lot more stack | 45 | # Disable unit-at-a-time mode, it makes gcc use a lot more stack |
43 | # due to the lack of sharing of stacklots. | 46 | # due to the lack of sharing of stacklots. |
@@ -100,7 +103,7 @@ AFLAGS += $(mflags-y) | |||
100 | boot := arch/i386/boot | 103 | boot := arch/i386/boot |
101 | 104 | ||
102 | .PHONY: zImage bzImage compressed zlilo bzlilo \ | 105 | .PHONY: zImage bzImage compressed zlilo bzlilo \ |
103 | zdisk bzdisk fdimage fdimage144 fdimage288 install kernel_install | 106 | zdisk bzdisk fdimage fdimage144 fdimage288 install |
104 | 107 | ||
105 | all: bzImage | 108 | all: bzImage |
106 | 109 | ||
@@ -122,8 +125,7 @@ zdisk bzdisk: vmlinux | |||
122 | fdimage fdimage144 fdimage288: vmlinux | 125 | fdimage fdimage144 fdimage288: vmlinux |
123 | $(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(KBUILD_IMAGE) $@ | 126 | $(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(KBUILD_IMAGE) $@ |
124 | 127 | ||
125 | install: vmlinux | 128 | install: |
126 | install kernel_install: | ||
127 | $(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(KBUILD_IMAGE) install | 129 | $(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(KBUILD_IMAGE) install |
128 | 130 | ||
129 | archclean: | 131 | archclean: |
diff --git a/arch/i386/boot/Makefile b/arch/i386/boot/Makefile index 1e71382d413a..0fea75dd4e31 100644 --- a/arch/i386/boot/Makefile +++ b/arch/i386/boot/Makefile | |||
@@ -100,5 +100,5 @@ zlilo: $(BOOTIMAGE) | |||
100 | cp System.map $(INSTALL_PATH)/ | 100 | cp System.map $(INSTALL_PATH)/ |
101 | if [ -x /sbin/lilo ]; then /sbin/lilo; else /etc/lilo/install; fi | 101 | if [ -x /sbin/lilo ]; then /sbin/lilo; else /etc/lilo/install; fi |
102 | 102 | ||
103 | install: $(BOOTIMAGE) | 103 | install: |
104 | sh $(srctree)/$(src)/install.sh $(KERNELRELEASE) $< System.map "$(INSTALL_PATH)" | 104 | sh $(srctree)/$(src)/install.sh $(KERNELRELEASE) $< System.map "$(INSTALL_PATH)" |
diff --git a/arch/i386/boot/install.sh b/arch/i386/boot/install.sh index f17b40dfc0f4..5e44c736eea8 100644 --- a/arch/i386/boot/install.sh +++ b/arch/i386/boot/install.sh | |||
@@ -19,6 +19,20 @@ | |||
19 | # $4 - default install path (blank if root directory) | 19 | # $4 - default install path (blank if root directory) |
20 | # | 20 | # |
21 | 21 | ||
22 | verify () { | ||
23 | if [ ! -f "$1" ]; then | ||
24 | echo "" 1>&2 | ||
25 | echo " *** Missing file: $1" 1>&2 | ||
26 | echo ' *** You need to run "make" before "make install".' 1>&2 | ||
27 | echo "" 1>&2 | ||
28 | exit 1 | ||
29 | fi | ||
30 | } | ||
31 | |||
32 | # Make sure the files actually exist | ||
33 | verify "$2" | ||
34 | verify "$3" | ||
35 | |||
22 | # User may have a custom install script | 36 | # User may have a custom install script |
23 | 37 | ||
24 | if [ -x ~/bin/${CROSS_COMPILE}installkernel ]; then exec ~/bin/${CROSS_COMPILE}installkernel "$@"; fi | 38 | if [ -x ~/bin/${CROSS_COMPILE}installkernel ]; then exec ~/bin/${CROSS_COMPILE}installkernel "$@"; fi |