2009-06-11 12:26:54 +00:00
# initrd template
# create required directories
2009-09-08 08:11:06 +00:00
makedir @initrd@/lib
makedir @initrd@/modules
makedir @initrd@/firmware
link @initrd@/lib/modules to ../modules
link @initrd@/lib/firmware to ../firmware
2009-06-11 12:26:54 +00:00
makedir @initrd@/sbin
makedir @initrd@/dev
makedir @initrd@/etc
makedir @initrd@/etc/udev/rules.d
makedir @initrd@/lib/udev/rules.d
makedir @initrd@/proc
makedir @initrd@/selinux
makedir @initrd@/sys
makedir @initrd@/etc/terminfo/a
makedir @initrd@/etc/terminfo/d
makedir @initrd@/etc/terminfo/l
makedir @initrd@/etc/terminfo/s
makedir @initrd@/etc/terminfo/v
makedir @initrd@/etc/terminfo/x
makedir @initrd@/etc/terminfo/g
makedir @initrd@/tmp
makedir @initrd@/usr/libexec
makedir @initrd@/usr/@libdir@/NetworkManager
makedir @initrd@/usr/share/dbus-1/system-services
makedir @initrd@/var/cache/hald
makedir @initrd@/var/lib/dbus
makedir @initrd@/var/lib/dhclient
makedir @initrd@/var/lock/rpm
makedir @initrd@/var/run
makedir @initrd@/var/run/dbus
makedir @initrd@/var/run/hald
makedir @initrd@/var/run/NetworkManager
makedir @initrd@/etc/dbus-1/system.d
makedir @initrd@/etc/modprobe.d
makedir @initrd@/etc/NetworkManager/dispatcher.d
makedir @initrd@/@libdir@/dbus-1
makedir @initrd@/etc/sysconfig/network-scripts
makedir @initrd@/usr/share/PolicyKit/policy
makedir @initrd@/etc/PolicyKit
makedir @initrd@/var/lib/misc
makedir @initrd@/etc/hal/fdi
makedir @initrd@/usr/share/hal/fdi
makedir @initrd@/usr/share/hwdata
makedir @initrd@/etc/rc.d/init.d
makedir @initrd@/usr/sbin
makedir @initrd@/var/run/wpa_supplicant
# set the buildarch
edit @initrd@/etc/arch text "@buildarch@"
# copy etc stuff
2009-09-04 11:34:04 +00:00
copy @instroot@ etc/passwd to @initrd@ etc
chmod @initrd@/etc/passwd mode 0644
copy @instroot@ etc/group to @initrd@ etc
chmod @initrd@/etc/group mode 0644
copy @instroot@ etc/nsswitch.conf to @initrd@ etc
chmod @initrd@/etc/nsswitch.conf mode 0644
copy @instroot@ etc/hosts to @initrd@ etc
chmod @initrd@/etc/hosts mode 0644
2009-06-11 12:26:54 +00:00
# copy mount/umount
2009-09-04 11:34:04 +00:00
copy @instroot@ bin/mount to @initrd@ sbin
copy @instroot@ bin/umount to @initrd@ sbin
copy @instroot@ sbin/mount.* to @initrd@ sbin
copy @instroot@ sbin/umount.* to @initrd@ sbin
2009-06-11 12:26:54 +00:00
# copy udev
2009-09-04 11:34:04 +00:00
copy @instroot@ sbin/udevd to @initrd@ sbin
copy @instroot@ sbin/udevadm to @initrd@ sbin
2009-09-08 08:11:06 +00:00
link @initrd@/sbin/udevinfo to udevadm
link @initrd@/sbin/udevsettle to udevadm
2009-06-11 12:26:54 +00:00
# udev rules
2009-09-04 11:34:04 +00:00
copy @instroot@ etc/udev/udev.conf to @initrd@ etc/udev
chmod @initrd@/etc/udev/udev.conf mode 0644
copy @instroot@ lib/udev/* to @initrd@ lib/udev
2009-09-08 08:11:06 +00:00
#chmod @initrd@/lib/udev/* mode 0644
2009-09-04 11:34:04 +00:00
2009-06-11 12:26:54 +00:00
remove @initrd@/lib/udev/rules.d/*persistent*
remove @initrd@/lib/udev/rules.d/*generator*
2009-09-04 11:34:04 +00:00
copy @instroot@ etc/udev/rules.d/*.rules to @initrd@ etc/udev/rules.d
chmod @initrd@/etc/udev/rules.d/*.rules mode 0644
2009-06-11 12:26:54 +00:00
# copy bash
2009-09-04 11:34:04 +00:00
copy @instroot@ bin/bash to @initrd@ sbin
2009-06-11 12:26:54 +00:00
link @initrd@/sbin/sh to bash
2009-09-04 11:34:04 +00:00
copy @instroot@ sbin/consoletype to @initrd@ sbin
copy @instroot@ usr/bin/logger to @initrd@ sbin
copy @instroot@ etc/rc.d/init.d/functions to @initrd@ etc/rc.d/init.d
copy @instroot@ etc/sysconfig/network-scripts/network-functions* to @initrd@ etc/sysconfig/network-scripts
2009-06-11 12:26:54 +00:00
link @initrd@/etc/init.d to /etc/rc.d/init.d
# dhcp and dhcpv6 client daemons and support programs
2009-09-04 11:34:04 +00:00
copy @instroot@ sbin/dhclient to @initrd@ sbin
copy @instroot@ sbin/dhclient-script to @initrd@ sbin
copy @instroot@ sbin/dhcp6c to @initrd@ sbin
copy @instroot@ sbin/arping to @initrd@ sbin
copy @instroot@ sbin/ifconfig to @initrd@ sbin
copy @instroot@ sbin/ip to @initrd@ sbin
copy @instroot@ bin/ipcalc to @initrd@ sbin
copy @instroot@ bin/hostname to @initrd@ sbin
copy @instroot@ sbin/ethtool to @initrd@ sbin
copy @instroot@ sbin/route to @initrd@ sbin
2009-06-11 12:26:54 +00:00
touch @initrd@/etc/resolv.conf
# hwdata
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/share/hwdata/pci.ids to @initrd@ usr/share/hwdata
copy @instroot@ usr/share/hwdata/usb.ids to @initrd@ usr/share/hwdata
2009-06-11 12:26:54 +00:00
# hal
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/sbin/hald to @initrd@ sbin
copy @instroot@ usr/libexec/hald-runner to @initrd@ usr/libexec
copy @instroot@ usr/libexec/hald-generate-fdi-cache to @initrd@ usr/libexec
copy @instroot@ usr/libexec/hal*storage* to @initrd@ usr/libexec
2009-06-11 12:26:54 +00:00
touch @initrd@/var/run/hald.acl-list
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/share/hal/fdi/* to @initrd@ usr/share/hal/fdi
copy @instroot@ etc/hal/fdi/* to @initrd@ etc/hal/fdi
copy @instroot@ etc/dbus-1/system.d/hal.conf to @initrd@ etc/dbus-1/system.d
2009-06-11 12:26:54 +00:00
# policykit
2009-09-04 11:34:04 +00:00
copy @instroot@ etc/PolicyKit/PolicyKit.conf to @initrd@ etc/PolicyKit
copy @instroot@ usr/share/dbus-1/system-services/org.freedesktop.PolicyKit.service to @initrd@ usr/share/dbus-1/system-services
copy @instroot@ usr/share/PolicyKit/policy/org.freedesktop.policykit.policy to @initrd@ usr/share/PolicyKit/policy
copy @instroot@ var/lib/misc/PolicyKit.reload to @initrd@ var/lib/misc
2009-06-11 12:26:54 +00:00
# dbus
2009-09-04 11:34:04 +00:00
copy @instroot@ bin/dbus-uuidgen to @initrd@ sbin
copy @instroot@ bin/dbus-daemon to @initrd@ sbin
copy @instroot@ etc/dbus-1/system.conf to @initrd@ etc/dbus-1
copy @instroot@ @libdir@/dbus-1/dbus-daemon-launch-helper to @initrd@ @libdir@/dbus-1
2009-06-11 12:26:54 +00:00
chown @initrd@/@libdir@/dbus-1/dbus-daemon-launch-helper user root group dbus
chmod @initrd@/@libdir@/dbus-1/dbus-daemon-launch-helper mode 04750
# wpa_supplicant
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/sbin/wpa_passphrase to @initrd@ usr/sbin
copy @instroot@ usr/sbin/wpa_supplicant to @initrd@ usr/sbin
copy @instroot@ etc/dbus-1/system.d/wpa_supplicant.conf to @initrd@ etc/dbus-1/system.d
copy @instroot@ etc/wpa_supplicant/wpa_supplicant.conf to @initrd@ etc/wpa_supplicant
copy @instroot@ usr/share/dbus-1/system-services/fi.epitest.hostap.WPASupplicant.service to @initrd@ usr/share/dbus-1/system-services
2009-06-11 12:26:54 +00:00
# networkmanager
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/sbin/NetworkManager to @initrd@ usr/sbin
copy @instroot@ usr/sbin/nm-system-settings to @initrd@ usr/sbin
copy @instroot@ etc/dbus-1/system.d/nm-*.conf to @initrd@ etc/dbus-1/system.d
copy @instroot@ etc/dbus-1/system.d/NetworkManager.conf to @initrd@ etc/dbus-1/system.d
copy @instroot@ etc/NetworkManager/nm-system-settings.conf to @initrd@ etc/NetworkManager
copy @instroot@ usr/@libdir@/NetworkManager/libnm-settings-plugin-ifcfg-fedora.so to @initrd@ usr/@libdir@/NetworkManager
copy @instroot@ usr/libexec/nm-* to @initrd@ usr/libexec
copy @instroot@ usr/share/dbus-1/system-services/org.freedesktop.NetworkManagerSystemSettings.service to @initrd@ usr/share/dbus-1/system-services
copy @instroot@ usr/share/dbus-1/system-services/org.freedesktop.nm_dispatcher.service to @initrd@ usr/share/dbus-1/system-services
2009-06-11 12:26:54 +00:00
# modprobe
2009-09-04 11:34:04 +00:00
copy @instroot@ sbin/modprobe to @initrd@ sbin
copy @instroot@ sbin/insmod to @initrd@ sbin
copy @instroot@ sbin/rmmod to @initrd@ sbin
2009-06-11 12:26:54 +00:00
# profile
edit @initrd@/.profile text "PATH=/bin:/usr/bin:/usr/sbin:/mnt/sysimage/sbin:/mnt/sysimage/usr/sbin:/mnt/sysimage/bin:/mnt/sysimage/usr/bin\nexport PATH"
# terminfos
2009-09-07 11:06:24 +00:00
copy @instroot@ usr/share/terminfo/a/ansi to @initrd@ etc/terminfo/a nolinks
copy @instroot@ usr/share/terminfo/d/dumb to @initrd@ etc/terminfo/d nolinks
copy @instroot@ usr/share/terminfo/l/linux to @initrd@ etc/terminfo/l nolinks
copy @instroot@ usr/share/terminfo/s/screen to @initrd@ etc/terminfo/s nolinks
copy @instroot@ usr/share/terminfo/v/vt100 to @initrd@ etc/terminfo/v nolinks
copy @instroot@ usr/share/terminfo/v/vt100-nav to @initrd@ etc/terminfo/v nolinks
copy @instroot@ usr/share/terminfo/v/vt102 to @initrd@ etc/terminfo/v nolinks
copy @instroot@ usr/share/terminfo/x/xterm to @initrd@ etc/terminfo/x nolinks
copy @instroot@ usr/share/terminfo/x/xterm-color to @initrd@ etc/terminfo/x nolinks
copy @instroot@ usr/share/terminfo/g/gnome to @initrd@ etc/terminfo/g nolinks
2009-09-04 11:34:04 +00:00
chmod @initrd@/etc/terminfo/*/* mode 0644
2009-06-11 12:26:54 +00:00
# misc
2009-09-04 11:34:04 +00:00
copy @instroot@ bin/awk to @initrd@ sbin
copy @instroot@ bin/gawk to @initrd@ sbin
copy @instroot@ bin/egrep to @initrd@ sbin
copy @instroot@ bin/fgrep to @initrd@ sbin
copy @instroot@ bin/grep to @initrd@ sbin
copy @instroot@ bin/kill to @initrd@ sbin
copy @instroot@ bin/ln to @initrd@ sbin
copy @instroot@ bin/readlink to @initrd@ sbin
copy @instroot@ bin/rm to @initrd@ sbin
copy @instroot@ bin/rmdir to @initrd@ sbin
copy @instroot@ bin/sed to @initrd@ sbin
copy @instroot@ bin/sleep to @initrd@ sbin
copy @instroot@ bin/touch to @initrd@ sbin
2009-08-19 14:51:32 +00:00
2009-06-11 12:26:54 +00:00
link @initrd@/init to /sbin/init
link @initrd@/etc/mtab to /proc/mounts
link @initrd@/bin to sbin
link @initrd@/var/lib/xkb to ../../tmp
# loader
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/lib/anaconda-runtime/loader/loader to @initrd@ sbin
copy @instroot@ usr/lib/anaconda-runtime/loader/loader.tr to @initrd@ etc
chmod @initrd/etc/loader.tr mode 0644
2009-06-11 12:26:54 +00:00
# indirect dependencies
2009-09-08 08:11:06 +00:00
copy @instroot@ @libdir@/ld-linux.so.2 to @initrd@ @libdir@
#copy @instroot@ @libdir@/libcom_err.so.2 to @initrd@ @libdir@
#copy @instroot@ @libdir@/libdbus-glib-1.so.2 to @initrd@ @libdir@
#copy @instroot@ @libdir@/libfreebl3.so to @initrd@ @libdir@
copy @instroot@ @libdir@/libgcc_s.so.1 to @initrd@ @libdir@
2009-09-04 11:34:04 +00:00
copy @instroot@ @libdir@/libnss_dns.so.2 to @initrd@ @libdir@
copy @instroot@ @libdir@/libnss_files.so.2 to @initrd@ @libdir@
2009-09-08 08:11:06 +00:00
copy @instroot@ @libdir@/libsoftokn3.so to @initrd@ @libdir@
copy @instroot@ usr/@libdir@/libsqlite3.so.0 to @initrd@ usr/@libdir@
2009-06-11 12:26:54 +00:00
# langtable
2009-09-04 11:34:04 +00:00
copy @instroot@ usr/lib/anaconda/lang-table to @initrd@ etc