Skip to content

Commit 86e6311

Browse files
karchermglaubitz
authored andcommitted
Adjust for newer glibc on sparc64
This commit removes special cases for sparc64 which caused test failures on a sparc64 system (Debian, glibc 2.28). With these changes, the ABI tests pass except for the known test failure from #1080
1 parent a4d4177 commit 86e6311

File tree

1 file changed

+5
-19
lines changed
  • src/unix/notbsd/linux/other

1 file changed

+5
-19
lines changed

src/unix/notbsd/linux/other/mod.rs

+5-19
Original file line numberDiff line numberDiff line change
@@ -40,23 +40,19 @@ s! {
4040
pub ut_exit: __exit_status,
4141

4242
#[cfg(any(target_arch = "aarch64",
43-
target_arch = "sparc64",
4443
all(target_pointer_width = "32",
4544
not(target_arch = "x86_64"))))]
4645
pub ut_session: ::c_long,
4746
#[cfg(any(target_arch = "aarch64",
48-
target_arch = "sparc64",
4947
all(target_pointer_width = "32",
5048
not(target_arch = "x86_64"))))]
5149
pub ut_tv: ::timeval,
5250

5351
#[cfg(not(any(target_arch = "aarch64",
54-
target_arch = "sparc64",
5552
all(target_pointer_width = "32",
5653
not(target_arch = "x86_64")))))]
5754
pub ut_session: ::int32_t,
5855
#[cfg(not(any(target_arch = "aarch64",
59-
target_arch = "sparc64",
6056
all(target_pointer_width = "32",
6157
not(target_arch = "x86_64")))))]
6258
pub ut_tv: __timeval,
@@ -629,10 +625,6 @@ cfg_if!{
629625
pub const NFT_CHAIN_MAXNAMELEN: ::c_int = 32;
630626
pub const NFT_SET_MAXNAMELEN: ::c_int = 32;
631627
pub const NFT_OBJ_MAXNAMELEN: ::c_int = 32;
632-
} else if #[cfg(target_arch = "sparc64")] {
633-
pub const NFT_TABLE_MAXNAMELEN: ::c_int = 32;
634-
pub const NFT_CHAIN_MAXNAMELEN: ::c_int = 32;
635-
pub const NFT_SET_MAXNAMELEN: ::c_int = 32;
636628
} else {
637629
pub const NFT_TABLE_MAXNAMELEN: ::c_int = 256;
638630
pub const NFT_CHAIN_MAXNAMELEN: ::c_int = 256;
@@ -692,17 +684,11 @@ pub const NFT_MSG_DELSETELEM: ::c_int = 14;
692684
pub const NFT_MSG_NEWGEN: ::c_int = 15;
693685
pub const NFT_MSG_GETGEN: ::c_int = 16;
694686
pub const NFT_MSG_TRACE: ::c_int = 17;
695-
cfg_if! {
696-
if #[cfg(not(target_arch = "sparc64"))] {
697-
pub const NFT_MSG_NEWOBJ: ::c_int = 18;
698-
pub const NFT_MSG_GETOBJ: ::c_int = 19;
699-
pub const NFT_MSG_DELOBJ: ::c_int = 20;
700-
pub const NFT_MSG_GETOBJ_RESET: ::c_int = 21;
701-
pub const NFT_MSG_MAX: ::c_int = 22;
702-
} else {
703-
pub const NFT_MSG_MAX: ::c_int = 18;
704-
}
705-
}
687+
pub const NFT_MSG_NEWOBJ: ::c_int = 18;
688+
pub const NFT_MSG_GETOBJ: ::c_int = 19;
689+
pub const NFT_MSG_DELOBJ: ::c_int = 20;
690+
pub const NFT_MSG_GETOBJ_RESET: ::c_int = 21;
691+
pub const NFT_MSG_MAX: ::c_int = 22;
706692

707693
pub const NFT_SET_ANONYMOUS: ::c_int = 0x1;
708694
pub const NFT_SET_CONSTANT: ::c_int = 0x2;

0 commit comments

Comments
 (0)