Skip to content

Commit

Permalink
Auto merge of #3303 - Mek101:main, r=JohnTitor
Browse files Browse the repository at this point in the history
linux/gnu: add glob extension constants

As per title, added
```
GLOB_PERIOD
GLOB_ALTDIRFUNC
GLOB_BRACE
GLOB_NOMAGIC
GLOB_TILDE
GLOB_ONLYDIR
GLOB_TILDE_CHECK
```
  • Loading branch information
bors committed Jul 16, 2023
2 parents fab4a56 + 43152fb commit 9253fca
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
7 changes: 7 additions & 0 deletions libc-test/semver/linux-gnu.txt
Expand Up @@ -51,6 +51,13 @@ FUTEXFS_SUPER_MAGIC
GENL_ID_PMCRAID
GENL_ID_VFS_DQUOT
GENL_UNS_ADMIN_PERM
GLOB_ALTDIRFUNC
GLOB_BRACE
GLOB_NOMAGIC
GLOB_ONLYDIR
GLOB_PERIOD
GLOB_TILDE
GLOB_TILDE_CHECK
HOSTFS_SUPER_MAGIC
HPFS_SUPER_MAGIC
HUGETLBFS_MAGIC
Expand Down
10 changes: 10 additions & 0 deletions src/unix/linux_like/linux/gnu/mod.rs
Expand Up @@ -1083,6 +1083,16 @@ pub const TIME_ERROR: ::c_int = 5;
pub const TIME_BAD: ::c_int = TIME_ERROR;
pub const MAXTC: ::c_long = 6;

// Portable GLOB_* flags are defined at the `linux_like` level.
// The following are GNU extensions.
pub const GLOB_PERIOD: ::c_int = 1 << 7;
pub const GLOB_ALTDIRFUNC: ::c_int = 1 << 9;
pub const GLOB_BRACE: ::c_int = 1 << 10;
pub const GLOB_NOMAGIC: ::c_int = 1 << 11;
pub const GLOB_TILDE: ::c_int = 1 << 12;
pub const GLOB_ONLYDIR: ::c_int = 1 << 13;
pub const GLOB_TILDE_CHECK: ::c_int = 1 << 14;

cfg_if! {
if #[cfg(any(
target_arch = "arm",
Expand Down

0 comments on commit 9253fca

Please sign in to comment.