summarylogtreecommitdiffstats
path: root/geant4-piidata.install
diff options
context:
space:
mode:
authorL.G. Sarmiento2015-06-14 19:40:14 +0200
committerL.G. Sarmiento2015-06-14 19:40:14 +0200
commit389932f2580ca33340368d89cd770f0a1136d584 (patch)
treea14f8b34ca6638e920cc9bb203038f8253da944f /geant4-piidata.install
downloadaur-389932f2580ca33340368d89cd770f0a1136d584.tar.gz
Initial import
Diffstat (limited to 'geant4-piidata.install')
-rw-r--r--geant4-piidata.install35
1 files changed, 35 insertions, 0 deletions
diff --git a/geant4-piidata.install b/geant4-piidata.install
new file mode 100644
index 00000000000..b4f0f3d6df4
--- /dev/null
+++ b/geant4-piidata.install
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+_varname='G4PIIDATA'
+_packagename='geant4-piidata'
+_foldername='G4PII'
+_dataversion=1.3
+
+_add() {
+ echo "export ${_varname}=/usr/share/${_packagename}/${_foldername}${_dataversion}" >> /etc/profile.d/geant4.sh
+ echo "setenv ${_varname} /usr/share/${_packagename}/${_foldername}${_dataversion}" >> /etc/profile.d/geant4.csh
+}
+
+_remove() {
+ sed -i "/${_varname}/d" /etc/profile.d/geant4.sh
+ sed -i "/${_varname}/d" /etc/profile.d/geant4.csh
+}
+
+pre_install() {
+ _remove
+}
+post_install() {
+ _add
+}
+pre_upgrade() {
+ _remove
+}
+post_upgrade() {
+ _add
+}
+pre_remove() {
+ _remove
+}
+post_remove() {
+ _remove
+}