1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-11-28 11:20:38 +02:00
openwrt-xburst/target/linux/adm8668/image/Makefile
juhosg c363d3b566 adm8668: use a suffix for initramfs images
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31478 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-04-25 18:53:46 +00:00

40 lines
970 B
Makefile

#
# Copyright (C) 2010 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/image.mk
VMLINUX:=$(BIN_DIR)/$(IMG_PREFIX)-vmlinux
ifeq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),y)
VMLINUX:=$(BIN_DIR)/$(IMG_PREFIX)-vmlinux-initramfs
endif
define Build/Clean
$(MAKE) -C lzma-loader clean
endef
define Image/Prepare
cat $(KDIR)/vmlinux | $(STAGING_DIR_HOST)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 > $(KDIR)/vmlinux.lzma
$(MAKE) -C lzma-loader \
KDIR="$(KDIR)" \
clean compile
rm -f $(KDIR)/fs_mark
touch $(KDIR)/fs_mark
$(call prepare_generic_squashfs,$(KDIR)/fs_mark)
endef
define Image/Build
./my-mkimage $(KDIR)/loader.bin $(KDIR)/root.squashfs \
$(KDIR)/fs_mark $(BIN_DIR)/$(IMG_PREFIX)-$(1).bin
endef
define Image/BuildKernel
cp $(KDIR)/vmlinux.elf $(VMLINUX).elf
cp $(KDIR)/vmlinux $(VMLINUX).bin
endef
$(eval $(call BuildImage))