Submitted by: vincent-opdarw@vinc17.org
Reviewed by:  markd@opendarwin.org
Approved by:  markd@opendarwin.org
Obtained from:
Committed patch for darwin and ui_msg's to tell people to use h2ph to
create perl headers.

git-svn-id: https://svn.macports.org/repository/macports/trunk/dports@17345 d073be05-634f-4543-b044-5fe20cf6d1d6
This commit is contained in:
Mark Duling
2006-04-07 04:20:48 +00:00
parent 2b5217ff37
commit bf6f39a981
2 changed files with 27 additions and 1 deletions
+12 -1
View File
@@ -1,4 +1,4 @@
# $Id: Portfile,v 1.1 2005/01/26 07:40:35 blb Exp $
# $Id: Portfile,v 1.2 2006/04/07 04:20:46 markd Exp $
PortSystem 1.0
PortGroup perl5 1.0
@@ -13,4 +13,15 @@ long_description This routine displays information on a file system such \
ways. If all fails, it croaks.
platforms darwin
checksums md5 b95651483e0234db33561a53708e007d
patchfiles patch-lib-Filesys-Diskspace.pm
post-install {
ui_msg "\n
To use Filesys::Diskspace some .ph Perl header files are required. They
may be generated using .h C header files with the following commands:
cd /usr/include
sudo h2ph sys/*
\n"
}
@@ -0,0 +1,15 @@
--- /lib/Filesys/DiskSpace.pm.org 1999-09-05 22:41:22.000000000 +0000
+++ lib/Filesys/DiskSpace.pm 2005-08-03 01:38:45.000000000 +0000
@@ -89,10 +89,9 @@
$res = syscall (&main::SYS_statfs, $dir, $fmt);
# statfs...
- if ($^O eq 'freebsd') {
+ if ($^O eq 'freebsd' || $^O eq 'darwin') {
# only tested with FreeBSD 3.0. Should also work with 4.0.
- my ($f1, $f2);
- ($f1, $bsize, $f2, $blocks, $bfree, $bavail, $files, $ffree) =
+ (undef, $bsize, undef, $blocks, $bfree, $bavail, $files, $ffree) =
unpack "L8", $fmt;
$type = 0; # read it from 'f_type' field ?
}