disambiguate include guards and export C strings
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# POSIX header spec: https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/sys_utsname.h.html
|
||||
#
|
||||
# There are no spec quotations relating to includes
|
||||
include_guard = "_SYS_UTSNAME_H"
|
||||
include_guard = "_RELIBC_SYS_UTSNAME_H"
|
||||
language = "C"
|
||||
style = "Tag"
|
||||
no_includes = true
|
||||
|
||||
@@ -1,7 +1,13 @@
|
||||
# POSIX header spec: https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/tar.h.html
|
||||
#
|
||||
# There are no spec quotations relating to includes
|
||||
include_guard = "_TAR_H"
|
||||
include_guard = "_RELIBC_TAR_H"
|
||||
# cbindgen cannot export Rust &str
|
||||
after_includes = """
|
||||
|
||||
#define TMAGIC "ustar"
|
||||
#define TVERSION "00"
|
||||
"""
|
||||
language = "C"
|
||||
style = "Tag"
|
||||
no_includes = true
|
||||
|
||||
@@ -54,8 +54,10 @@ pub const FIFOTYPE: u8 = b'6'; // FIFO special
|
||||
pub const CONTTYPE: u8 = b'7'; // Contiguous file
|
||||
|
||||
/// tar format magic and version
|
||||
/// cbindgen:ignore
|
||||
pub const TMAGIC: &str = "ustar"; // Magic string : ustar and a null
|
||||
pub const TMAGLEN: usize = 6; // Length of the magic string
|
||||
/// cbindgen:ignore
|
||||
pub const TVERSION: &str = "00"; // Version string
|
||||
pub const TVERSLEN: usize = 2; // Length of the version string
|
||||
|
||||
|
||||
Reference in New Issue
Block a user