summaryrefslogtreecommitdiffstats
path: root/tools/templates/core_pkg/base/metadir/+INSTALL
diff options
context:
space:
mode:
Diffstat (limited to 'tools/templates/core_pkg/base/metadir/+INSTALL')
-rw-r--r--tools/templates/core_pkg/base/metadir/+INSTALL29
1 files changed, 29 insertions, 0 deletions
diff --git a/tools/templates/core_pkg/base/metadir/+INSTALL b/tools/templates/core_pkg/base/metadir/+INSTALL
new file mode 100644
index 0000000..895c39c
--- /dev/null
+++ b/tools/templates/core_pkg/base/metadir/+INSTALL
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+if [ "${2}" = "POST-INSTALL" ]; then
+ exit 0
+fi
+
+if [ ! -f /usr/local/share/%%PRODUCT_NAME%%/base.txz ]; then
+ echo "===> ERROR: base tarball not found!"
+ exit 1
+fi
+
+echo "===> Removing schg flag from base files"
+
+# Cleanup schg flags
+chflags -R noschg \
+ /bin \
+ /sbin \
+ /usr/bin \
+ /usr/sbin \
+ /libexec \
+ /lib \
+ /usr/lib >/dev/null 2>&1
+
+echo "===> Extracting new base tarball"
+
+# Install new base files
+tar -C / -xJPUf /usr/local/share/%%PRODUCT_NAME%%/base.txz
+
+exit $?
OpenPOWER on IntegriCloud