Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for mipsel-sony-psp #80

Merged
merged 1 commit into from
Jan 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 11 additions & 9 deletions impl/src/declaration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,27 +129,28 @@ pub fn expand(input: TokenStream) -> TokenStream {
target_os = "fuchsia",
target_os = "illumos",
target_os = "freebsd",
target_os = "psp",
))]
extern "Rust" {
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_name = #linux_section_start)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_name = #linux_section_start)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_name = #macho_section_start)]
#[cfg_attr(target_os = "illumos", link_name = #illumos_section_start)]
#[cfg_attr(target_os = "freebsd", link_name = #freebsd_section_start)]
static LINKME_START: <#ty as #linkme_path::__private::Slice>::Element;

#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_name = #linux_section_stop)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_name = #linux_section_stop)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_name = #macho_section_stop)]
#[cfg_attr(target_os = "illumos", link_name = #illumos_section_stop)]
#[cfg_attr(target_os = "freebsd", link_name = #freebsd_section_stop)]
static LINKME_STOP: <#ty as #linkme_path::__private::Slice>::Element;

#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_name = #linux_dupcheck_start)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_name = #linux_dupcheck_start)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_name = #macho_dupcheck_start)]
#[cfg_attr(target_os = "illumos", link_name = #illumos_dupcheck_start)]
#[cfg_attr(target_os = "freebsd", link_name = #freebsd_dupcheck_start)]
static DUPCHECK_START: #linkme_path::__private::usize;

#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_name = #linux_dupcheck_stop)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_name = #linux_dupcheck_stop)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_name = #macho_dupcheck_stop)]
#[cfg_attr(target_os = "illumos", link_name = #illumos_dupcheck_stop)]
#[cfg_attr(target_os = "freebsd", link_name = #freebsd_dupcheck_stop)]
Expand All @@ -173,14 +174,14 @@ pub fn expand(input: TokenStream) -> TokenStream {
static DUPCHECK_STOP: () = ();

#used
#[cfg(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "illumos", target_os = "freebsd"))]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_section = #linux_section)]
#[cfg(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "illumos", target_os = "freebsd", target_os = "psp"))]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_section = #linux_section)]
#[cfg_attr(target_os = "illumos", link_section = #illumos_section)]
#[cfg_attr(target_os = "freebsd", link_section = #freebsd_section)]
static mut LINKME_PLEASE: [<#ty as #linkme_path::__private::Slice>::Element; 0] = [];

#used
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_section = #linux_dupcheck)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_section = #linux_dupcheck)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_section = #macho_dupcheck)]
#[cfg_attr(target_os = "windows", link_section = #windows_dupcheck)]
#[cfg_attr(target_os = "illumos", link_section = #illumos_dupcheck)]
Expand All @@ -198,6 +199,7 @@ pub fn expand(input: TokenStream) -> TokenStream {
target_os = "fuchsia",
target_os = "illumos",
target_os = "freebsd",
target_os = "psp",
)))]
#unsupported_platform

Expand Down Expand Up @@ -242,7 +244,7 @@ pub fn expand(input: TokenStream) -> TokenStream {
$item:item
) => {
#used
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_section = $linux_section)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_section = $linux_section)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_section = $macho_section)]
#[cfg_attr(target_os = "windows", link_section = $windows_section)]
#[cfg_attr(target_os = "illumos", link_section = $illumos_section)]
Expand All @@ -251,7 +253,7 @@ pub fn expand(input: TokenStream) -> TokenStream {
};
($item:item) => {
#used
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia"), link_section = #linux_section)]
#[cfg_attr(any(target_os = "none", target_os = "linux", target_os = "android", target_os = "fuchsia", target_os = "psp"), link_section = #linux_section)]
#[cfg_attr(any(target_os = "macos", target_os = "ios", target_os = "tvos"), link_section = #macho_section)]
#[cfg_attr(target_os = "windows", link_section = #windows_section)]
#[cfg_attr(target_os = "illumos", link_section = #illumos_section)]
Expand Down
3 changes: 2 additions & 1 deletion src/distributed_slice.rs
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ impl<T> DistributedSlice<[T]> {
target_os = "android",
target_os = "fuchsia",
target_os = "illumos",
target_os = "freebsd"
target_os = "freebsd",
target_os = "psp",
))]
pub const unsafe fn private_new(
name: &'static str,
Expand Down
Loading