Ajout Makefile stage0
[hvlinux.git] / stage2 / post-install
index 3e65624..74122ad 100755 (executable)
@@ -1,5 +1,4 @@
 #!/bin/bash
-set -o errexit
 
 # Reading system configuration informations, functions and package versions.
 source ../sysinfos
@@ -32,4 +31,20 @@ chown -v root:root /tmp
 chown -v root:root /var
 chown -v root:root /var/log
 
+# Removing /tools from PATH:
+SED_REP='/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/bin'
+sed -i -e "s!^\(PATH=\).*tools.*!\1${SED_REP}!" /etc/profile
+
+# Removing /tools directory
+if [ -d /tools ]; then
+    DEST=/usr/src/tools
+    if [ -d ${DEST} ]; then
+        # Remove old backup
+        rm -rf ${DEST}
+    fi
+    mv /tools ${DEST}
+fi
+
+ldconfig
+
 exit $?