aboutsummaryrefslogtreecommitdiff
path: root/libraries/allegro4/doinst.sh
diff options
context:
space:
mode:
authorPeter Wang <novalazy@gmail.com>2015-06-14 22:07:53 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2015-06-14 22:09:01 +0700
commit4689b00db89248843d64c4d2ccb86424c74d4148 (patch)
tree78bf342fd55839b7871ab794973705c0e5e14789 /libraries/allegro4/doinst.sh
parent6e5a0ff4fd0a105e3c91e56ed3755514dacbb8e6 (diff)
libraries/allegro4: Added (game programming library).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'libraries/allegro4/doinst.sh')
-rw-r--r--libraries/allegro4/doinst.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/libraries/allegro4/doinst.sh b/libraries/allegro4/doinst.sh
new file mode 100644
index 000000000000..5e444b85f3fe
--- /dev/null
+++ b/libraries/allegro4/doinst.sh
@@ -0,0 +1,14 @@
+config() {
+ NEW="$1"
+ OLD="$(dirname $NEW)/$(basename $NEW .new)"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
+ # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+config etc/allegro.cfg.new