diff options
author | Renato Botelho <garga@FreeBSD.org> | 2015-04-24 16:20:47 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2015-04-24 16:20:47 -0300 |
commit | 88c066ff18638844cebc166eca9caba425950c4d (patch) | |
tree | e8ba06a6c3312f372318b0fac65856c66bd739c9 /config | |
parent | dfd227e89fab0089e9555bb9927a42684fe0860c (diff) | |
download | pfsense-packages-88c066ff18638844cebc166eca9caba425950c4d.tar.gz pfsense-packages-88c066ff18638844cebc166eca9caba425950c4d.tar.bz2 pfsense-packages-88c066ff18638844cebc166eca9caba425950c4d.zip |
Sanitize mailscanner version, add port_category, run_depends and fix pbi detection
Diffstat (limited to 'config')
-rw-r--r-- | config/mailscanner/mailscanner.inc | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/config/mailscanner/mailscanner.inc b/config/mailscanner/mailscanner.inc index 8418c85c..62905091 100644 --- a/config/mailscanner/mailscanner.inc +++ b/config/mailscanner/mailscanner.inc @@ -33,11 +33,16 @@ require_once("globals.inc"); #require("guiconfig.inc"); $pf_version=substr(trim(file_get_contents("/etc/version")),0,3); -define('MAILSCANNER_PREFIX', '/usr/pbi/mailscanner-' . php_uname("m")); -if ($pf_version == "2.1") - define('MAILSCANNER_LOCALBASE', MAILSCANNER_PREFIX); -else - define('MAILSCANNER_LOCALBASE', MAILSCANNER_PREFIX . '/local'); +if ($pf_version == "2.1" || $pf_version == "2.2") { + define('MAILSCANNER_PREFIX', '/usr/pbi/mailscanner-' . php_uname("m")); + if ($pf_version == "2.1") + define('MAILSCANNER_LOCALBASE', MAILSCANNER_PREFIX); + else + define('MAILSCANNER_LOCALBASE', MAILSCANNER_PREFIX . '/local'); +} else { + define('MAILSCANNER_PREFIX', '/usr/local'); + define('MAILSCANNER_LOCALBASE', '/usr/local'); +} $uname=posix_uname(); if ($uname['machine']=='amd64') |