[PATCH] patching lorax to work with F17 usrmove

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---
 docs/fedora-livemedia.ks                       |   28 ++++++------
 share/config_files/common/profile              |    2 +-
 share/config_files/common/sshd_config.anaconda |    2 +-
 share/runtime-cleanup.tmpl                     |   52 +++++++++++++-----------
 share/runtime-postinstall.tmpl                 |   12 +++---
 src/sbin/livemedia-creator                     |    2 +-
 6 files changed, 51 insertions(+), 47 deletions(-)

diff --git a/docs/fedora-livemedia.ks b/docs/fedora-livemedia.ks
index 667b560..5ab5b29 100644
--- a/docs/fedora-livemedia.ks
+++ b/docs/fedora-livemedia.ks
@@ -40,7 +40,7 @@ part swap --size=1000
 %post
 # FIXME: it'd be better to get this installed from a package
 cat > /etc/rc.d/init.d/livesys << EOF
-#!/bin/bash
+#!/usr/bin/bash
 #
 # live: Init script for live image
 #
@@ -92,7 +92,7 @@ fi
 mountPersistentHome() {
   # support label/uuid
   if [ "\${homedev##LABEL=}" != "\${homedev}" -o "\${homedev##UUID=}" != "\${homedev}" ]; then
-    homedev=\`/sbin/blkid -o device -t "\$homedev"\`
+    homedev=\`/usr/sbin/blkid -o device -t "\$homedev"\`
   fi
 
   # if we're given a file rather than a blockdev, loopback it
@@ -109,7 +109,7 @@ mountPersistentHome() {
   fi
 
   # if it's encrypted, we need to unlock it
-  if [ "\$(/sbin/blkid -s TYPE -o value \$homedev 2>/dev/null)" = "crypto_LUKS" ]; then
+  if [ "\$(/usr/sbin/blkid -s TYPE -o value \$homedev 2>/dev/null)" = "crypto_LUKS" ]; then
     echo
     echo "Setting up encrypted /home device"
     plymouth ask-for-password --command="cryptsetup luksOpen \$homedev EncHome"
@@ -121,7 +121,7 @@ mountPersistentHome() {
   # if we have /home under what's passed for persistent home, then
   # we should make that the real /home.  useful for mtd device on olpc
   if [ -d /home/home ]; then mount --bind /home/home /home ; fi
-  [ -x /sbin/restorecon ] && /sbin/restorecon /home
+  [ -x /usr/sbin/restorecon ] && /usr/sbin/restorecon /home
   if [ -d /home/liveuser ]; then USERADDARGS="-M" ; fi
 }
 
@@ -150,7 +150,7 @@ fi
 mount -t tmpfs -o mode=0755 varcacheyum /var/cache/yum
 mount -t tmpfs tmp /tmp
 mount -t tmpfs vartmp /var/tmp
-[ -x /sbin/restorecon ] && /sbin/restorecon /var/cache/yum /tmp /var/tmp >/dev/null 2>&1
+[ -x /usr/sbin/restorecon ] && /usr/sbin/restorecon /var/cache/yum /tmp /var/tmp >/dev/null 2>&1
 
 if [ -n "\$configdone" ]; then
   exit 0
@@ -208,27 +208,27 @@ sed -i -e 's/hwclock/no-such-hwclock/g' /etc/rc.d/init.d/halt
 
 # and hack so that we eject the cd on shutdown if we're using a CD...
 if strstr "\`cat /proc/cmdline\`" CDLABEL= ; then
-  cat >> /sbin/halt.local << FOE
+  cat >> /usr/sbin/halt.local << FOE
 #!/bin/bash
 # XXX: This often gets stuck during shutdown because /etc/init.d/halt
 #      (or something else still running) wants to read files from the block\
 #      device that was ejected.  Disable for now.  Bug #531924
 # we want to eject the cd on halt, but let's also try to avoid
 # io errors due to not being able to get files...
-#cat /sbin/halt > /dev/null
-#cat /sbin/reboot > /dev/null
+#cat /usr/sbin/halt > /dev/null
+#cat /usr/sbin/reboot > /dev/null
 #/usr/sbin/eject -p -m \$(readlink -f /dev/live) >/dev/null 2>&1
 #echo "Please remove the CD from your drive and press Enter to finish restarting"
 #read -t 30 < /dev/console
 FOE
-chmod +x /sbin/halt.local
+chmod +x /usr/sbin/halt.local
 fi
 
 EOF
 
 # bah, hal starts way too late
 cat > /etc/rc.d/init.d/livesys-late << EOF
-#!/bin/bash
+#!/usr/bin/bash
 #
 # live: Late init script for live image
 #
@@ -283,12 +283,12 @@ fi
 EOF
 
 chmod 755 /etc/rc.d/init.d/livesys
-/sbin/restorecon /etc/rc.d/init.d/livesys
-/sbin/chkconfig --add livesys
+/usr/sbin/restorecon /etc/rc.d/init.d/livesys
+/usr/sbin/chkconfig --add livesys
 
 chmod 755 /etc/rc.d/init.d/livesys-late
-/sbin/restorecon /etc/rc.d/init.d/livesys-late
-/sbin/chkconfig --add livesys-late
+/usr/sbin/restorecon /etc/rc.d/init.d/livesys-late
+/usr/sbin/chkconfig --add livesys-late
 
 # work around for poor key import UI in PackageKit
 rm -f /var/lib/rpm/__db*
diff --git a/share/config_files/common/profile b/share/config_files/common/profile
index 00a475e..3311944 100644
--- a/share/config_files/common/profile
+++ b/share/config_files/common/profile
@@ -1,3 +1,3 @@
 PS1="[anaconda \u@\h \W]\\$ "
-PATH=/bin:/sbin:/usr/bin:/usr/sbin:/mnt/sysimage/sbin:/mnt/sysimage/usr/sbin:/mnt/sysimage/bin:/mnt/sysimage/usr/bin
+PATH=/usr/bin:/usr/sbin:/mnt/sysimage/usr/sbin:/mnt/sysimage/usr/bin
 export PATH PS1
diff --git a/share/config_files/common/sshd_config.anaconda b/share/config_files/common/sshd_config.anaconda
index 0c0404c..a230ee8 100644
--- a/share/config_files/common/sshd_config.anaconda
+++ b/share/config_files/common/sshd_config.anaconda
@@ -8,7 +8,7 @@ StrictModes yes
 X11Forwarding yes
 X11DisplayOffset 10
 PrintMotd yes
-XAuthLocation /sbin/xauth
+XAuthLocation /usr/sbin/xauth
 KeepAlive yes
 SyslogFacility AUTHPRIV
 RSAAuthentication yes
diff --git a/share/runtime-cleanup.tmpl b/share/runtime-cleanup.tmpl
index e7aed0e..d7711e9 100644
--- a/share/runtime-cleanup.tmpl
+++ b/share/runtime-cleanup.tmpl
@@ -130,7 +130,7 @@ removefrom audit /etc/* /sbin/audispd /sbin/auditctl /sbin/aureport
 removefrom audit /sbin/ausearch /sbin/autrace /usr/bin/*
 removefrom audit-libs /etc/* /${libdir}/libauparse*
 removefrom authconfig /usr/sbin/* /usr/share/*
-removefrom bash /etc/* /usr/bin/* /usr/share/*
+removefrom bash /etc/* /usr/bin/bashbug* /usr/share/*
 removefrom bind-libs-lite /usr/${libdir}/libirs*
 removefrom bind-libs-lite /usr/${libdir}/libisccfg-export*
 removefrom bind-utils /usr/bin/dig /usr/bin/host /usr/bin/nsupdate
@@ -139,8 +139,8 @@ removefrom btrfs-progs /sbin/btrfs /sbin/btrfs-* /sbin/btrfstune
 removefrom ca-certificates /etc/pki/java/*
 removefrom ca-certificates /etc/pki/tls/certs/ca-bundle.trust.crt /etc/ssl/*
 removefrom cairo /usr/${libdir}/libcairo-script*
-removefrom coreutils /etc/* /bin/link /bin/nice /bin/stty /bin/su /bin/unlink
-removefrom coreutils /sbin/* /usr/bin/[ /usr/bin/base64 /usr/bin/chcon
+removefrom coreutils /etc/* /usr/bin/link /usr/bin/nice /usr/bin/stty /usr/bin/su /usr/bin/unlink
+removefrom coreutils /usr/sbin/runuser /usr/bin/[ /usr/bin/base64 /usr/bin/chcon
 removefrom coreutils /usr/bin/cksum /usr/bin/comm /usr/bin/csplit /usr/bin/cut
 removefrom coreutils /usr/bin/dir /usr/bin/dircolors /usr/bin/dirname
 removefrom coreutils /usr/bin/expand /usr/bin/factor /usr/bin/fmt
@@ -168,7 +168,7 @@ removefrom dbus-x11 /etc/X11/*
 removefrom dejavu-sans-fonts --allbut *.conf */DejaVuSans{,-Bold}.ttf
 removefrom dejavu-sans-mono-fonts --allbut *.conf */DejaVuSansMono.ttf
 removefrom device-mapper-multipath /etc/* /sbin/mpathconf /sbin/multipathd
-removefrom dhclient /usr/*
+removefrom dhclient /usr/lib/* /usr/share/*
 removefrom dnsmasq /etc/rc.d/* /usr/sbin/*
 removefrom dosfstools /sbin/dosfsck /sbin/fsck.*
 removefrom dump /etc/*
@@ -185,7 +185,7 @@ removefrom findutils /usr/bin/oldfind /usr/share/*
 removefrom firstboot /lib/systemd/* /usr/sbin/* /usr/share/firstboot/*
 removefrom firstboot /usr/share/locale/*
 removefrom fontconfig /usr/bin/*
-removefrom gawk /usr/bin/* /usr/libexec/* /usr/share/*
+removefrom gawk /usr/bin/{igawk,pgawk} /usr/libexec/* /usr/share/*
 removefrom gdk-pixbuf2 /usr/share/locale*
 removefrom gfs2-utils /usr/sbin/*
 removefrom glib2 /etc/* /usr/bin/* /usr/share/locale/*
@@ -218,17 +218,21 @@ removefrom gtk2 /usr/bin/update-gtk-immodules
 removefrom gtk3 /usr/bin/update-gtk-immodules
 removefrom gtk3 /usr/share/* /usr/${libdir}/gtk-3.0/*
 removefrom gtk3 /usr/${libdir}/libgailutil*
-removefrom gzip /usr/bin/*
+removefrom gzip /usr/bin/{gzexe,zcmp,zdiff,zegrep,zfgrep,zforce,zgrep,zless,zmore,znew}
 removefrom hwdata /etc/* /usr/share/hwdata/oui.txt /usr/share/hwdata/pnp.ids
 removefrom hwdata /usr/share/hwdata/upgradelist
 removefrom initscripts /etc/ppp/* /usr/sbin/* /usr/share/locale/*
 removefrom iproute /etc/* /sbin/cbq /sbin/ifcfg /sbin/rtmon /sbin/tc /usr/*
-removefrom iputils /etc/* /bin/ping6 /bin/tracepath* /sbin/ifenslave
-removefrom iputils /sbin/rdisc /usr/sbin/*
+removefrom iputils /etc/* /usr/bin/ping6 /usr/bin/tracepath* /usr/sbin/ifenslave
+removefrom iputils /usr/sbin/*
 removefrom iscsi-initiator-utils /etc/rc.d/*
 removefrom jfsutils /sbin/jfs_fsck /sbin/jfs_fscklog /sbin/jfs_logdump
 removefrom jfsutils /sbin/jfs_mkfs
-removefrom kbd /bin/* /usr/share/locale/*
+removefrom kbd \
+    /usr/bin/{chvt,deallocvt,fgconsole,getkeycodes,kbdinfo,kbdrate,loadunimap,\
+        mapscrn,open,openvt,psfaddtable,psfgettable,psfstriptable,psfxtable,\
+        setkeycodes,setleds,setmetamode,setvtrgb,showconsolefont,showkey} \
+    /usr/share/locale/*
 removefrom krb5-libs /etc/* /${libdir}/libgssrpc* /usr/${libdir}/*
 removefrom less /etc/*
 removefrom libX11-common /usr/share/X11/XErrorDB
@@ -250,7 +254,7 @@ removefrom libmlx4 /etc/rdma/* /usr/${libdir}/*
 removefrom libnotify /usr/bin/*
 removefrom libpng /usr/${libdir}/libpng.*
 removefrom librsvg2 /usr/bin/*
-removefrom libselinux /sbin/*
+removefrom libselinux /usr/sbin/*
 removefrom libsemanage /etc/selinux/*
 removefrom libstdc++ /usr/share/*
 removefrom libthai /usr/share/libthai/*
@@ -266,17 +270,17 @@ removefrom lvm2 /etc/*
 removefrom lzo /usr/${libdir}/liblzo2.*
 removefrom madan-fonts /usr/share/fonts/madan/*
 removefrom mdadm /etc/*
-removefrom module-init-tools /etc/* /sbin/insmod.static /sbin/weak-modules
-removefrom mt-st /etc/* /sbin/*
+removefrom module-init-tools /etc/* /usr/sbin/insmod.static /usr/sbin/weak-modules
+removefrom mt-st /etc/* /usr/sbin/*
 removefrom mtools /etc/*
 removefrom ncurses /usr/bin/captoinfo /usr/bin/infocmp /usr/bin/infotocap
 removefrom ncurses /usr/bin/reset /usr/bin/tabs /usr/bin/tic /usr/bin/toe
 removefrom ncurses /usr/bin/tput /usr/bin/tset
 removefrom ncurses-libs /usr/${libdir}/libform* /usr/${libdir}/libmenu*
 removefrom ncurses-libs /usr/${libdir}/libpanel.* /usr/${libdir}/libtic*
-removefrom net-tools /bin/netstat /etc/ethers /sbin/ether-wake /sbin/ipmaddr
-removefrom net-tools /sbin/iptunnel /sbin/mii-diag /sbin/mii-tool /sbin/nameif
-removefrom net-tools /sbin/plipconfig /sbin/slattach /usr/share/locale/*
+removefrom net-tools /usr/bin/netstat /etc/ethers /usr/sbin/ether-wake /usr/sbin/ipmaddr
+removefrom net-tools /usr/sbin/iptunnel /usr/sbin/mii-diag /usr/sbin/mii-tool /usr/sbin/nameif
+removefrom net-tools /usr/sbin/plipconfig /usr/sbin/slattach /usr/share/locale/*
 removefrom newt /usr/share/locale/*
 removefrom nfs-utils /etc/nfsmount.conf
 removefrom nfs-utils /etc/rc.d/init.d/* /lib/systemd/system/*
@@ -290,17 +294,17 @@ removefrom nfs-utils /usr/sbin/showmount /usr/sbin/sm-notify
 removefrom nfs-utils /usr/sbin/start-statd /var/lib/nfs/etab
 removefrom nfs-utils /var/lib/nfs/rmtab /var/lib/nfs/state /var/lib/nfs/xtab
 removefrom nss-softokn /usr/${libdir}/nss/*
-removefrom ntfs-3g --allbut /sbin/mount.ntfs* /${libdir}/*
-removefrom ntfsprogs --allbut /sbin/ntfsresize
+removefrom ntfs-3g --allbut /usr/sbin/mount.ntfs* /${libdir}/*
+removefrom ntfsprogs --allbut /usr/sbin/ntfsresize
 removefrom openldap /etc/openldap/* /usr/${libdir}/libldap_r-*
 removefrom openssh /etc/ssh/* /usr/libexec/*
 removefrom openssh-clients /etc/ssh/* /usr/bin/slogin /usr/bin/ssh-*
 removefrom openssh-clients /usr/${libdir}/* /usr/libexec/*
 removefrom openssh-server /etc/ssh/* /usr/${libdir}/* /usr/libexec/*
 removefrom openssl /etc/pki/* /usr/bin/* /usr/${libdir}/openssl/*
-removefrom pam /sbin/* /usr/share/locale/*
+removefrom pam /usr/sbin/* /usr/share/locale/*
 removefrom pciutils /usr/sbin/*
-removefrom pcmciautils /sbin/*
+removefrom pcmciautils /usr/sbin/*
 removefrom pcre /usr/bin/* /usr/${libdir}/*
 removefrom policycoreutils /etc/* /usr/bin/* /usr/share/locale/*
 removefrom polkit /usr/bin/*
@@ -310,7 +314,7 @@ removefrom procps /usr/bin/free /usr/bin/pgrep /usr/bin/pkill
 removefrom procps /usr/bin/pmap /usr/bin/pwdx /usr/bin/skill /usr/bin/slabtop
 removefrom procps /usr/bin/snice /usr/bin/tload /usr/bin/uptime
 removefrom procps /usr/bin/vmstat /usr/bin/w /usr/bin/watch
-removefrom psmisc /sbin/* /usr/share/locale/*
+removefrom psmisc /usr/share/locale/*
 removefrom pygtk2 /usr/bin/* /usr/${libdir}/pygtk/*
 removefrom pykickstart /usr/bin/* /usr/share/locale/*
 removefrom python-bugzilla /usr/bin/*
@@ -333,14 +337,14 @@ removefrom tar /usr/share/locale/*
 removefrom un-core-dotum-fonts /usr/share/fonts/un-core/UnDotumBold.ttf
 removefrom usbutils /usr/bin/*
 removefrom util-linux --allbut \
-    /bin/{dmesg,kill,login,lsblk,more,mount,umount,mountpoint} \
+    /usr/bin/{dmesg,kill,login,lsblk,more,mount,umount,mountpoint} \
     /etc/mtab /etc/pam.d/login /etc/pam.d/remote \
-    /sbin/{agetty,blkid,blockdev,clock,fdisk,fsck,fstrim,hwclock,losetup} \
-    /sbin/{mkswap,nologin,sfdisk,swapoff,swapon,wipefs} \
+    /usr/sbin/{agetty,blkid,blockdev,clock,fdisk,fsck,fstrim,hwclock,losetup} \
+    /usr/sbin/{mkswap,nologin,sfdisk,swapoff,swapon,wipefs} \
     /usr/bin/logger
 removefrom volume_key-libs /usr/share/locale/*
 removefrom wget /etc/* /usr/share/locale/*
-removefrom xfsprogs --allbut /sbin/* /usr/sbin/xfs_{admin,check,copy,db}
+removefrom xfsprogs --allbut /usr/sbin/{fsck.xfs,mkfs.xfs,xfs_repair} /usr/sbin/xfs_{admin,check,copy,db}
 removefrom xkeyboard-config /usr/share/locale/*
 removefrom xorg-x11-drv-intel /usr/${libdir}/libI*
 removefrom xorg-x11-drv-openchrome /usr/${libdir}/libchrome*
diff --git a/share/runtime-postinstall.tmpl b/share/runtime-postinstall.tmpl
index 9b69455..38fd043 100644
--- a/share/runtime-postinstall.tmpl
+++ b/share/runtime-postinstall.tmpl
@@ -46,7 +46,7 @@ removefrom initscripts /lib/systemd/system/fedora* /lib/systemd/fedora*
 removefrom lvm2 /lib/systemd/system/*
 removefrom mdadm /lib/systemd/system/*
 ## finally, make /init -> /sbin/init symlink
-symlink /sbin/init init
+symlink /usr/sbin/init init
 
 ## install some basic configuration files
 append etc/resolv.conf ""
@@ -67,15 +67,15 @@ install ${configdir}/pam.sshd etc/pam.d/login
 install ${configdir}/pam.sshd etc/pam.d/remote
 
 ## set up "install" user account
-append etc/passwd "install:x:0:0:root:/root:/sbin/loader"
+append etc/passwd "install:x:0:0:root:/root:/usr/sbin/loader"
 append etc/shadow "install::14438:0:99999:7:::"
 ## remove root password
 replace "root:\*:" "root::" etc/shadow
 
 ## s390-specific setup
 %if basearch in ("s390", "s390x"):
-    remove sbin/init
-    move usr/share/anaconda/linuxrc.s390 sbin/init
+    remove usr/sbin/init
+    move usr/share/anaconda/linuxrc.s390 usr/sbin/init
     ## generate ssh keys
     runcmd ssh-keygen -q -C "" -N "" -t rsa1 -f ${root}/etc/ssh/ssh_host_key
     runcmd ssh-keygen -q -C "" -N "" -t rsa  -f ${root}/etc/ssh/ssh_host_rsa_key
@@ -99,9 +99,9 @@ gconfset /desktop/gnome/interface/accessibility bool true
 gconfset /desktop/gnome/interface/at-spi-corba bool true
 
 ## get_anaconda_portions()
-move usr/${libdir}/anaconda/loader sbin
+move usr/${libdir}/anaconda/loader usr/sbin
 move usr/share/anaconda/loader.tr etc
-move usr/libexec/anaconda/auditd sbin
+move usr/libexec/anaconda/auditd usr/sbin
 
 ## for compatibility with Ancient Anaconda Traditions
 symlink lib/modules /modules
diff --git a/src/sbin/livemedia-creator b/src/sbin/livemedia-creator
index 4a4576e..de90c41 100755
--- a/src/sbin/livemedia-creator
+++ b/src/sbin/livemedia-creator
@@ -464,7 +464,7 @@ def make_livecd( disk_img, squashfs_args="", templatedir=None,
         # Link /images to work_dir/images to make the templates happy
         if os.path.islink( joinpaths( installroot, "images" ) ):
             os.unlink( joinpaths( installroot, "images" ) )
-        subprocess.check_call(["/bin/ln", "-s", joinpaths( work_dir, "images" ),
+        subprocess.check_call(["/usr/bin/ln", "-s", joinpaths( work_dir, "images" ),
                                                 joinpaths( installroot, "images" )])
 
         tb = TreeBuilder( product=product, arch=arch,
-- 
1.7.6.5

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux