From 05f0a28932c1acab7a9ddb58435d69626dad54da Mon Sep 17 00:00:00 2001 From: Nezmer Date: Tue, 12 Oct 2010 02:23:16 +0300 Subject: Use sysconfdir, localstatedir, BASH instead of hardcoded values This applies to contrib/ files, our scripts, and the documentation. Dan: fix 'make clean' in contrib/ directory. Signed-off-by: Nezmer Signed-off-by: Dan McGee --- contrib/pacscripts.in | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'contrib/pacscripts.in') diff --git a/contrib/pacscripts.in b/contrib/pacscripts.in index 101fb15f..123c79df 100755 --- a/contrib/pacscripts.in +++ b/contrib/pacscripts.in @@ -1,4 +1,4 @@ -#!/bin/bash +#!@BASH@ # # pacscripts : tries to print out the {pre,post}_{install,remove,upgrade} # scripts of a given package @@ -27,7 +27,7 @@ set -o errexit progname=$(basename $0) progver="0.4" -conf="/etc/pacman.conf" +conf="@sysconfdir@/pacman.conf" if [ ! -r "$conf" ]; then echo "ERROR: unable to read $conf" @@ -36,8 +36,8 @@ fi eval $(awk '/DBPath/ {print $1$2$3}' "$conf") eval $(awk '/CacheDir/ {print $1$2$3}' "$conf") -pac_db="${DBPath:-/var/lib/pacman}/local" -pac_cache="${CacheDir:-/var/cache/pacman/pkg}" +pac_db="${DBPath:-@localstatedir@/lib/pacman}/local" +pac_cache="${CacheDir:-@localstatedir@/cache/pacman/pkg}" error() { local mesg=$1; shift -- cgit v1.2.3-54-g00ecf