Radix cross Linux

The main Radix cross Linux repository contains the build scripts of packages, which have the most complete and common functionality for desktop machines

452 Commits   2 Branches   1 Tag
   250         kx #!/bin/sh
   250         kx 
   250         kx # Preserve new files
   250         kx install_file() {
   250         kx   NEW="$1"
   250         kx   OLD="`dirname $NEW`/`basename $NEW .new`"
   250         kx   # If there's no file by that name, mv it over:
   250         kx   if [ ! -r $OLD ]; then
   250         kx     mv $NEW $OLD
   250         kx   elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy
   250         kx     rm $NEW
   250         kx   fi
   250         kx   # Otherwise, we leave the .new copy for the admin to consider...
   250         kx }
   250         kx 
   250         kx 
   250         kx # arg 1:  the new package version
   250         kx pre_install() {
   250         kx   /bin/true
   250         kx }
   250         kx 
   250         kx # arg 1:  the new package version
   250         kx post_install() {
   250         kx   # Run this if we are on an installed system. Otherwise it will be handled on first boot.
   250         kx   if [ -r proc/sys/kernel/osrelease -a ! -r /etc/system-installer -a -x /usr/bin/glib-compile-schemas ]; then
   250         kx     /usr/bin/glib-compile-schemas /usr/share-glib-2.0/schemas/       1> /dev/null 2> /dev/null
   250         kx   fi
   250         kx 
   250         kx   # Run this if we are on an installed system. Otherwise it will be handled on first boot.
   250         kx   if [ -r proc/sys/kernel/osrelease -a ! -r /etc/system-installer -a -x /usr/bin/update-gtk-immodules-3.0 ]; then
   250         kx     /usr/bin/update-gtk-immodules
   250         kx   fi
   250         kx }
   250         kx 
   250         kx # arg 1:  the new package version
   250         kx # arg 2:  the old package version
   250         kx pre_update() {
   250         kx   /bin/true
   250         kx }
   250         kx 
   250         kx # arg 1:  the new package version
   250         kx # arg 2:  the old package version
   250         kx post_update() {
   250         kx   post_install
   250         kx }
   250         kx 
   250         kx # arg 1:  the old package version
   250         kx pre_remove() {
   250         kx   /bin/true
   250         kx }
   250         kx 
   250         kx # arg 1:  the old package version
   250         kx post_remove() {
   250         kx   /bin/true
   250         kx }
   250         kx 
   250         kx 
   250         kx operation=$1
   250         kx shift
   250         kx 
   250         kx $operation $*