new package: add package 'initramfs' for building a shared linked initramfs

Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
Stephan Raue 2011-05-18 01:16:47 +02:00
parent d9ed48a459
commit 4fae2dfe37
3 changed files with 49 additions and 3 deletions

40
packages/initramfs/meta Normal file
View File

@ -0,0 +1,40 @@
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2011 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
PKG_NAME="initramfs"
PKG_VERSION=""
PKG_REV="1"
PKG_ARCH="any"
PKG_LICENSE="GPL"
PKG_SITE="http://www.openelec.tv"
PKG_URL=""
PKG_DEPENDS="eglibc-initramfs busybox-initramfs plymouth-lite diskdev_cmds-initramfs"
PKG_BUILD_DEPENDS="toolchain eglibc-initramfs busybox-initramfs plymouth-lite"
PKG_PRIORITY="optional"
PKG_SECTION="initramfs"
PKG_SHORTDESC="initramfs: Metapackage for installing initramfs"
PKG_LONGDESC="debug is a Metapackage for installing initramfs"
PKG_IS_ADDON="no"
PKG_AUTORECONF="no"
if [ "$HFSTOOLS" = "yes" ]; then
PKG_DEPENDS="$PKG_DEPENDS diskdev_cmds-initramfs"
fi

View File

@ -22,8 +22,13 @@
. config/options $1
export INSTALL=$(kernel_path)/initramfs
$SCRIPTS/install busybox-initramfs
# export INSTALL=$(kernel_path)/initramfs
export INSTALL=$ROOT/$BUILD/image/initramfs/root-image
$SCRIPTS/install initramfs
cd $INSTALL
find . | cpio -H newc -ov -R 0:0 > $ROOT/$BUILD/image/initramfs.cpio
cd -
if [ "$BOOTLOADER" = "u-boot" ]; then
$SCRIPTS/build u-boot

View File

@ -37,7 +37,8 @@ sed -i -e "s|^HOSTCC[[:space:]]*=.*$|HOSTCC = $HOST_CC|" \
$LINUX/Makefile
cp $KERNEL_CFG_FILE $LINUX/.config
sed -i -e "s|^CONFIG_INITRAMFS_SOURCE=.*$|CONFIG_INITRAMFS_SOURCE=\"$ROOT/$PKG_DIR/config/initramfs\"|" \
#sed -i -e "s|^CONFIG_INITRAMFS_SOURCE=.*$|CONFIG_INITRAMFS_SOURCE=\"$ROOT/$PKG_DIR/config/initramfs\"|" \
sed -i -e "s|^CONFIG_INITRAMFS_SOURCE=.*$|CONFIG_INITRAMFS_SOURCE=\"$ROOT/$BUILD/image/initramfs.cpio\"|" \
$LINUX/.config
# copy some extra firmware to linux tree