Debian Codegraph @

compat/include/bylabel.h

raw symbols SCIP
1 /*
2 * Ported to Linux's Second Extended File System as part of the
3 * dump and restore backup suit
4 * 1999-02-22 Arkadiusz Miśkiewicz <[email protected]>
5 * - added Native Language Support
6 * 2000-01-20 James Antill <[email protected]>
7 * - Added error message if /proc/partitions cannot be opened
8 * 2000-05-09 Erik Troan <[email protected]>
9 * - Added cache for UUID and disk labels
10 * Wed Aug 16 2000 Erik Troan <[email protected]>
11 * - Ported to dump/restore
12 * Stelian Pop <[email protected]> - Alcôve <www.alcove.com>, 2000-2002
13 */
14
15 #ifndef _BYLABEL_H_
16 #define _BYLABEL_H_
17
18 #include "config.h" // IWYU pragma: keep
19
20 #ifdef HAVE_BLKID
21
22 #include <blkid/blkid.h>
23 #include <stdio.h>
24
25 inline const char * get_device_name(const char * item) {
26 return blkid_get_devname(NULL, item, NULL);
27 }
28
29 inline const char * get_device_label(const char * spec) {
30 return blkid_get_tag_value(NULL, "LABEL", spec);
31 }
32
33 #else
34
35 const char * get_device_name(const char * item);
36 const char * get_device_label(const char * spec);
37
38 #endif
39
40 #endif /* !_BYLABEL_H_ */