Skip to content

Rust now requires MacOS > 10.12 #56

Open
@strowk

Description

See
https://blog.rust-lang.org/2023/09/25/Increasing-Apple-Version-Requirements.html

This:

TARGET_DIR=/opt/osxcross UNATTENDED=yes OSX_VERSION_MIN=10.7 ./build.sh

needs to be upped to 10.12 in at least some targets, otherwise error looking like this:

          ld: warning: object file (/target/x86_64-apple-darwin/release/deps/libidna-9e0bb8c28bf4f03d.rlib(idna-9e0bb8c28bf4f03d.idna.3875f9ff72356008-cgu.7.rcgu.o)) was built for newer macOS version (10.12) than being linked (10.7)
          Undefined symbols for architecture x86_64:
            "_clock_gettime", referenced from:
                std::sys::unix::time::Timespec::now::h0ebd2e38935918ca in libstd-4b3c9502f998a9c9.rlib(std-4b3c9502f998a9c9.std.ccb858c55971878c-cgu.0.rcgu.o)
            "_getentropy", referenced from:
                std::sys::unix::rand::hashmap_random_keys::ha92d0a2687c22b7a in libstd-4b3c9502f998a9c9.rlib(std-4b3c9502f998a9c9.std.ccb858c55971878c-cgu.0.rcgu.o)
          ld: symbol(s) not found for architecture x86_64
          clang: error: linker command failed with exit code 1 (use -v to see invocation)

would be happening (this is from build for x86_64).

Simply upping the value to 10.12 would be more strict than what Rust seems to require now though.
There was no issue for me on aarch64-apple-darwin, and that is in alignment with blog post linked above, as that target is not mentioned as affected by change (aarch64-apple-ios is mentioned, but not darwin).

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions