Skip to content

Commit

Permalink
feat: Add AIX support
Browse files Browse the repository at this point in the history
  • Loading branch information
Byron authored Jul 2, 2024
2 parents 644f186 + b414215 commit d4e66dc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ name = "open"
[target.'cfg(all(unix, not(macos)))'.dependencies]
pathdiff = "0.2.0"

[target.'cfg(any(target_os = "linux", target_os = "android", target_os = "freebsd", target_os = "dragonfly", target_os = "netbsd", target_os = "openbsd", target_os = "illumos", target_os = "solaris" ))'.dependencies]
[target.'cfg(any(target_os = "linux", target_os = "android", target_os = "freebsd", target_os = "dragonfly", target_os = "netbsd", target_os = "openbsd", target_os = "illumos", target_os = "solaris", target_os = "aix" ))'.dependencies]
is-wsl = "0.4.0"

[target."cfg(unix)".dependencies]
Expand Down
9 changes: 6 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ use redox as os;
target_os = "netbsd",
target_os = "openbsd",
target_os = "illumos",
target_os = "solaris"
target_os = "solaris",
target_os = "aix"
))]
use unix as os;

Expand All @@ -110,7 +111,8 @@ use unix as os;
target_os = "macos",
target_os = "windows",
target_os = "haiku",
target_os = "redox"
target_os = "redox",
target_os = "aix"
)))]
compile_error!("open is not supported on this platform");

Expand Down Expand Up @@ -373,6 +375,7 @@ mod redox;
target_os = "netbsd",
target_os = "openbsd",
target_os = "illumos",
target_os = "solaris"
target_os = "solaris",
target_os = "aix"
))]
mod unix;

0 comments on commit d4e66dc

Please sign in to comment.