diff options
author | James <> | 2013-03-17 12:16:37 +0000 |
---|---|---|
committer | James <> | 2013-03-17 12:16:37 +0000 |
commit | 27b76ab0671089c47506615a796a261e993896a7 (patch) | |
tree | 61213d67e7fa87b20356b23798558e2c4212c42f /target/linux/adm8668/image/.svn | |
download | trunk-36060-master.tar.gz trunk-36060-master.tar.bz2 trunk-36060-master.zip |
Diffstat (limited to 'target/linux/adm8668/image/.svn')
4 files changed, 194 insertions, 0 deletions
diff --git a/target/linux/adm8668/image/.svn/entries b/target/linux/adm8668/image/.svn/entries new file mode 100644 index 0000000..db6d3ea --- /dev/null +++ b/target/linux/adm8668/image/.svn/entries @@ -0,0 +1,99 @@ +10 + +dir +36060 +svn://svn.openwrt.org/openwrt/trunk/target/linux/adm8668/image +svn://svn.openwrt.org/openwrt + + + +2012-04-25T18:53:48.453310Z +31479 +juhosg + + + + + + + + + + + + + + +3c298f89-4303-0410-b956-a3cf2f4a3e73 + +lzma-loader +dir + +Makefile +file + + + + +2013-03-17T12:12:22.000000Z +8f192d1eba8069715e2e9c319e2579c9 +2012-04-25T18:53:48.453310Z +31479 +juhosg + + + + + + + + + + + + + + + + + + + + + +1431 + +my-mkimage +file + + + + +2013-03-17T12:12:22.000000Z +80b3ef5d9940b28d7a375d64e549d5ad +2011-01-27T21:50:00.981354Z +25176 +florian +has-props + + + + + + + + + + + + + + + + + + + + +973 + diff --git a/target/linux/adm8668/image/.svn/prop-base/my-mkimage.svn-base b/target/linux/adm8668/image/.svn/prop-base/my-mkimage.svn-base new file mode 100644 index 0000000..869ac71 --- /dev/null +++ b/target/linux/adm8668/image/.svn/prop-base/my-mkimage.svn-base @@ -0,0 +1,5 @@ +K 14 +svn:executable +V 1 +* +END diff --git a/target/linux/adm8668/image/.svn/text-base/Makefile.svn-base b/target/linux/adm8668/image/.svn/text-base/Makefile.svn-base new file mode 100644 index 0000000..bc412a6 --- /dev/null +++ b/target/linux/adm8668/image/.svn/text-base/Makefile.svn-base @@ -0,0 +1,58 @@ +# +# 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 +UIMAGE:=$(IMG_PREFIX)-uImage +ifeq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),y) + VMLINUX:=$(BIN_DIR)/$(IMG_PREFIX)-vmlinux-initramfs + UIMAGE:=$(IMG_PREFIX)-uImage-initramfs +endif + +define kernel_entry +-a 0x80002000 -e 0x80002000 +endef + + +define CompressGzip + gzip -9 -c $(1) > $(2) +endef + +define MkImage + mkimage -A mips -O linux -T kernel $(call kernel_entry) -C $(1) $(2) \ + -n "ADM8668 Linux Kernel(2.4.31)" \ + -d $(3) $(4) +endef + +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 + $(call CompressGzip,$(KDIR)/vmlinux,$(KDIR)/vmlinux.bin.gz) + $(call MkImage,gzip,,$(KDIR)/vmlinux.bin.gz,$(BIN_DIR)/$(UIMAGE)-gzip.bin) +endef + +$(eval $(call BuildImage)) diff --git a/target/linux/adm8668/image/.svn/text-base/my-mkimage.svn-base b/target/linux/adm8668/image/.svn/text-base/my-mkimage.svn-base new file mode 100644 index 0000000..7ed6666 --- /dev/null +++ b/target/linux/adm8668/image/.svn/text-base/my-mkimage.svn-base @@ -0,0 +1,32 @@ +#!/bin/sh +# my-mkimage +# This will pad given files to 64k boundaries to make a single u-boot image. +# we have to be fancy because u-boot mkimage is going to add 64 byte header, ... +# and i only know basic arithmetic.. ;) +# +# Copyright (C) 2010 Scott Nicholas <neutronscott@scottn.us> +[ $# -lt 2 ] && { + echo usage: $0 loader.bin [rootfs.squashfs [fs_mark [...]]] output.bin +} + +OLDSIZE=$(stat -c%s $1) +NEWSIZE=$(((OLDSIZE / 65536 + 1) * 65536 - 64)) + +dd if=$1 of=vmlinuz.tmp bs=$NEWSIZE conv=sync >/dev/null 2>&1 +shift +appends=$(($# - 1)) +echo +while [ $appends -gt 0 ]; do + dd if=$1 of=temp bs=64k conv=sync >/dev/null 2>&1 + printf "### '%s' starts at 0x%x\n" "`basename $1`" "$((NEWSIZE+64))" + cat temp >>vmlinuz.tmp + shift + appends=$((appends-1)) + NEWSIZE=$(stat -c%s vmlinuz.tmp) +done +echo +../../../../staging_dir/host/bin/mkimage -A mips -O linux -T kernel \ +-C none -a 0x80400000 -e 0x80400000 -n "ADM8668 Linux Kernel(2.4.31)" \ +-d vmlinuz.tmp $1 + +rm temp vmlinuz.tmp |