Files
bpfire/lfs/initrd
ms 0db33b5671 Setup weiter ausgebaut.
Initrd des Installationssystems verkleinert.


git-svn-id: http://svn.ipfire.org/svn/ipfire/trunk@789 ea5c0bd1-69bd-2848-81d8-4f18e57aeed8
2007-08-20 13:21:16 +00:00

88 lines
3.7 KiB
Plaintext

###############################################################################
# This file is part of the IPCop Firewall. #
# #
# IPCop 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 of the License, or #
# (at your option) any later version. #
# #
# IPCop 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 IPCop; if not, write to the Free Software #
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA #
# #
# Makefiles are based on LFSMake, which is #
# Copyright (C) 2002 Rod Roard <rod@sunsetsystems.com> #
# #
###############################################################################
###############################################################################
# Definitions
###############################################################################
include Config
VER = ipfire
THISAPP = initrd
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(THISAPP)
###############################################################################
# Top-level Rules
###############################################################################
install : $(TARGET)
check :
download :
md5 :
###############################################################################
# Installation Details
###############################################################################
$(TARGET) :
@$(PREBUILD)
rm -f /install/images/initrd
# Finish up initrd directory
-mkdir -p /install/initrd/{dev,etc,mnt,root,lib/modules/$(KVER)-ipfire/kernel/drivers,cdrom,dev,harddisk,proc,tmp,usr/share/terminfo/l,var/run,sys} && \
cd /install/initrd/etc && rm -f fstab
cp -aRf $(DIR_SRC)/config/install/* /install/initrd/etc/
rm -rf /install/initrd/etc{,/udev,/udev/rules.d}/.svn
rm -rf /install/initrd/usr/share/man
chmod 755 /install/initrd/etc/halt /install/initrd/etc/rc
cp -f /usr/share/terminfo/l/linux /install/initrd/usr/share/terminfo/l
# make new dependencies
depmod -a -F /boot/System.map-$(KVER)-ipfire $(KVER)-ipfire
depmod -a -F /boot/System.map-$(KVER)-ipfire-smp $(KVER)-ipfire-smp
cp -a /lib/modules/$(KVER)-ipfire/ /install/initrd/lib/modules/
rm -rf /install/initrd/lib/modules/$(KVER)-ipfire/{build,source,misc/*,kernel/{crypro,sound,net}} \
/install/initrd/lib/modules/$(KVER)-ipfire/kernel/drivers/message/fusion/mptlan*
cp /opt/$(MACHINE)-uClibc/lib/libgcc_s.so.1 /install/initrd/lib/
cd /install/initrd/lib/ && ln -sf libgcc_s.so.1 libgcc_s.so
-mkdir -p /install/{images,mnt}
rm -rf /install/mnt/*
cp -aR /install/initrd/* /install/mnt
# make new dependencies
depmod -a -F /boot/System.map-$(KVER)-ipfire $(KVER)-ipfire
mksquashfs /install/initrd /install/images/initrd
cd /install/initrd && find ./ -ls > $(DIR_INFO)/_build.initrd.log
@$(POSTBUILD)