aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenato Botelho <garga@FreeBSD.org>2015-04-28 10:45:18 -0300
committerRenato Botelho <garga@FreeBSD.org>2015-04-28 10:45:18 -0300
commit578824e9239e2d414aa899b51557e6c5a10dec69 (patch)
treef8c9ad6413f6f67c8fd0df8da496fc588760710a
parente936ec53eeea5c41c4b53459c8f5954f84cd2bad (diff)
downloadpfsense-packages-578824e9239e2d414aa899b51557e6c5a10dec69.tar.gz
pfsense-packages-578824e9239e2d414aa899b51557e6c5a10dec69.tar.bz2
pfsense-packages-578824e9239e2d414aa899b51557e6c5a10dec69.zip
Sanitize bandwidthd version, add port_category, run_depends and fix pbi checking
-rw-r--r--config/bandwidthd/bandwidthd.inc11
-rw-r--r--pkg_config.10.xml5
2 files changed, 9 insertions, 7 deletions
diff --git a/config/bandwidthd/bandwidthd.inc b/config/bandwidthd/bandwidthd.inc
index b7ef3bbd..ac5cc116 100644
--- a/config/bandwidthd/bandwidthd.inc
+++ b/config/bandwidthd/bandwidthd.inc
@@ -31,18 +31,17 @@
// Check pfSense version
$pfs_version = substr(trim(file_get_contents("/etc/version")),0,3);
switch ($pfs_version) {
- case "1.2":
- case "2.0":
- define('PKG_BANDWIDTHD_BASE', '/usr/local/bandwidthd');
- define('PKG_BANDWIDTHD_RUNTIME_LIBRARY_ENV', '');
- break;
case "2.1":
define('PKG_BANDWIDTHD_BASE', '/usr/pbi/bandwidthd-' . php_uname("m") . '/bandwidthd');
define('PKG_BANDWIDTHD_RUNTIME_LIBRARY_ENV', '');
break;
- default:
+ case "2.2":
define('PKG_BANDWIDTHD_BASE', '/usr/pbi/bandwidthd-' . php_uname("m") . '/local/bandwidthd');
define('PKG_BANDWIDTHD_RUNTIME_LIBRARY_ENV', 'LD_LIBRARY_PATH=/usr/pbi/bandwidthd-' . php_uname("m") . '/local/lib');
+ break;
+ default:
+ define('PKG_BANDWIDTHD_BASE', '/usr/local/bandwidthd');
+ define('PKG_BANDWIDTHD_RUNTIME_LIBRARY_ENV', '');
}
// End: Check pfSense version
diff --git a/pkg_config.10.xml b/pkg_config.10.xml
index 97b11385..c63af681 100644
--- a/pkg_config.10.xml
+++ b/pkg_config.10.xml
@@ -887,12 +887,15 @@
<website>http://bandwidthd.sourceforge.net/</website>
<descr>BandwidthD tracks usage of TCP/IP network subnets and builds html files with graphs to display utilization. Charts are built by individual IPs, and by default display utilization over 2 day, 8 day, 40 day, and 400 day periods. Furthermore, each ip address's utilization can be logged out at intervals of 3.3 minutes, 10 minutes, 1 hour or 12 hours in cdf format, or to a backend database server. HTTP, TCP, UDP, ICMP, VPN, and P2P traffic are color coded.</descr>
<category>System</category>
- <version>2.0.1_6 pkg v.0.5</version>
+ <version>0.5</version>
<status>BETA</status>
<required_version>2.2</required_version>
<depends_on_package_pbi>bandwidthd-2.0.1_6-##ARCH##.pbi</depends_on_package_pbi>
<config_file>https://packages.pfsense.org/packages/config/bandwidthd/bandwidthd.xml</config_file>
<configurationfile>bandwidthd.xml</configurationfile>
+ <port_category>net-mgmt</port_category>
+ <port_uses>pgsql</port_uses>
+ <run_depends>bandwidthd/bandwidthd:net-mgmt/bandwidthd</run_depends>
<build_pbi>
<ports_before>net/libpcap databases/postgresql91-client graphics/gd</ports_before>
<port>net-mgmt/bandwidthd</port>