Rename pmconflict_t to alpm_conflict_t
[pacman-ng.git] / lib / libalpm / diskspace.h
blob79e1677286d634c2346155c61cbb0a49441007a0
1 /*
2 * diskspace.h
4 * Copyright (c) 2010-2011 Pacman Development Team <pacman-dev@archlinux.org>
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef _ALPM_DISKSPACE_H
21 #define _ALPM_DISKSPACE_H
23 #if defined(HAVE_SYS_MOUNT_H)
24 #include <sys/mount.h>
25 #endif
26 #if defined(HAVE_SYS_STATVFS_H)
27 #include <sys/statvfs.h>
28 #endif
30 #include "alpm.h"
32 enum mount_used_level {
33 USED_REMOVE = 1,
34 USED_INSTALL = (1 << 1),
37 typedef struct __alpm_mountpoint_t {
38 /* mount point information */
39 char *mount_dir;
40 size_t mount_dir_len;
41 /* storage for additional disk usage calculations */
42 long blocks_needed;
43 long max_blocks_needed;
44 enum mount_used_level used;
45 int read_only;
46 FSSTATSTYPE fsp;
47 } alpm_mountpoint_t;
49 int _alpm_check_diskspace(alpm_handle_t *handle);
51 #endif /* _ALPM_DISKSPACE_H */
53 /* vim: set ts=2 sw=2 noet: */