From c1280b74c328395ec8c01fa00e77803de1418ead Mon Sep 17 00:00:00 2001 From: sroracle Date: Wed, 14 Jun 2017 02:46:39 -0400 Subject: main/awstats: fix default include path If awstats is called as /usr/bin/awstats.pl, @PossibleLibDir (see e.g. line 2236 in awstats.pl) will be ( "/usr/bin/lib", "/usr/share/awstats/lib" ), neither of which exist on alpine. Add sed to change /usr/share/awstats to /usr/lib/awstats/cgi-bin in order to properly find the /lang, /lib, and /plugins directories in /cgi-bin when called from /usr/bin. --- main/awstats/APKBUILD | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'main/awstats') diff --git a/main/awstats/APKBUILD b/main/awstats/APKBUILD index 746e2230f4..7ad1f95f0f 100644 --- a/main/awstats/APKBUILD +++ b/main/awstats/APKBUILD @@ -20,6 +20,11 @@ prepare() { sed -e "s:/usr/local/$pkgname/wwwroot:/usr/lib/$pkgname:g" \ -i "$file" done + for file in wwwroot/cgi-bin/*; do + [ -f "${file}" ] || continue + sed -e "s:/usr/share/$pkgname:/usr/lib/$pkgname/cgi-bin:g" \ + -i "$file" + done } package() { -- cgit v1.2.3