CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
Switched from uImage to zImage. Now uImage is generated by uboot's repository.
authorJose V Beneyto <sepen@crux.nu>
Thu, 3 Nov 2011 10:28:06 +0000 (11:28 +0100)
committerJose V Beneyto <sepen@crux.nu>
Thu, 3 Nov 2011 10:28:06 +0000 (11:28 +0100)
Makefile

index 9b0893d44e41303dee756a9b6a7aa3efb9b021f9..f05f578b05f049be0cc273850068ce162aafd6d0 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -4,9 +4,9 @@
 
 TARGET = arm-crux-linux-gnueabi
 
-TOPDIR = $(shell pwd)
+PWD = $(shell pwd)
 WORK = $(PWD)/work
-CROSSTOOLS = $(TOPDIR)/../../toolchain/crosstools
+CROSSTOOLS = $(PWD)/../../toolchain/crosstools
 
 KERNEL_VERSION = 2.6.31.14.27-efikamx_20111026
 
@@ -17,34 +17,31 @@ all: image modules map
 clean: image-clean modules-clean map-clean
 
 distclean: clean image-distclean modules-distclean map-distclean
-       rm -vrf $(WORK)/linux-$(KERNEL_VERSION)
-
-$(WORK)/mkimage: 
-       wget -P $(WORK) http://crux-arm.nu/files/distfiles/mkimage
-       chmod u+x $(WORK)/mkimage
 
 $(WORK)/linux-$(KERNEL_VERSION).tar.bz2:
        wget -P $(WORK) http://crux-arm.nu/files/distfiles/efikamx/linux-$(KERNEL_VERSION).tar.bz2
 
-$(WORK)/linux-$(KERNEL_VERSION): $(TOPDIR)/config-$(KERNEL_VERSION) $(WORK)/mkimage $(WORK)/linux-$(KERNEL_VERSION).tar.bz2
+$(WORK)/linux-$(KERNEL_VERSION): $(WORK)/linux-$(KERNEL_VERSION).tar.bz2 $(PWD)/config-$(KERNEL_VERSION)
        tar -C $(WORK) -xvjf $(WORK)/linux-$(KERNEL_VERSION).tar.bz2
-       cp -v $(TOPDIR)/config-$(KERNEL_VERSION) $(WORK)/linux-$(KERNEL_VERSION)/.config
+       cp -v $(PWD)/config-$(KERNEL_VERSION) $(WORK)/linux-$(KERNEL_VERSION)/.config
        touch $(WORK)/linux-$(KERNEL_VERSION)
 
-$(WORK)/uImage-$(KERNEL_VERSION): $(WORK)/linux-$(KERNEL_VERSION)
+$(WORK)/zImage-$(KERNEL_VERSION): $(WORK)/linux-$(KERNEL_VERSION)
        cd $(WORK)/linux-$(KERNEL_VERSION) && \
-               export PATH=$(CROSSTOOLS)/bin:$(WORK):$$PATH && \
+               export PATH=$(CROSSTOOLS)/bin:$$PATH && \
                export LD_LIBRARY_PATH=$(CROSSTOOLS)/lib:$$LD_LIBRARY_PATH && \
-               make uImage ARCH=arm CROSS_COMPILE=$(TARGET)- 
-       cp -v $(WORK)/linux-$(KERNEL_VERSION)/arch/arm/boot/uImage $(WORK)/uImage-$(KERNEL_VERSION)
-       touch $(WORK)/uImage-$(KERNEL_VERSION)
+               make zImage ARCH=arm CROSS_COMPILE=$(TARGET)- 
+       cp -v $(WORK)/linux-$(KERNEL_VERSION)/arch/arm/boot/zImage $(WORK)/zImage-$(KERNEL_VERSION)
+       ln -sf zImage-$(KERNEL_VERSION) $(WORK)/zImage
+       touch $(WORK)/zImage-$(KERNEL_VERSION)
 
-image: $(WORK)/uImage-$(KERNEL_VERSION)
+image: $(WORK)/zImage-$(KERNEL_VERSION)
 
 image-clean:
-       rm -vf $(WORK)/uImage-$(KERNEL_VERSION)
+       rm -vf $(WORK)/zImage-$(KERNEL_VERSION)
 
 image-distclean: image-clean
+       rm -vrf $(WORK)/linux-$(KERNEL_VERSION) $(WORK)/linux-$(KERNEL_VERSION).tar.bz2
 
 $(WORK)/modules-$(KERNEL_VERSION): $(WORK)/linux-$(KERNEL_VERSION)
        cd $(WORK)/linux-$(KERNEL_VERSION) && \