xfsprogs: update to 4.8.0
This commit is contained in:
parent
01f0124e14
commit
76ed55f542
|
@ -48,64 +48,6 @@
|
|||
|
||||
/* internal fshandle - typecast to a void for external use */
|
||||
#define FSHANDLE_SZ 8
|
||||
--- libxfs/linux.c.orig 2015-08-03 02:39:42.000000000 +0200
|
||||
+++ libxfs/linux.c 2015-10-03 21:17:50.262694871 +0200
|
||||
@@ -16,11 +16,8 @@
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
-#define ustat __kernel_ustat
|
||||
#include <mntent.h>
|
||||
#include <sys/stat.h>
|
||||
-#undef ustat
|
||||
-#include <sys/ustat.h>
|
||||
#include <sys/mount.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/sysinfo.h>
|
||||
@@ -51,9 +48,12 @@
|
||||
int
|
||||
platform_check_ismounted(char *name, char *block, struct stat64 *s, int verbose)
|
||||
{
|
||||
- /* Pad ust; pre-2.6.28 linux copies out too much in 32bit compat mode */
|
||||
- struct ustat ust[2];
|
||||
struct stat64 st;
|
||||
+ FILE *f;
|
||||
+ struct stat64 mst;
|
||||
+ struct mntent *mnt;
|
||||
+ char mounts[MAXPATHLEN];
|
||||
+ int ismounted = 0;
|
||||
|
||||
if (!s) {
|
||||
if (stat64(block, &st) < 0)
|
||||
@@ -63,14 +63,25 @@
|
||||
s = &st;
|
||||
}
|
||||
|
||||
- if (ustat(s->st_rdev, ust) >= 0) {
|
||||
+ strcpy(mounts, (!access(PROC_MOUNTED, R_OK)) ? PROC_MOUNTED : MOUNTED);
|
||||
+ if ((f = setmntent(mounts, "r")) == NULL)
|
||||
+ return 0;
|
||||
+
|
||||
+ while ((mnt = getmntent(f)) != NULL) {
|
||||
+ if (stat64(mnt->mnt_dir, &mst) < 0)
|
||||
+ continue;
|
||||
+ if (mst.st_dev != s->st_rdev)
|
||||
+ continue;
|
||||
+
|
||||
if (verbose)
|
||||
fprintf(stderr,
|
||||
_("%s: %s contains a mounted filesystem\n"),
|
||||
progname, name);
|
||||
- return 1;
|
||||
+ ismounted = 1;
|
||||
+ break;
|
||||
}
|
||||
- return 0;
|
||||
+ endmntent(f);
|
||||
+ return ismounted;
|
||||
}
|
||||
|
||||
int
|
||||
--- include/xfs.h.orig 2015-08-04 01:37:12.000000000 +0200
|
||||
+++ include/xfs.h 2015-10-03 21:42:48.317971365 +0200
|
||||
@@ -33,6 +33,8 @@
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'xfsprogs'
|
||||
pkgname=xfsprogs
|
||||
version=4.7.0
|
||||
revision=2
|
||||
version=4.8.0
|
||||
revision=1
|
||||
build_style=gnu-configure
|
||||
configure_args="--enable-readline=yes --enable-lib64=no"
|
||||
CFLAGS=-D_DIRENT_HAVE_D_RECLEN
|
||||
|
@ -11,8 +11,8 @@ short_desc="Utilities for managing the XFS filesystem"
|
|||
maintainer="Juan RP <xtraeme@voidlinux.eu>"
|
||||
license="LGPL-2.1"
|
||||
homepage="http://xfs.org/"
|
||||
distfiles="ftp://oss.sgi.com/projects/xfs/cmd_tars/${pkgname}-${version}.tar.gz"
|
||||
checksum=88580bb3e6847c3edef436703a4fae403fc19b20739db4c31166ee4b256178d7
|
||||
distfiles="ftp://ftp.kernel.org/pub/linux/utils/fs/xfs/${pkgname}/${pkgname}-${version}.tar.xz"
|
||||
checksum=82ce9cb3a55f4e208e8fe3471ff0aff0602b8300f3e50bdf05cc7e11549686f9
|
||||
|
||||
do_install() {
|
||||
make install install-dev DIST_ROOT=${DESTDIR} \
|
||||
|
|
Loading…
Reference in New Issue