diff --git a/Mk/Uses/cargo.mk b/Mk/Uses/cargo.mk index 1ee0f9c76bb8..eb86fa3a6f40 100644 --- a/Mk/Uses/cargo.mk +++ b/Mk/Uses/cargo.mk @@ -1,434 +1,434 @@ # This file contains logic to ease porting of Rust packages or # binaries using the `cargo` command. # # Feature: cargo # Usage: USES=cargo # Valid ARGS: none # # MAINTAINER: rust@FreeBSD.org .if !defined(_INCLUDE_USES_CARGO_MK) _INCLUDE_USES_CARGO_MK= yes . if !empty(cargo_ARGS) IGNORE+= USES=cargo takes no arguments . endif .sinclude "${MASTERDIR}/Makefile.crates" # List of static dependencies. The format is cratename-version. # CARGO_CRATES will be downloaded from MASTER_SITE_CRATESIO. CARGO_CRATES?= # List of features to build (space separated list). # Use special token --no-default-features to disable default # features by passing it to cargo build/install/test. CARGO_FEATURES?= # The subdirectory in the source tree where the cargo project # is located. By default the whole project is in Rust, but # the Rust part can be at any location. # Multiple Rust subprojects are not yet supported. CARGO_SRC_SUBDIR?= # Is the Rust project top-level? CARGO_RUST_TOPLEVEL= ${CARGO_SRC_SUBDIR:C/^.+$/no/:C/^$/yes/} # WRKSRC of the Rust project. CARGO_WRKSRC= ${WRKSRC}/${CARGO_SRC_SUBDIR} # Name of the local directory for vendoring crates. CARGO_VENDOR_DIR?= ${CARGO_WRKSRC}/cargo-crates # Default path for cargo manifest. CARGO_CARGOTOML?= ${CARGO_WRKSRC}/Cargo.toml CARGO_CARGOLOCK?= ${CARGO_WRKSRC}/Cargo.lock # Save crates inside ${DISTDIR}/rust/crates by default. CARGO_DIST_SUBDIR?= rust/crates # Generate list of DISTFILES. # Prefer canonical file extension .crate going forward . if make(makesum) CARGO_CRATE_EXT= .crate . else # If there is a rust/crates/*.tar.gz in distinfo keep using the old # extension. We need to delay eval until the last moment for # DISTINFO_FILE. We cache the command output to avoid multiple # slow grep runs for every CARGO_CRATE_EXT access. CARGO_CRATE_EXT= ${defined(_CARGO_CRATE_EXT_CACHE):?${_CARGO_CRATE_EXT_CACHE}:${:!if ${GREP} -q '\(${CARGO_DIST_SUBDIR}/.*\.tar\.gz\)' "${DISTINFO_FILE}" 2>/dev/null; then ${ECHO_CMD} .tar.gz; else ${ECHO_CMD} .crate; fi!:_=_CARGO_CRATE_EXT_CACHE}} . endif _CARGO_CRATES:= ${CARGO_CRATES:N*@git+*} _CARGO_GIT_SOURCES:= ${CARGO_CRATES:M*@git+*} # enumerate crates for unqiue and sane distfile group names _CARGO_CRATES:= ${empty(_CARGO_CRATES):?:${_CARGO_CRATES:range:@i@$i ${_CARGO_CRATES:[$i]}@}} # split up crates into (index, crate, name, version) 4-tuples _CARGO_CRATES:= ${_CARGO_CRATES:C/^([-_a-zA-Z0-9]+)-([0-9].*)/\0 \1 \2/} . for _index _crate _name _version in ${_CARGO_CRATES} # Resolving CRATESIO alias is very inefficient with many MASTER_SITES, consume MASTER_SITE_CRATESIO directly MASTER_SITES+= ${MASTER_SITE_CRATESIO:S,%SUBDIR%,${_name}/${_version},:S,$,:_cargo_${_index},} DISTFILES+= ${CARGO_DIST_SUBDIR}/${_crate}${CARGO_CRATE_EXT}:_cargo_${_index} # Provide pointer to the crate's extraction dir WRKSRC_crate_${_name}= ${CARGO_VENDOR_DIR}/${_crate} # ... also with version suffix in case of multiple versions of the # same crate WRKSRC_crate_${_crate}= ${CARGO_VENDOR_DIR}/${_crate} . endfor _CARGO_AWK= ${AWK} -vCP="${CP}" -vFIND="${FIND}" -vGREP="${GREP}" \ -vCARGO_VENDOR_DIR="${CARGO_VENDOR_DIR}" \ -vGIT_SOURCES="${_CARGO_GIT_SOURCES}" \ -vWRKDIR="${WRKDIR}" -vWRKSRC="${CARGO_WRKSRC}" \ -f${SCRIPTSDIR}/split-url.awk \ -f${SCRIPTSDIR}/cargo-crates-git-common.awk -f . if !empty(_CARGO_GIT_SOURCES) . for _index _site _filename _wrksrc _crates in ${:!${_CARGO_AWK} ${SCRIPTSDIR}/cargo-crates-git-fetch.awk /dev/null!} MASTER_SITES+= ${_site}:_cargo_git${_index} DISTFILES+= ${_filename}:_cargo_git${_index} . for _crate in ${_crates:S/,/ /g} # Make sure the build dependencies checks below can work for git sourced crates too _CARGO_CRATES+= @git ${_crate} ${_crate} @git # Provide pointer to the crate's extraction dir # # This might not point to the actual crate's sources since a # single git source can contain multiple crates. We cannot collect # subdir information until after the full extraction is done and we # cannot set make variables at that point. This is better than # nothing. WRKSRC_crate_${_crate}= ${WRKDIR}/${_wrksrc} . endfor . endfor . endif # Build dependencies. CARGO_BUILDDEP?= yes . if ${CARGO_BUILDDEP:tl} == "yes" -BUILD_DEPENDS+= ${RUST_DEFAULT}>=1.96.0:lang/${RUST_DEFAULT} +BUILD_DEPENDS+= ${RUST_DEFAULT}>=1.97.0:lang/${RUST_DEFAULT} . elif ${CARGO_BUILDDEP:tl} == "any-version" BUILD_DEPENDS+= ${RUST_DEFAULT}>=0:lang/${RUST_DEFAULT} . endif # Location of toolchain (default to lang/rust's toolchain) CARGO?= ${LOCALBASE}/bin/cargo RUSTC?= ${LOCALBASE}/bin/rustc RUSTDOC?= ${LOCALBASE}/bin/rustdoc # Location of the cargo output directory. CARGO_TARGET_DIR?= ${WRKDIR}/target _CARGO_RUST_ARCH_amd64= x86_64 _CARGO_RUST_ARCH_i386= i686 _CARGO_RUST_ARCH_riscv64= riscv64gc # Environment for cargo # - CARGO_HOME: local cache of the registry index # - CARGO_BUILD_JOBS: configure number of jobs to run # - CARGO_TARGET_DIR: location of where to place all generated artifacts # - RUST_BACKTRACE: produce backtraces when something in the build panics # - RUSTC: path of rustc binary (default to lang/rust) # - RUSTDOC: path of rustdoc binary (default to lang/rust) # - RUSTFLAGS: custom flags to pass to all compiler invocations that Cargo performs CARGO_ENV+= \ CARGO_HOME=${WRKDIR}/cargo-home \ CARGO_BUILD_JOBS=${MAKE_JOBS_NUMBER} \ CARGO_TARGET_DIR=${CARGO_TARGET_DIR} \ RUSTC=${RUSTC} \ RUSTDOC=${RUSTDOC} \ RUSTFLAGS="${RUSTFLAGS} -C linker=${CC} ${LDFLAGS:C/.+/-C link-args=&/}" . if ${ARCH} != powerpc64le CARGO_ENV+= RUST_BACKTRACE=1 . endif . if !defined(WITHOUT_LTO) _CARGO_MSG= "===> Additional optimization to port applied" WITH_LTO= yes . endif # Adjust -C target-cpu if -march/-mcpu is set by bsd.cpu.mk . if ${ARCH} == amd64 || ${ARCH} == i386 RUSTFLAGS+= ${CFLAGS:M-march=*:S/-march=/-C target-cpu=/} . elif ${ARCH:Mpowerpc*} RUSTFLAGS+= ${CFLAGS:M-mcpu=*:S/-mcpu=/-C target-cpu=/:S/power/pwr/} . elif ${ARCH} == aarch64 || ${ARCH} == armv7 RUSTFLAGS+= -C target-cpu=${CPUTYPE:C/\+.+//g} . else RUSTFLAGS+= ${CFLAGS:M-mcpu=*:S/-mcpu=/-C target-cpu=/} . endif # Helper to shorten cargo calls. _CARGO_RUN= ${SETENVI} ${WRK_ENV} ${MAKE_ENV} ${CARGO_ENV} ${CARGO} CARGO_CARGO_RUN= cd ${CARGO_WRKSRC} && ${SETENVI} ${WRK_ENV} ${MAKE_ENV} ${CARGO_ENV} \ CARGO_FREEBSD_PORTS_SKIP_GIT_UPDATE=1 ${CARGO} # User arguments for cargo targets. CARGO_BUILD_ARGS?= CARGO_INSTALL_ARGS?= CARGO_INSTALL_PATH?= . CARGO_TEST_ARGS?= CARGO_TEST_AFTER_ARGS?= CARGO_UPDATE_ARGS?= # Use module targets ? CARGO_BUILD?= ${CARGO_RUST_TOPLEVEL} CARGO_CONFIGURE?= yes CARGO_INSTALL?= ${CARGO_RUST_TOPLEVEL} CARGO_TEST?= ${CARGO_RUST_TOPLEVEL} # rustc stashes intermediary files in TMPDIR (default /tmp) which # might cause issues for users that for some reason space limit # their /tmp. WRKDIR should have plenty of space. # Allow users and ports to still overwrite it. . if ${TMPDIR:U/tmp} == /tmp TMPDIR= ${WRKDIR} . endif # Manage crate features. . if !empty(CARGO_FEATURES:M--no-default-features) CARGO_BUILD_ARGS+= --no-default-features CARGO_INSTALL_ARGS+= --no-default-features CARGO_TEST_ARGS+= --no-default-features . endif . if !empty(CARGO_FEATURES:N--no-default-features) CARGO_BUILD_ARGS+= --features='${CARGO_FEATURES:N--no-default-features}' CARGO_INSTALL_ARGS+= --features='${CARGO_FEATURES:N--no-default-features}' CARGO_TEST_ARGS+= --features='${CARGO_FEATURES:N--no-default-features}' . endif . if !defined(WITH_DEBUG) CARGO_BUILD_ARGS+= --release CARGO_TEST_ARGS+= --release . else CARGO_INSTALL_ARGS+= --debug . endif . if ${_CARGO_CRATES:Mcmake} BUILD_DEPENDS+= cmake:devel/cmake-core . endif . if ${_CARGO_CRATES:Mgettext-sys} CARGO_ENV+= GETTEXT_BIN_DIR=${LOCALBASE}/bin \ GETTEXT_INCLUDE_DIR=${LOCALBASE}/include \ GETTEXT_LIB_DIR=${LOCALBASE}/lib . endif . if ${_CARGO_CRATES:Mjemalloc-sys} BUILD_DEPENDS+= gmake:devel/gmake . endif . if ${_CARGO_CRATES:Mlibgit2-sys} # Use the system's libgit2 instead of building the bundled version CARGO_ENV+= LIBGIT2_SYS_USE_PKG_CONFIG=1 . endif . if ${_CARGO_CRATES:Mlibssh2-sys} # Use the system's libssh2 instead of building the bundled version CARGO_ENV+= LIBSSH2_SYS_USE_PKG_CONFIG=1 . endif . if ${_CARGO_CRATES:Monig_sys} # onig_sys always prefers the system library but will try to link # statically with it. Since devel/oniguruma doesn't provide a static # library it'll link to libonig.so instead. Strictly speaking setting # RUSTONIG_SYSTEM_LIBONIG is not necessary, but will force onig_sys to # always use the system's libonig as returned by `pkg-config oniguruma`. CARGO_ENV+= RUSTONIG_SYSTEM_LIBONIG=1 . endif . if ${_CARGO_CRATES:Mopenssl-src} DEV_WARNING+= "Please make sure this port uses the system OpenSSL and consider removing CARGO_CRATES=${CARGO_CRATES:Mopenssl-src-[0-9]*} (a vendored copy of OpenSSL) from the build, e.g., by patching Cargo.toml appropriately." . endif . if ${_CARGO_CRATES:Mopenssl-sys} # Make sure that openssl-sys can find the correct version of OpenSSL CARGO_ENV+= OPENSSL_LIB_DIR=${OPENSSLLIB} \ OPENSSL_INCLUDE_DIR=${OPENSSLINC} . endif . if ${_CARGO_CRATES:Mpkg-config} .include "${USESDIR}/pkgconfig.mk" . endif . if ${_CARGO_CRATES:Mzstd-sys} # Use the system's zstd instead of building the bundled version CARGO_ENV+= ZSTD_SYS_USE_PKG_CONFIG=1 . endif . for _index _crate _name _version in ${_CARGO_CRATES} # Split up semantic version and try to sanitize it by removing # pre-release identifier (-) or build metadata (+) . if ${_version:S/./ /:S/./ /:C/[-+].*//:_:[#]} == 3 . for _major _minor _patch in $_ # FreeBSD 12.0 changed ABI: r318736 and r320043 # https://github.com/rust-lang/libc/commit/78f93220d70e # https://github.com/rust-lang/libc/commit/969ad2b73cdc . if ${_name} == libc && ${_major} == 0 && (${_minor} < 2 || (${_minor} == 2 && ${_patch} < 38)) DEV_ERROR+= "CARGO_CRATES=${_crate} may be unstable on FreeBSD 12.0. Consider updating to the latest version \(higher than 0.2.37\)." . endif . if ${_name} == libc && ${_major} == 0 && (${_minor} < 2 || (${_minor} == 2 && ${_patch} < 49)) DEV_ERROR+= "CARGO_CRATES=${_crate} may be unstable on aarch64 or not build on armv6, armv7, powerpc64. Consider updating to the latest version \(higher than 0.2.49\)." . endif # FreeBSD 12.0 updated base OpenSSL in r339270: # https://github.com/sfackler/rust-openssl/commit/276577553501 . if ${_name} == openssl && !exists(${PATCHDIR}/patch-openssl-1.1.1) && ${_major} == 0 && (${_minor} < 10 || (${_minor} == 10 && ${_patch} < 4)) DEV_WARNING+= "CARGO_CRATES=${_crate} does not support OpenSSL 1.1.1. Consider updating to the latest version \(higher than 0.10.3\)." . endif . endfor . endif . endfor _USES_extract+= 600:cargo-extract cargo-extract: # target for preparing crates directory. It will put all crates in # the local crates directory. @${ECHO_MSG} "===> Moving crates to ${CARGO_VENDOR_DIR}" @${MKDIR} ${CARGO_VENDOR_DIR} . for _index _crate _name _version in ${_CARGO_CRATES} . if ${_index} != @git @${MV} ${WRKDIR}/${_crate} ${CARGO_VENDOR_DIR}/${_crate} @${PRINTF} '{"package":"%s","files":{}}' \ $$(${SHA256} -q ${_DISTDIR}/${CARGO_DIST_SUBDIR}/${_crate}${CARGO_CRATE_EXT}) \ > ${CARGO_VENDOR_DIR}/${_crate}/.cargo-checksum.json @if [ -r ${CARGO_VENDOR_DIR}/${_crate}/Cargo.toml.orig ]; then \ ${MV} ${CARGO_VENDOR_DIR}/${_crate}/Cargo.toml.orig \ ${CARGO_VENDOR_DIR}/${_crate}/Cargo.toml.orig-cargo; \ fi . endif . endfor . if ${CARGO_CONFIGURE:tl} == "yes" _USES_configure+= 250:cargo-configure CARGO_DOT_DIR= ${WRKSRC}/${CARGO_SRC_SUBDIR}/../.cargo # configure hook. Place a config file for overriding crates-io index # by local source directory. cargo-configure: # Check that the running kernel has COMPAT_FREEBSD11 required by lang/rust post-ino64 @${SETENV} CC="${CC}" OPSYS="${OPSYS}" OSVERSION="${OSVERSION}" WRKDIR="${WRKDIR}" \ ${SH} ${SCRIPTSDIR}/rust-compat11-canary.sh . if defined(_CARGO_MSG) @${ECHO_MSG} ${_CARGO_MSG} . endif @${ECHO_MSG} "===> Cargo config:" @${MKDIR} ${CARGO_DOT_DIR} @: > ${CARGO_DOT_DIR}/config.toml @${ECHO_CMD} "[source.cargo]" >> ${CARGO_DOT_DIR}/config.toml @${ECHO_CMD} "directory = '${CARGO_VENDOR_DIR}'" >> ${CARGO_DOT_DIR}/config.toml @${ECHO_CMD} "[source.crates-io]" >> ${CARGO_DOT_DIR}/config.toml @${ECHO_CMD} "replace-with = 'cargo'" >> ${CARGO_DOT_DIR}/config.toml . if !empty(_CARGO_GIT_SOURCES) @${_CARGO_AWK} ${SCRIPTSDIR}/cargo-crates-git-configure.awk \ /dev/null >> ${CARGO_DOT_DIR}/config.toml . endif @${CAT} ${CARGO_DOT_DIR}/config.toml @if ! ${GREP} -qF '[profile.release]' ${CARGO_CARGOTOML}; then \ ${ECHO_CMD} "" >> ${CARGO_CARGOTOML}; \ ${ECHO_CMD} "[profile.release]" >> ${CARGO_CARGOTOML}; \ ${ECHO_CMD} "opt-level = 2" >> ${CARGO_CARGOTOML}; \ ${ECHO_CMD} "debug = false" >> ${CARGO_CARGOTOML}; \ ${ECHO_CMD} 'strip = "symbols"' >> ${CARGO_CARGOTOML}; \ fi @${ECHO_MSG} "===> Updating Cargo.lock" @${CARGO_CARGO_RUN} update \ --manifest-path ${CARGO_CARGOTOML} \ --verbose \ --verbose \ ${CARGO_UPDATE_ARGS} . endif . if !target(do-build) && ${CARGO_BUILD:tl} == "yes" do-build: @${CARGO_CARGO_RUN} build \ --manifest-path ${CARGO_CARGOTOML} \ --verbose \ --verbose \ ${CARGO_BUILD_ARGS} . endif . if !target(do-install) && ${CARGO_INSTALL:tl} == "yes" do-install: . for path in ${CARGO_INSTALL_PATH} @${CARGO_CARGO_RUN} install \ --no-track \ --path "${path}" \ --root "${STAGEDIR}${PREFIX}" \ --verbose \ --verbose \ ${CARGO_INSTALL_ARGS} . endfor . endif . if !empty(CARGO_TEST_AFTER_ARGS) _CARGO_TEST_AFTER_ARGS= -- ${CARGO_TEST_AFTER_ARGS} . endif . if !target(do-test) && ${CARGO_TEST:tl} == "yes" do-test: @${CARGO_CARGO_RUN} test \ --manifest-path ${CARGO_CARGOTOML} \ --verbose \ --verbose \ ${CARGO_TEST_ARGS} \ ${_CARGO_TEST_AFTER_ARGS} . endif # # Helper targets for port maintainers # # cargo-audit generates a vulnerability report using # security/cargo-audit based on the crates in Cargo.lock. cargo-audit: configure @if ! type cargo-audit > /dev/null 2>&1; then \ ${ECHO_MSG} "===> Please install \"security/cargo-audit\""; exit 1; \ fi @${ECHO_MSG} "===> Checking for vulnerable crates" @${CARGO} audit --file ${CARGO_CARGOLOCK} # cargo-crates will output the crates list from Cargo.lock. If there # is no Cargo.lock for some reason, try and generate it first. cargo-crates: cargo-crates-generate-lockfile @${_CARGO_AWK} ${SCRIPTSDIR}/cargo-crates.awk ${CARGO_CARGOLOCK} # cargo-crates-generate-lockfile will try to generate a Cargo.lock file # if it does not exist. cargo-crates-generate-lockfile: extract @if [ ! -r "${CARGO_CARGOLOCK}" ]; then \ ${ECHO_MSG} "===> ${CARGO_CARGOLOCK} not found. Trying to generate it..."; \ cd ${CARGO_CARGOLOCK:H}; ${_CARGO_RUN} generate-lockfile \ --manifest-path ${CARGO_CARGOTOML} \ --verbose; \ fi # cargo-crates-licenses will try to grab license information from # all downloaded crates. cargo-crates-licenses: configure @${FIND} ${CARGO_VENDOR_DIR} -name 'Cargo.toml' -maxdepth 2 \ -exec ${GREP} -H '^license' {} \; \ | ${SED} \ -e 's@^${CARGO_VENDOR_DIR}/@@' \ -e 's@/Cargo.toml:license.*= *"@|@' \ -e 's@"$$@@g' | sort | /usr/bin/column -t -s '|' # cargo-crates-merge will in-place update CARGO_CRATES in the port # based on the crates list from Cargo.lock. If there is no Cargo.lock # for some reason, try and generate it first. cargo-crates-merge: @if ! type portedit > /dev/null 2>&1; then \ ${ECHO_MSG} "===> Please install \"ports-mgmt/portfmt\""; exit 1; \ fi @${MAKE} clean cargo-crates-generate-lockfile @f="${MASTERDIR}/Makefile"; [ -r "${MASTERDIR}/Makefile.crates" ] && f="${MASTERDIR}/Makefile.crates"; \ ${_CARGO_AWK} ${SCRIPTSDIR}/cargo-crates.awk ${CARGO_CARGOLOCK} | \ portedit merge -i $$f; \ ${MAKE} clean makesum; \ ${ECHO_MSG} "${DISTINFO_FILE} and CARGO_CRATES in $$f were updated"; .endif diff --git a/Mk/bsd.gecko.mk b/Mk/bsd.gecko.mk index 180161226b45..2a29a0a4c4da 100644 --- a/Mk/bsd.gecko.mk +++ b/Mk/bsd.gecko.mk @@ -1,384 +1,384 @@ #-*- tab-width: 4; -*- # ex:ts=4 # # Date created: 12 Nov 2005 # Whom: Michael Johnson # # 4 column tabs prevent hair loss and tooth decay! # bsd.gecko.mk abstracts the selection of gecko-based backends. It allows users # and porters to support any available gecko backend without needing to build # many conditional tests. ${USE_GECKO} is the list of backends that your port # can handle, and ${GECKO} is set by bsd.gecko.mk to be the chosen backend. # Users set ${WITH_GECKO} to the list of gecko backends they want on their # system. .if defined(USE_GECKO) . if !defined(_POSTMKINCLUDED) && !defined(Gecko_Pre_Include) Gecko_Pre_Include= bsd.gecko.mk # This file contains some reusable components for mozilla ports. It's of # use primarily to apps from the mozilla project itself (such as Firefox, # Thunderbird, etc.), and probably won't be of use for gecko-based ports # like epiphany, galeon, etc. # # You need to make sure to add USE_GECKO=gecko to for your port can uses # one of these options below. # # Ports can use the following: # # USE_MOZILLA By default, it enables every system dependency # listed in '_ALL_DEPENDS'. If your port doesn't # need one of those then you can use '-' like # 'USE_MOZILLA= -png -vpx' to subtract the # dependencies. Experimental deps use '+' like # 'USE_MOZILLA= +speex +theora'. # # MOZILLA_PLIST_DIRS List of directories to descend into when installing # and creating the plist # # MOZ_OPTIONS configure arguments (added to .mozconfig). If # NOMOZCONFIG is defined, you probably want to set # CONFIGURE_ARGS+=${MOZ_OPTIONS} # # MOZ_MK_OPTIONS The make(1) arguments (added to .mozconfig). If # NOMOZCONFIG is defined, you probably want to set # MAKE_ARGS+=${MOZ_MK_OPTIONS} # # MOZ_EXPORT Environment variables for the build process (added # to .mozconfig). If NOMOZCONFIG is defined, you # probably want to set MAKE_ENV+=${MOZ_EXPORT} # # NOMOZCONFIG Don't drop a customized .mozconfig into the build # directory. Options will have to be specified in # CONFIGURE_ARGS instead # MAINTAINER?= gecko@FreeBSD.org MOZILLA?= ${PORTNAME} MOZILLA_VER?= ${PORTVERSION} MOZILLA_BIN?= ${PORTNAME}-bin MOZILLA_EXEC_NAME?=${MOZILLA} USES+= compiler:c++17-lang cpe elfctl gl gmake gnome iconv \ llvm:min=17,noexport localbase nodejs:24,build,env \ pkgconfig python:build desktop-file-utils CPE_VENDOR?=mozilla USE_GL= gl USE_GNOME= cairo gdkpixbuf gtk30 USE_XORG= x11 xcb xcomposite xdamage xext xfixes xrandr xrender xt xtst HAS_CONFIGURE= yes CONFIGURE_OUTSOURCE= yes LDFLAGS+= -Wl,--as-needed -Wl,--undefined-version BINARY_ALIAS+= python3=${PYTHON_CMD} ELF_FEATURES+= +wxneeded:dist/bin/${MOZILLA} +wxneeded:dist/bin/${MOZILLA}-bin BUNDLE_LIBS= yes BUILD_DEPENDS+= rust-cbindgen>=0.29.4:devel/rust-cbindgen \ - ${RUST_DEFAULT}>=1.96.0:lang/${RUST_DEFAULT} + ${RUST_DEFAULT}>=1.97.0:lang/${RUST_DEFAULT} LIB_DEPENDS+= libdrm.so:graphics/libdrm RUN_DEPENDS+= ${LOCALBASE}/lib/libpci.so:devel/libpci LIB_DEPENDS+= libepoll-shim.so:devel/libepoll-shim MOZ_EXPORT+= ${CONFIGURE_ENV} \ PYTHON3="${PYTHON_CMD}" \ RUSTFLAGS="${RUSTFLAGS}" MOZ_OPTIONS+= --prefix="${PREFIX}" MOZ_MK_OPTIONS+=MOZ_OBJDIR="${BUILD_WRKSRC}" MOZ_OPTIONS+= --with-libclang-path="${LLVM_PREFIX:S/${PREFIX}/${LOCALBASE}/}/lib" . if !exists(/usr/bin/llvm-objdump) MOZ_EXPORT+= LLVM_OBJDUMP="${LOCALBASE}/bin/llvm-objdump${LLVM_VERSION}" . endif # Require newer Clang than what's in base system unless user opted out . if ${CC} == cc && ${CXX} == c++ && exists(/usr/lib/libc++.so) CPP= ${LOCALBASE}/bin/clang-cpp${LLVM_VERSION} CC= ${LOCALBASE}/bin/clang${LLVM_VERSION} CXX= ${LOCALBASE}/bin/clang++${LLVM_VERSION} USES:= ${USES:Ncompiler\:*} # XXX avoid warnings . endif MOZSRC?= ${WRKSRC} PLISTF?= ${WRKDIR}/plist_files MOZCONFIG?= ${WRKSRC}/.mozconfig MOZILLA_PLIST_DIRS?= bin lib share/pixmaps share/applications # Adjust -C target-cpu if -march/-mcpu is set by bsd.cpu.mk . if ${ARCH} == amd64 || ${ARCH} == i386 RUSTFLAGS+= ${CFLAGS:M-march=*:S/-march=/-C target-cpu=/} . elif ${ARCH:Mpowerpc*} RUSTFLAGS+= ${CFLAGS:M-mcpu=*:S/-mcpu=/-C target-cpu=/:S/power/pwr/} . else RUSTFLAGS+= ${CFLAGS:M-mcpu=*:S/-mcpu=/-C target-cpu=/} . endif # Standard depends _ALL_DEPENDS= av1 event ffi graphite harfbuzz jpeg nspr nss png pixman sqlite vpx webp av1_LIB_DEPENDS= libaom.so:multimedia/aom libdav1d.so:multimedia/dav1d av1_MOZ_OPTIONS= --with-system-av1 event_LIB_DEPENDS= libevent.so:devel/libevent event_MOZ_OPTIONS= --with-system-libevent ffi_LIB_DEPENDS= libffi.so:devel/libffi ffi_MOZ_OPTIONS= --enable-system-ffi . if exists(${FILESDIR}/patch-bug847568) graphite_LIB_DEPENDS= libgraphite2.so:graphics/graphite2 graphite_MOZ_OPTIONS= --with-system-graphite2 harfbuzz_LIB_DEPENDS= libharfbuzz.so:print/harfbuzz harfbuzz_MOZ_OPTIONS= --with-system-harfbuzz . endif icu_LIB_DEPENDS= libicui18n.so:devel/icu icu_MOZ_OPTIONS= --with-system-icu --with-intl-api -jpeg_BUILD_DEPENDS=yasm:devel/yasm jpeg_USES= jpeg jpeg_MOZ_OPTIONS= --with-system-jpeg=${LOCALBASE} nspr_LIB_DEPENDS= libnspr4.so:devel/nspr nspr_MOZ_OPTIONS= --with-system-nspr nss_LIB_DEPENDS= libnss3.so:security/nss nss_MOZ_OPTIONS= --with-system-nss pixman_LIB_DEPENDS= libpixman-1.so:x11/pixman pixman_MOZ_OPTIONS= --enable-system-pixman png_LIB_DEPENDS= libpng.so:graphics/png png_MOZ_OPTIONS= --with-system-png sqlite_LIB_DEPENDS= libsqlite3.so:databases/sqlite3 sqlite_MOZ_OPTIONS= --enable-system-sqlite -vpx_BUILD_DEPENDS= yasm:devel/yasm vpx_LIB_DEPENDS= libvpx.so:multimedia/libvpx vpx_MOZ_OPTIONS= --with-system-libvpx webp_LIB_DEPENDS= libwebp.so:graphics/webp webp_MOZ_OPTIONS= --with-system-webp . for use in ${USE_MOZILLA} ${use:S/-/_WITHOUT_/}= ${TRUE} . endfor LIB_DEPENDS+= libfontconfig.so:x11-fonts/fontconfig \ libfreetype.so:print/freetype2 . for dep in ${_ALL_DEPENDS} ${USE_MOZILLA:M+*:S/+//} . if !defined(_WITHOUT_${dep}) BUILD_DEPENDS+= ${${dep}_BUILD_DEPENDS} LIB_DEPENDS+= ${${dep}_LIB_DEPENDS} RUN_DEPENDS+= ${${dep}_RUN_DEPENDS} USES+= ${${dep}_USES} MOZ_OPTIONS+= ${${dep}_MOZ_OPTIONS} . else BUILD_DEPENDS+= ${-${dep}_BUILD_DEPENDS} . endif . endfor # Standard options MOZ_OPTIONS+= \ --enable-update-channel=${PKGNAMESUFFIX:Urelease:S/^-//} \ --disable-updater \ --with-system-zlib # API keys from www/chromium # http://www.chromium.org/developers/how-tos/api-keys # Note: these are for FreeBSD use ONLY. For your own distribution, # please get your own set of keys. MOZ_EXPORT+= MOZ_GOOGLE_LOCATION_SERVICE_API_KEY=AIzaSyBsp9n41JLW8jCokwn7vhoaMejDFRd1mp8 MOZ_EXPORT+= MOZ_GOOGLE_SAFEBROWSING_API_KEY=AIzaSyBsp9n41JLW8jCokwn7vhoaMejDFRd1mp8 . if ${PORT_OPTIONS:MOPTIMIZED_CFLAGS} CFLAGS+= -O3 MOZ_EXPORT+= MOZ_OPTIMIZE_FLAGS="${CFLAGS:M-O*}" MOZ_OPTIONS+= --enable-optimize . else MOZ_OPTIONS+= --disable-optimize . endif . if ${PORT_OPTIONS:MCANBERRA} RUN_DEPENDS+= libcanberra>0:audio/libcanberra . endif . if ${PORT_OPTIONS:MDBUS} BUILD_DEPENDS+= libnotify>0:devel/libnotify LIB_DEPENDS+= libdbus-1.so:devel/dbus \ libdbus-glib-1.so:devel/dbus-glib . else MOZ_OPTIONS+= --disable-dbus . endif . if ${PORT_OPTIONS:MFFMPEG} # dom/media/platforms/ffmpeg/FFmpegRuntimeLinker.cpp RUN_DEPENDS+= ffmpeg>=6.0,1:multimedia/ffmpeg . endif . if ${PORT_OPTIONS:MLIBPROXY} LIB_DEPENDS+= libproxy.so:net/libproxy MOZ_OPTIONS+= --enable-libproxy . else MOZ_OPTIONS+= --disable-libproxy . endif . if ${PORT_OPTIONS:MLTO} MOZ_OPTIONS+= --enable-lto=cross . endif . if ${PORT_OPTIONS:MALSA} BUILD_DEPENDS+= ${LOCALBASE}/include/alsa/asoundlib.h:audio/alsa-lib MOZ_OPTIONS+= --enable-alsa . endif . if ${PORT_OPTIONS:MJACK} BUILD_DEPENDS+= ${LOCALBASE}/include/jack/jack.h:audio/jack MOZ_OPTIONS+= --enable-jack . endif . if ${PORT_OPTIONS:MPULSEAUDIO} BUILD_DEPENDS+= ${LOCALBASE}/include/pulse/pulseaudio.h:audio/pulseaudio MOZ_OPTIONS+= --enable-pulseaudio . else MOZ_OPTIONS+= --disable-pulseaudio . endif . if ${PORT_OPTIONS:MSNDIO} BUILD_DEPENDS+= ${LOCALBASE}/include/sndio.h:audio/sndio MOZ_OPTIONS+= --enable-sndio . else MOZ_OPTIONS+= --disable-sndio . endif . if ${PORT_OPTIONS:MDEBUG} MOZ_OPTIONS+= --enable-debug --disable-release STRIP= # ports/184285 . else MOZ_OPTIONS+= --disable-debug --disable-debug-symbols --enable-release . if ${ARCH:Maarch64} || (defined(MACHINE_CPU) && ${MACHINE_CPU:Msse2}) MOZ_OPTIONS+= --enable-rust-simd . endif . endif . if ${PORT_OPTIONS:MPROFILE} MOZ_OPTIONS+= --enable-profiling STRIP= . else MOZ_OPTIONS+= --disable-profiling . endif . if ${PORT_OPTIONS:MTEST} USE_XORG+= xscrnsaver MOZ_OPTIONS+= --enable-tests . else MOZ_OPTIONS+= --disable-tests . endif . if !defined(STRIP) || ${STRIP} == "" MOZ_OPTIONS+= --disable-strip --disable-install-strip . else MOZ_OPTIONS+= --enable-strip --enable-install-strip . endif # _MAKE_JOBS is only available after bsd.port.post.mk, thus cannot be # used in .mozconfig. And client.mk automatically uses -jN where N # is what multiprocessing.cpu_count() returns. . if defined(DISABLE_MAKE_JOBS) || defined(MAKE_JOBS_UNSAFE) MAKE_JOBS_NUMBER= 1 . endif . if defined(MAKE_JOBS_NUMBER) MOZ_MAKE_FLAGS+=-j${MAKE_JOBS_NUMBER} . endif . if defined(MOZ_MAKE_FLAGS) MOZ_MK_OPTIONS+=MOZ_MAKE_FLAGS="${MOZ_MAKE_FLAGS}" . endif . if ${ARCH} == amd64 . if ${USE_MOZILLA:M-nss} USE_BINUTILS= # intel-gcm.s CFLAGS+= -B${LOCALBASE}/bin LDFLAGS+= -B${LOCALBASE}/bin . endif . elif ${ARCH:Mpowerpc*} BUILD_DEPENDS+= as:devel/binutils . endif . else # bsd.port.post.mk post-patch: gecko-post-patch gecko-post-patch: @${RM} ${MOZCONFIG} . if !defined(NOMOZCONFIG) . for arg in ${MOZ_OPTIONS} @${ECHO_CMD} ac_add_options ${arg:Q} >> ${MOZCONFIG} . endfor . for arg in ${MOZ_MK_OPTIONS} @${ECHO_CMD} mk_add_options ${arg:Q} >> ${MOZCONFIG} . endfor . for var in ${MOZ_EXPORT} @${ECHO_CMD} export ${var:Q} >> ${MOZCONFIG} . endfor . endif # .if !defined(NOMOZCONFIG) . if ${USE_MOZILLA:M-nspr} @${ECHO_MSG} "===> Applying NSPR patches" @for i in ${.CURDIR}/../../devel/nspr/files/patch-*; do \ ${PATCH} ${PATCH_ARGS} -d ${MOZSRC}/nsprpub < $$i; \ done . endif . if ${USE_MOZILLA:M-nss} @${ECHO_MSG} "===> Applying NSS patches" @for i in ${.CURDIR}/../../security/nss/files/patch-*; do \ ${PATCH} ${PATCH_ARGS} -d ${MOZSRC}/security/nss < $$i; \ done . endif @if [ -f ${WRKSRC}/config/baseconfig.mk ] ; then \ ${REINPLACE_CMD} -e 's|%%MOZILLA%%|${MOZILLA}|g' \ ${WRKSRC}/config/baseconfig.mk; \ fi @${REINPLACE_CMD} -e 's|%%MOZILLA%%|${MOZILLA}|g' \ ${MOZSRC}/config/baseconfig.mk @${REINPLACE_CMD} -e 's|/usr/local/netscape|${LOCALBASE}|g ; \ s|/usr/local/lib/netscape|${LOCALBASE}/lib|g' \ ${MOZSRC}/xpcom/io/SpecialSystemDirectory.cpp @${REINPLACE_CMD} -e 's|/etc|${PREFIX}&|g' \ ${MOZSRC}/xpcom/build/nsXPCOMPrivate.h @${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g' \ -e 's|mozilla/plugins|browser_plugins|g' \ -e 's|share/mozilla/extensions|lib/xpi|g' \ ${MOZSRC}/xpcom/io/nsAppFileLocationProvider.cpp \ ${MOZSRC}/toolkit/xre/nsXREDirProvider.cpp # Disable vendor checksums like lang/rust @${REINPLACE_CMD} 's,"files":{[^}]*},"files":{},' \ ${MOZSRC}/third_party/rust/*/.cargo-checksum.json # Thunderbird has rust crates in the comm dir @if [ -d ${MOZSRC}/comm/third_party/rust ] ; then \ ${REINPLACE_CMD} 's,"files":{[^}]*},"files":{},' \ ${MOZSRC}/comm/third_party/rust/*/.cargo-checksum.json; \ fi pre-configure-script: # Check that the running kernel has COMPAT_FREEBSD11 required by lang/rust post-ino64 @${SETENV} CC="${CC}" OPSYS="${OPSYS}" OSVERSION="${OSVERSION}" WRKDIR="${WRKDIR}" \ ${SH} ${SCRIPTSDIR}/rust-compat11-canary.sh post-install-script: gecko-create-plist gecko-create-plist: # Create the plist ${RM} ${PLISTF} . for dir in ${MOZILLA_PLIST_DIRS} @cd ${STAGEDIR}${PREFIX}/${dir} && ${FIND} -H -s * ! -type d | \ ${SED} -e 's|^|${dir}/|' >> ${PLISTF} . endfor ${CAT} ${PLISTF} | ${SORT} >> ${TMPPLIST} . endif .endif # HERE THERE BE TACOS -- adamw diff --git a/lang/rust-bootstrap/Makefile b/lang/rust-bootstrap/Makefile index 9b7667c1f4a4..f6c305702d9f 100644 --- a/lang/rust-bootstrap/Makefile +++ b/lang/rust-bootstrap/Makefile @@ -1,148 +1,148 @@ # Once the bootstraps are available on pkg.FreeBSD.org run sync.sh # to upload them to ~/public_distfiles on freefall in preparation # for the next lang/rust update. PORTNAME= rust -PORTVERSION= 1.96.1 +PORTVERSION= 1.97.1 CATEGORIES= lang MASTER_SITES= https://static.rust-lang.org/dist/ PKGNAMEPREFIX= ${FLAVOR:S/_/-/g}- PKGNAMESUFFIX= -bootstrap DISTNAME= ${PORTNAME}c-${PORTVERSION}-src DIST_SUBDIR= rust MAINTAINER= rust@FreeBSD.org COMMENT= Create bootstrap compilers for building lang/rust WWW= https://www.rust-lang.org/ LICENSE= APACHE20 MIT LICENSE_COMB= dual LICENSE_FILE_APACHE20= ${WRKSRC}/LICENSE-APACHE LICENSE_FILE_MIT= ${WRKSRC}/LICENSE-MIT ONLY_FOR_ARCHS= aarch64 amd64 powerpc64 powerpc64le ONLY_FOR_ARCHS_REASON= untested on other architectures BUILD_DEPENDS= ${FLAVOR:S/_/-/g}-freebsd-sysroot>=a2021.09.14:devel/freebsd-sysroot@${FLAVOR} \ cmake:devel/cmake-core \ gmake:devel/gmake \ rust>=${PORTVERSION}:lang/rust FLAVORS= aarch64 amd64 armv7 i386 powerpc powerpc64 powerpc64le riscv64 FLAVOR?= ${FLAVORS:[1]} USES= cpe ninja:build perl5 python:build tar:xz CPE_VENDOR= ${PORTNAME}-lang # for openssl-src crate USE_PERL5= build PATCHDIR= ${.CURDIR}/../rust/files # rustc stashes intermediary files in TMPDIR (default /tmp) which # might cause issues for users that for some reason space limit # their /tmp. WRKDIR should have plenty of space. # ?= to allow users to still overwrite it in make.conf. TMPDIR?= ${WRKDIR} # Resulting packages are not specific to amd64 NO_ARCH= yes _CARGO_VENDOR_DIR= ${WRKSRC}/vendor _RUST_ARCH_amd64= x86_64 _RUST_ARCH_i386= i686 _RUST_ARCH_powerpc64= powerpc64 _RUST_ARCH_riscv64= riscv64gc _RUST_HOST= ${_RUST_ARCH_${ARCH}:U${ARCH}}-unknown-${OPSYS:tl} _RUST_TARGET= ${_RUST_ARCH_${FLAVOR}:U${FLAVOR}}-unknown-${OPSYS:tl} _RUST_LLVM_TARGET= ${_RUST_LLVM_TARGET_${FLAVOR}} _RUST_LLVM_TARGET_aarch64= AArch64 _RUST_LLVM_TARGET_amd64= X86 _RUST_LLVM_TARGET_armv7= ARM _RUST_LLVM_TARGET_i386= X86 _RUST_LLVM_TARGET_powerpc64= PowerPC _RUST_LLVM_TARGET_powerpc64le= PowerPC _RUST_LLVM_TARGET_powerpc= PowerPC _RUST_LLVM_TARGET_riscv64= RISCV .include .if ${OPSYS} != FreeBSD IGNORE= is only for FreeBSD .endif .if exists(${PATCHDIR}/${FLAVOR:S/_/-/}) EXTRA_PATCHES+= ${PATCHDIR}/${FLAVOR:S/_/-/} .endif post-patch: # Disable vendor checksums @${REINPLACE_CMD} 's,"files":{[^}]*},"files":{},' \ ${_CARGO_VENDOR_DIR}/*/.cargo-checksum.json do-configure: # Check that the running kernel has COMPAT_FREEBSD11 required by lang/rust post-ino64 @${SETENV} CC="${CC}" OPSYS="${OPSYS}" OSVERSION="${OSVERSION}" WRKDIR="${WRKDIR}" \ ${SH} ${SCRIPTSDIR}/rust-compat11-canary.sh @${ECHO_CMD} '# https://github.com/rust-lang/rust/issues/135358 (bug #947897)' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'profile="dist"' >> ${WRKSRC}/config.toml @${ECHO_CMD} '[build]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'tools = ["cargo"]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'build-dir="${WRKDIR}/_build"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'vendor=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'extended=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'python="${PYTHON_CMD}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'docs=false' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'verbose=2' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cargo-native-static=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cargo="${LOCALBASE}/bin/cargo"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'rustc="${LOCALBASE}/bin/rustc"' >> ${WRKSRC}/config.toml .if ${_RUST_HOST} != ${_RUST_TARGET} @${ECHO_CMD} 'host=["${_RUST_HOST}","${_RUST_TARGET}"]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'target=["${_RUST_TARGET}"]' >> ${WRKSRC}/config.toml .endif .if defined(WITH_CCACHE_BUILD) && !defined(NO_CCACHE) @${ECHO_CMD} 'ccache="${CCACHE_BIN}"' >> ${WRKSRC}/config.toml .else @${ECHO_CMD} 'ccache=false' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} '[rust]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'channel="stable"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'default-linker="${CC}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'deny-warnings=false' >> ${WRKSRC}/config.toml @${ECHO_CMD} '[llvm]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'download-ci-llvm=false' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'link-shared=false' >> ${WRKSRC}/config.toml # https://github.com/rust-lang/rust/pull/72696#issuecomment-641517185 @${ECHO_CMD} 'ldflags="-lz"' >> ${WRKSRC}/config.toml # we need to make sure to always build llvm with host arch support to get a # host compiler that can build the host->target compiler @${ECHO_CMD} 'targets="${_RUST_LLVM_TARGET};${_RUST_LLVM_TARGET_${ARCH}}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} '[target.${_RUST_TARGET}]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cc="${LOCALBASE}/freebsd-sysroot/${FLAVOR:S/_/-/g}/bin/cc"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${LOCALBASE}/freebsd-sysroot/${FLAVOR:S/_/-/g}/bin/c++"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${LOCALBASE}/freebsd-sysroot/${FLAVOR:S/_/-/g}/bin/cc"' >> ${WRKSRC}/config.toml .for _key _util in ar ${AR} ranlib ${RANLIB} @bin="$$(which ${_util})"; \ ${ECHO_CMD} "${_key}=\"$$bin\"" >> ${WRKSRC}/config.toml .endfor .if ${_RUST_HOST} != ${_RUST_TARGET} @${ECHO_CMD} '[target.${_RUST_HOST}]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cc="${CC}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${CXX}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${CC}"' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} '[dist]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'compression-formats=["xz"]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'src-tarball=false' >> ${WRKSRC}/config.toml do-build: @cd ${WRKSRC} && \ ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} x.py dist --jobs=${MAKE_JOBS_NUMBER} do-install: @${MKDIR} ${STAGEDIR}${PREFIX}/rust-bootstrap/${FLAVOR} ${INSTALL_DATA} ${WRKDIR}/_build/dist/*-${_RUST_ARCH_${FLAVOR}:U${FLAVOR}}-unknown-${OPSYS:tl}${EXTRACT_SUFX} \ ${STAGEDIR}${PREFIX}/rust-bootstrap/${FLAVOR} # we only need rustc, std and cargo ${RM} ${STAGEDIR}${PREFIX}/rust-bootstrap/${FLAVOR}/rust-${PORTVERSION}-* \ ${STAGEDIR}${PREFIX}/rust-bootstrap/${FLAVOR}/rust*dev* @cd ${STAGEDIR}${PREFIX} && \ ${FIND} rust-bootstrap -type f >> ${TMPPLIST} .include diff --git a/lang/rust-bootstrap/distinfo b/lang/rust-bootstrap/distinfo index 115583c61db9..8324b9310fd3 100644 --- a/lang/rust-bootstrap/distinfo +++ b/lang/rust-bootstrap/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1784021515 -SHA256 (rust/rustc-1.96.1-src.tar.xz) = 77a6ff3003a4ad0cb00697b043c879e3e1a15d945b1a1f63818903bfc3fa8b98 -SIZE (rust/rustc-1.96.1-src.tar.xz) = 241602032 +TIMESTAMP = 1784478975 +SHA256 (rust/rustc-1.97.1-src.tar.xz) = 0ed06fdaffd4722a7702e0b4eebfafc897ab8f513e8e1b247cdd7e5c6df6ded2 +SIZE (rust/rustc-1.97.1-src.tar.xz) = 242787896 diff --git a/lang/rust-bootstrap/sync.sh b/lang/rust-bootstrap/sync.sh index 258f9b7cbc61..8febeafc7453 100644 --- a/lang/rust-bootstrap/sync.sh +++ b/lang/rust-bootstrap/sync.sh @@ -1,43 +1,43 @@ #!/bin/sh # Requires: pkg install yq # Upload Rust bootstraps available on pkg.FreeBSD.org to your # ~/public_distfiles on freefall for the next lang/rust update. # Change ABI below to select from which build to fetch the packages # from. set -xeu : "${PORTSDIR=/usr/ports}" : "${DATADIR=/tmp/rust-bootstrap}" fetch -qo /tmp/channel-rust-stable.toml https://dev-static.rust-lang.org/dist/channel-rust-stable.toml version=$( .if ${OPSYS} != FreeBSD IGNORE= is only for FreeBSD .endif .if ${ARCH} == powerpc LIB_DEPENDS+= libatomic.so:lang/gcc${GCC_DEFAULT} MAKE_ENV+= RUSTFLAGS="-L/usr/local/lib/gcc${GCC_DEFAULT}" .endif .if ${ARCH} != powerpc64le MAKE_ENV+= RUST_BACKTRACE=1 .endif # per https://rust-lang.github.io/rustup/concepts/components.html # rustc-dev and miri are only useful on nightly .if defined(NIGHTLY_DATE) _RUST_TOOLS+= miri cargo-miri _COMPONENTS+= rustc-dev-${_PACKAGE_VERS}-${_RUST_TARGET} \ miri-${_PACKAGE_VERS}-${_RUST_TARGET} .endif .if ${PORT_OPTIONS:MWASM} && ${PORT_OPTIONS:MDOCS} _COMPONENTS+= rust-docs-${_PACKAGE_VERS}-wasm32-unknown-unknown rust-docs-json-${_PACKAGE_VERS}-wasm32-unknown-unknown .endif .if exists(${PATCHDIR}/${ARCH}${BOOTSTRAPS_SUFFIX}) EXTRA_PATCHES+= ${PATCHDIR}/${ARCH}${BOOTSTRAPS_SUFFIX} .endif .ifdef QEMU_EMULATING IGNORE= fails to build with qemu-user-static .endif .if make(makesum) DISTFILES:= ${DISTFILES:M*\:src} \ ${ONLY_FOR_ARCHS:O:@_arch@${:!${MAKE} ARCH=${_arch} -V'DISTFILES:N*\:src'!}@} .endif post-patch: @${REINPLACE_CMD} 's,gdb,${LOCALBASE}/bin/gdb,' ${WRKSRC}/src/etc/rust-gdb .if defined(NIGHTLY_DATE) @${REINPLACE_CMD} '/rustfmt/d' ${WRKSRC}/src/stage0 .endif # Disable vendor checksums @${REINPLACE_CMD} 's,"files":{[^}]*},"files":{},' \ ${CARGO_VENDOR_DIR}/*/.cargo-checksum.json post-patch-PORT_LLVM-on: # WASM target hardcodes bundled lld @${REINPLACE_CMD} 's|"rust-lld"|"wasm-ld${LLVM_VERSION}"|' \ ${WRKSRC}/compiler/rustc_target/src/spec/base/wasm.rs do-configure: # Check that the running kernel has COMPAT_FREEBSD11 required by lang/rust post-ino64 @${SETENV} CC="${CC}" OPSYS="${OPSYS}" OSVERSION="${OSVERSION}" WRKDIR="${WRKDIR}" \ ${SH} ${SCRIPTSDIR}/rust-compat11-canary.sh .for _component in cargo rust-std rustc @cd ${WRKDIR}/${_component}-*-${OPSYS:tl} && \ ${SH} install.sh --prefix=${WRKDIR}/bootstrap --verbose .endfor @${ECHO_CMD} '[build]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'build-dir="${WRKDIR}/_build"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'build-stage=2' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'doc-stage=2' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'test-stage=2' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'vendor=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'extended=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'python="${PYTHON_CMD}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'docs=${_RUST_BUILD_DOCS}' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'verbose=2' >> ${WRKSRC}/config.toml .if defined(NIGHTLY_DATE) @${ECHO_CMD} 'profiler=true' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} 'target=[${_RUST_TARGETS:@.target.@"${.target.}"@:ts,}]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cargo="${WRKDIR}/bootstrap/bin/cargo"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'rustc="${WRKDIR}/bootstrap/bin/rustc"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'tools=[${_RUST_TOOLS:@.tool.@"${.tool.}"@:ts,}]' >> ${WRKSRC}/config.toml .if defined(WITH_CCACHE_BUILD) && !defined(NO_CCACHE) @${ECHO_CMD} 'ccache="${CCACHE_BIN}"' >> ${WRKSRC}/config.toml .else @${ECHO_CMD} 'ccache=false' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} '[install]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'prefix="${PREFIX}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'sysconfdir="${PREFIX}/etc"' >> ${WRKSRC}/config.toml @${ECHO_CMD} '[rust]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'channel="${PKGNAMESUFFIX:Ustable:S/^-//}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'default-linker="${CC}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'deny-warnings=false' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'verbose-tests=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'download-rustc=false' >> ${WRKSRC}/config.toml .if ${PORT_OPTIONS:MWASM} && !${PORT_OPTIONS:MPORT_LLVM} @${ECHO_CMD} 'lld=true' >> ${WRKSRC}/config.toml .else @${ECHO_CMD} 'lld=false' >> ${WRKSRC}/config.toml .endif .if ${PORT_OPTIONS:MLTO} @${ECHO_CMD} 'lto="thin"' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} 'remap-debuginfo=true' >> ${WRKSRC}/config.toml @${ECHO_CMD} '[llvm]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'download-ci-llvm=false' >> ${WRKSRC}/config.toml .if ${PORT_OPTIONS:MWASM} @${ECHO_CMD} 'clang=true' >> ${WRKSRC}/config.toml .endif .if ${PORT_OPTIONS:MLTO} @${ECHO_CMD} 'thin-lto=true' >> ${WRKSRC}/config.toml .endif @${ECHO_CMD} 'ninja=true' >> ${WRKSRC}/config.toml .if ${ARCH} == powerpc # Rust doesn't call the system compiler with the full version of the target. # This makes powerpc miscompile due to the secure-plt ABI change. # Additionally, force using ld.bfd to work around a linking problem in rustc_mir @${PRINTF} '#!/bin/sh\nexec ${CC} "$$@" --target=powerpc-unknown-freebsd13.5' > ${WRKDIR}/cc-wrapper @${CHMOD} +x ${WRKDIR}/cc-wrapper @${PRINTF} '#!/bin/sh\nexec ${CXX} "$$@" --target=powerpc-unknown-freebsd13.5' > ${WRKDIR}/cxx-wrapper @${CHMOD} +x ${WRKDIR}/cxx-wrapper .endif .for _target in ${_RUST_TARGETS} @${ECHO_CMD} '[target.${_target}]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'ar="${AR}"' >> ${WRKSRC}/config.toml .if ${ARCH} == powerpc @${ECHO_CMD} 'cc="${WRKDIR}/cc-wrapper"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${WRKDIR}/cxx-wrapper"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${CC}"' >> ${WRKSRC}/config.toml .else # use the builtin clang when not using PORT_LLVM .if ${_target} == "wasm32-unknown-unknown" .if ${PORT_OPTIONS:MPORT_LLVM} @${ECHO_CMD} 'cc="${LOCALBASE}/bin/clang${LLVM_VERSION}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${LOCALBASE}/bin/clang++${LLVM_VERSION}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${LOCALBASE}/bin/clang${LLVM_VERSION}"' >> ${WRKSRC}/config.toml .else @${ECHO_CMD} 'cc="${WRKDIR}/_build/${_RUST_TARGET}/llvm/bin/clang"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${WRKDIR}/_build/${_RUST_TARGET}/llvm/bin/clang++"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${WRKDIR}/_build/${_RUST_TARGET}/llvm/bin/clang"' >> ${WRKSRC}/config.toml .endif .else @${ECHO_CMD} 'cc="${CC}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'cxx="${CXX}"' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'linker="${CC}"' >> ${WRKSRC}/config.toml .endif .endif # powerpc .if ${PORT_OPTIONS:MPORT_LLVM} @${ECHO_CMD} 'llvm-config="${LOCALBASE}/bin/${LLVM_CONFIG}"' >> ${WRKSRC}/config.toml .endif .endfor @${ECHO_CMD} '[dist]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'compression-formats=["xz"]' >> ${WRKSRC}/config.toml @${ECHO_CMD} 'src-tarball=false' >> ${WRKSRC}/config.toml do-build: @cd ${WRKSRC} && \ ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} x.py dist --jobs=${MAKE_JOBS_NUMBER} do-install: ${RM} -r ${WRKDIR}/_extractdist .for _c in ${_COMPONENTS} ${MKDIR} ${WRKDIR}/_extractdist ${TAR} xf ${WRKDIR}/_build/dist/${_c}.tar.xz -C ${WRKDIR}/_extractdist cd ${WRKDIR}/_extractdist/${_c} && \ ${SH} install.sh \ --docdir="${STAGEDIR}${DOCSDIR}" \ --mandir="${STAGEDIR}${PREFIX}/share/man" \ --prefix="${STAGEDIR}${PREFIX}" ${RM} -r ${WRKDIR}/_extractdist .endfor # We autogenerate the plist file. We do that, instead of the # regular pkg-plist, because several libraries have a computed # filename based on the absolute path of the source files. As it # is user-specific, we cannot know their filename in advance. @${RM} ${STAGEDIR}${DOCSDIR}/*.old \ ${STAGEDIR}${PREFIX}/lib/rustlib/components \ ${STAGEDIR}${PREFIX}/lib/rustlib/install.log \ ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-* \ ${STAGEDIR}${PREFIX}/lib/rustlib/rust-installer-version \ ${STAGEDIR}${PREFIX}/lib/rustlib/uninstall.sh @${FIND} ${STAGEDIR}${PREFIX}/bin ${STAGEDIR}${PREFIX}/lib \ ${STAGEDIR}${PREFIX}/libexec -exec ${FILE} -i {} + | \ ${AWK} -F: '/executable|sharedlib/ { print $$1 }' | ${XARGS} ${STRIP_CMD} @${FIND} ${STAGEDIR}${PREFIX} -not -type d | \ ${SED} -E -e 's,^${STAGEDIR}${PREFIX}/,,' \ -e 's,(share/man/man[1-9]/.*\.[0-9]),\1.gz,' >> ${TMPPLIST} post-install-DOCS-on: # Ignore any left behind empty directories in case some docs fail # to build (failures are ignored due to deny-warnings=false). @${FIND} ${STAGEDIR}${DOCSDIR}/html -empty -type d | \ ${SED} 's,^${STAGEDIR},@comment @dir ,' >> ${TMPPLIST} post-install-SOURCES-on: # Silence stage-qa warnings by sanitizing permissions on sources @${FIND} ${STAGEDIR}${PREFIX}/lib/rustlib/src -type f -exec ${CHMOD} \ ${SHAREMODE} {} + # Note that make test does not work when rust is already installed. do-test: @cd ${WRKSRC} && \ ${SETENV} ${TEST_ENV} ${PYTHON_CMD} x.py test --jobs=${MAKE_JOBS_NUMBER} .include diff --git a/lang/rust/distinfo b/lang/rust/distinfo index 937194eb4ec6..9df6ea243d5a 100644 --- a/lang/rust/distinfo +++ b/lang/rust/distinfo @@ -1,51 +1,51 @@ -TIMESTAMP = 1782887481 -SHA256 (rust/rustc-1.96.1-src.tar.xz) = 77a6ff3003a4ad0cb00697b043c879e3e1a15d945b1a1f63818903bfc3fa8b98 -SIZE (rust/rustc-1.96.1-src.tar.xz) = 241602032 -SHA256 (rust/2026-04-16/rustc-1.95.0-aarch64-unknown-freebsd.tar.xz) = 3eeb0832d01e8f3ba7aef33f960670b8d7a4b087f7f7b4e9a7a7da6ef352a286 -SIZE (rust/2026-04-16/rustc-1.95.0-aarch64-unknown-freebsd.tar.xz) = 47344088 -SHA256 (rust/2026-04-16/rust-std-1.95.0-aarch64-unknown-freebsd.tar.xz) = 65a0907f39ec2088102aa9c7812cc2c33a8d70e24e9967e8d50e440b5fac6cb0 -SIZE (rust/2026-04-16/rust-std-1.95.0-aarch64-unknown-freebsd.tar.xz) = 23191068 -SHA256 (rust/2026-04-16/cargo-1.95.0-aarch64-unknown-freebsd.tar.xz) = ee96615bc43604f06b13faf53e1d7bb57843e319fc38ff252b7e67231ea0be3f -SIZE (rust/2026-04-16/cargo-1.95.0-aarch64-unknown-freebsd.tar.xz) = 9781756 -SHA256 (rust/2026-04-16/rustc-1.95.0-x86_64-unknown-freebsd.tar.xz) = 0a030920c1cc218bf9f48680954d94e54bae77b5014d5c0121007a6886088e80 -SIZE (rust/2026-04-16/rustc-1.95.0-x86_64-unknown-freebsd.tar.xz) = 43043652 -SHA256 (rust/2026-04-16/rust-std-1.95.0-x86_64-unknown-freebsd.tar.xz) = 8a97b55ed5b9a5f98e3c543a56c64afff0ed9659a8beadf534abb0a083e9a1f5 -SIZE (rust/2026-04-16/rust-std-1.95.0-x86_64-unknown-freebsd.tar.xz) = 24711212 -SHA256 (rust/2026-04-16/cargo-1.95.0-x86_64-unknown-freebsd.tar.xz) = a6a5396b37f3e07c3efdd19ff10bf745132eea9b1292272b9ef170663efb306d -SIZE (rust/2026-04-16/cargo-1.95.0-x86_64-unknown-freebsd.tar.xz) = 11140312 -SHA256 (rust/2026-04-16/rustc-1.95.0-armv7-unknown-freebsd.tar.xz) = 4e1daa217201cd1759efe4f8cbf61516654656d4c6fba603c4f34135b8530129 -SIZE (rust/2026-04-16/rustc-1.95.0-armv7-unknown-freebsd.tar.xz) = 47639612 -SHA256 (rust/2026-04-16/rust-std-1.95.0-armv7-unknown-freebsd.tar.xz) = 29de9f72cb05badabf9640ba2e24be83bdbb0c34dbfae882b6afdab7131c04bb -SIZE (rust/2026-04-16/rust-std-1.95.0-armv7-unknown-freebsd.tar.xz) = 22452548 -SHA256 (rust/2026-04-16/cargo-1.95.0-armv7-unknown-freebsd.tar.xz) = a70fccf3e3e59edcf10cf72888f7d4e09d26333623c53ff08683348afd13bbb8 -SIZE (rust/2026-04-16/cargo-1.95.0-armv7-unknown-freebsd.tar.xz) = 10080804 -SHA256 (rust/2026-04-16/rustc-1.95.0-i686-unknown-freebsd.tar.xz) = 9b73938a3e339bbbcc6690f6351d6e0d8cf113c70fbf772584c58c13d6518612 -SIZE (rust/2026-04-16/rustc-1.95.0-i686-unknown-freebsd.tar.xz) = 53910620 -SHA256 (rust/2026-04-16/rust-std-1.95.0-i686-unknown-freebsd.tar.xz) = e3f36055187c3e3d1a2182c86ef06f455d1d68474cf05222623e84fa69a2791f -SIZE (rust/2026-04-16/rust-std-1.95.0-i686-unknown-freebsd.tar.xz) = 24316300 -SHA256 (rust/2026-04-16/cargo-1.95.0-i686-unknown-freebsd.tar.xz) = 673ecde99418b1d13582b6eae1dcc1037560f082c434d1eb95eec53888cea386 -SIZE (rust/2026-04-16/cargo-1.95.0-i686-unknown-freebsd.tar.xz) = 11844776 -SHA256 (rust/2026-04-16/rustc-1.95.0-powerpc-unknown-freebsd.tar.xz) = cf4b63d877c3476dc148337f5312ebd20ae710693ca71c1202fef9610cd62a92 -SIZE (rust/2026-04-16/rustc-1.95.0-powerpc-unknown-freebsd.tar.xz) = 48629552 -SHA256 (rust/2026-04-16/rust-std-1.95.0-powerpc-unknown-freebsd.tar.xz) = 42b0a63d154f1e90d4e97f9a078bac497c8baf49c4541e122b2e9e83b2849e9f -SIZE (rust/2026-04-16/rust-std-1.95.0-powerpc-unknown-freebsd.tar.xz) = 21520632 -SHA256 (rust/2026-04-16/cargo-1.95.0-powerpc-unknown-freebsd.tar.xz) = 9a698cfa8a0630064584a5df15f41841cd31d56fc2c7b0516514d9229f76e90b -SIZE (rust/2026-04-16/cargo-1.95.0-powerpc-unknown-freebsd.tar.xz) = 10185700 -SHA256 (rust/2026-04-16/rustc-1.95.0-powerpc64-unknown-freebsd.tar.xz) = febf261b1b74493b7a7fce6b0ccb7529f21ee0658e9f29b3f5799032f2d8e347 -SIZE (rust/2026-04-16/rustc-1.95.0-powerpc64-unknown-freebsd.tar.xz) = 47504824 -SHA256 (rust/2026-04-16/rust-std-1.95.0-powerpc64-unknown-freebsd.tar.xz) = 0671a6d9315dbfdf92b9c0840364002d006166b69fe3a1c3bf7bdba42fb5534e -SIZE (rust/2026-04-16/rust-std-1.95.0-powerpc64-unknown-freebsd.tar.xz) = 21538320 -SHA256 (rust/2026-04-16/cargo-1.95.0-powerpc64-unknown-freebsd.tar.xz) = d850049c1d7cd863ed67e58fd02a787c3650be6eca1aefb7952da924b25e00de -SIZE (rust/2026-04-16/cargo-1.95.0-powerpc64-unknown-freebsd.tar.xz) = 10367508 -SHA256 (rust/2026-04-16/rustc-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = b216594c2351f59a012587d98cd7ad3c437460406531dd8ba47ad2331bed78fe -SIZE (rust/2026-04-16/rustc-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = 50062304 -SHA256 (rust/2026-04-16/rust-std-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = d84f5e3e85c0ebfa8a1fab25d032c6c8cf526b5e51c6a483fb49d5429e18455c -SIZE (rust/2026-04-16/rust-std-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = 21380196 -SHA256 (rust/2026-04-16/cargo-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = b1d000b03834a0485a33828e403be0a0b492ca11628b0cef6e762eb36b82c4f1 -SIZE (rust/2026-04-16/cargo-1.95.0-powerpc64le-unknown-freebsd.tar.xz) = 10925304 -SHA256 (rust/2026-04-16/rustc-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = a933d8f0bb2e57c9a7cdb7abeb7e82c715daefe11992273a17784e2a88cf8359 -SIZE (rust/2026-04-16/rustc-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = 51350904 -SHA256 (rust/2026-04-16/rust-std-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = cd8a3dfcbad74102419e44c96c2e04ae95e4032a17fde0c4d530b4c32723f136 -SIZE (rust/2026-04-16/rust-std-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = 21496384 -SHA256 (rust/2026-04-16/cargo-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = 3403e0ff5ccc20d8e79f2025f540929fc5a2165d6e2ef6db18282c83f4364193 -SIZE (rust/2026-04-16/cargo-1.95.0-riscv64gc-unknown-freebsd.tar.xz) = 10903448 +TIMESTAMP = 1784478952 +SHA256 (rust/rustc-1.97.1-src.tar.xz) = 0ed06fdaffd4722a7702e0b4eebfafc897ab8f513e8e1b247cdd7e5c6df6ded2 +SIZE (rust/rustc-1.97.1-src.tar.xz) = 242787896 +SHA256 (rust/2026-05-28/rustc-1.96.0-aarch64-unknown-freebsd.tar.xz) = d57e8d35ed6e92e485e3602214b649301c21e01741f05f8c61992fe73dc280fc +SIZE (rust/2026-05-28/rustc-1.96.0-aarch64-unknown-freebsd.tar.xz) = 47498768 +SHA256 (rust/2026-05-28/rust-std-1.96.0-aarch64-unknown-freebsd.tar.xz) = 80c0caad7dc4f2d63c8efdc7fd65a702caa2d2337374c385d42d4ea3ec3bf8a3 +SIZE (rust/2026-05-28/rust-std-1.96.0-aarch64-unknown-freebsd.tar.xz) = 23315460 +SHA256 (rust/2026-05-28/cargo-1.96.0-aarch64-unknown-freebsd.tar.xz) = 75a1ce386d13388a6d8d7c8ddca4286302609ccb86a5a1227d9fc44f74094a23 +SIZE (rust/2026-05-28/cargo-1.96.0-aarch64-unknown-freebsd.tar.xz) = 9942184 +SHA256 (rust/2026-05-28/rustc-1.96.0-x86_64-unknown-freebsd.tar.xz) = 8aacf40817160e47393716b4ed0e7741ede1791fc61a736d4dd55b2b58d0a7eb +SIZE (rust/2026-05-28/rustc-1.96.0-x86_64-unknown-freebsd.tar.xz) = 43291784 +SHA256 (rust/2026-05-28/rust-std-1.96.0-x86_64-unknown-freebsd.tar.xz) = f12eeaf3c1e30b2ecd526e141ed3171dd6832ec32f8a8f3be8d642ddc3786d3b +SIZE (rust/2026-05-28/rust-std-1.96.0-x86_64-unknown-freebsd.tar.xz) = 24701840 +SHA256 (rust/2026-05-28/cargo-1.96.0-x86_64-unknown-freebsd.tar.xz) = 311f38854162420177ccbf94352a55ceab35e49e3b626f6e94fc8bbf71b2be01 +SIZE (rust/2026-05-28/cargo-1.96.0-x86_64-unknown-freebsd.tar.xz) = 11336884 +SHA256 (rust/2026-05-28/rustc-1.96.0-armv7-unknown-freebsd.tar.xz) = a6efda4f3b6974c63fb58d58d539eacb5372c7be69d46bbb8452af3fbaad3592 +SIZE (rust/2026-05-28/rustc-1.96.0-armv7-unknown-freebsd.tar.xz) = 47726512 +SHA256 (rust/2026-05-28/rust-std-1.96.0-armv7-unknown-freebsd.tar.xz) = d1255fb87265e2a4d32a99cfb6eb35ffdeeba5fafafbfbc8e101b85d71b352c9 +SIZE (rust/2026-05-28/rust-std-1.96.0-armv7-unknown-freebsd.tar.xz) = 22642296 +SHA256 (rust/2026-05-28/cargo-1.96.0-armv7-unknown-freebsd.tar.xz) = 6189eb5f73c586fa852d251a57f62d86a152b7a600f4a9301408d9c4db9c1992 +SIZE (rust/2026-05-28/cargo-1.96.0-armv7-unknown-freebsd.tar.xz) = 10221740 +SHA256 (rust/2026-05-28/rustc-1.96.0-i686-unknown-freebsd.tar.xz) = 39c34869260270f000bad3a1257fb71c7c69240a08980ceb59ee0767cb27ea30 +SIZE (rust/2026-05-28/rustc-1.96.0-i686-unknown-freebsd.tar.xz) = 54155880 +SHA256 (rust/2026-05-28/rust-std-1.96.0-i686-unknown-freebsd.tar.xz) = 7c64b5702a74635ec2c7dd69db8379c8caf0c0aaf51bbf1eb8bb7c035d0988a5 +SIZE (rust/2026-05-28/rust-std-1.96.0-i686-unknown-freebsd.tar.xz) = 24592796 +SHA256 (rust/2026-05-28/cargo-1.96.0-i686-unknown-freebsd.tar.xz) = 5bc96abe47495c24225f8d05c261165a7c59df1dcf6e002aa9fb33ba7aaa3a52 +SIZE (rust/2026-05-28/cargo-1.96.0-i686-unknown-freebsd.tar.xz) = 11993776 +SHA256 (rust/2026-05-28/rustc-1.96.0-powerpc-unknown-freebsd.tar.xz) = 75bace04960c2c99226a36f992a1f6d6bc0644f1086a07989e0687c2a5b1dec9 +SIZE (rust/2026-05-28/rustc-1.96.0-powerpc-unknown-freebsd.tar.xz) = 48570032 +SHA256 (rust/2026-05-28/rust-std-1.96.0-powerpc-unknown-freebsd.tar.xz) = 9e92a95d05820ff7115c55c644e0955b7da9f444f6b6441468043eb97d034109 +SIZE (rust/2026-05-28/rust-std-1.96.0-powerpc-unknown-freebsd.tar.xz) = 21744484 +SHA256 (rust/2026-05-28/cargo-1.96.0-powerpc-unknown-freebsd.tar.xz) = 1bd0b37015bb69cfae6020263de2abe685523a79270ec8d699ed6e53fdbee262 +SIZE (rust/2026-05-28/cargo-1.96.0-powerpc-unknown-freebsd.tar.xz) = 10330852 +SHA256 (rust/2026-05-28/rustc-1.96.0-powerpc64-unknown-freebsd.tar.xz) = ad492433be985c31107e6b891c87012a446791cb128a1d3dd60d954b640bab13 +SIZE (rust/2026-05-28/rustc-1.96.0-powerpc64-unknown-freebsd.tar.xz) = 47536756 +SHA256 (rust/2026-05-28/rust-std-1.96.0-powerpc64-unknown-freebsd.tar.xz) = 6371b5040de443fca0f0061280c1183254d48d7a93afe094be9781e1aeb8e4d6 +SIZE (rust/2026-05-28/rust-std-1.96.0-powerpc64-unknown-freebsd.tar.xz) = 21597024 +SHA256 (rust/2026-05-28/cargo-1.96.0-powerpc64-unknown-freebsd.tar.xz) = a9c90cb9531e1a3bdbc6a5e99ce549e0cedb59ee325e914dad8421162980f6a0 +SIZE (rust/2026-05-28/cargo-1.96.0-powerpc64-unknown-freebsd.tar.xz) = 10536468 +SHA256 (rust/2026-05-28/rustc-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = e0ab060011a82694579e2eaad4bfb6544c77079e754dfe9d3e6c930fe5bf8cb2 +SIZE (rust/2026-05-28/rustc-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = 50475884 +SHA256 (rust/2026-05-28/rust-std-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = 1563f982b45d2f3a22dd4cccc49fa07fa43935a15d17e3bedefb0e384a4d5ad4 +SIZE (rust/2026-05-28/rust-std-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = 21754020 +SHA256 (rust/2026-05-28/cargo-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = fa47487d43b9da031c7d9da61d6d2c72b44ca042104785653c63a90c16850e47 +SIZE (rust/2026-05-28/cargo-1.96.0-powerpc64le-unknown-freebsd.tar.xz) = 11131156 +SHA256 (rust/2026-05-28/rustc-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = dc4abdaf93d73b663dbbf3f136a21fad621494497ac0f07ef949ae4e737b952a +SIZE (rust/2026-05-28/rustc-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = 51730840 +SHA256 (rust/2026-05-28/rust-std-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = a39ae3b34a39f10139a5b3b04f9e6c60ebbd755b2e532ea8ba149d3f35f5875a +SIZE (rust/2026-05-28/rust-std-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = 21603272 +SHA256 (rust/2026-05-28/cargo-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = 77472db8fef7edb95d146017bcb25c04b382625e56a8e7d846910bb85e050a09 +SIZE (rust/2026-05-28/cargo-1.96.0-riscv64gc-unknown-freebsd.tar.xz) = 11063224 diff --git a/lang/rust/files/patch-vendor_openssl_crypto_threads__pthread.c b/lang/rust/files/patch-vendor_openssl_crypto_threads__pthread.c index b48f9ab6bb54..fce344f484ee 100644 --- a/lang/rust/files/patch-vendor_openssl_crypto_threads__pthread.c +++ b/lang/rust/files/patch-vendor_openssl_crypto_threads__pthread.c @@ -1,29 +1,29 @@ /usr/ports/security/openssl34/files/patch-crypto_threads__pthread.c --- vendor/openssl-src-300.5.0+3.5.0/openssl/crypto/threads_pthread.c.orig 2025-05-09 22:37:37.000000000 +0200 +++ vendor/openssl-src-300.5.0+3.5.0/openssl/crypto/threads_pthread.c 2025-05-21 14:44:18.563852000 +0200 @@ -50,6 +50,10 @@ __tsan_mutex_post_lock((x), 0, 0) # define BROKEN_CLANG_ATOMICS #endif +#if defined(__FreeBSD__) && (defined(__i386__) || (defined(__powerpc__) && defined(__ILP32__))) +#define BROKEN_CLANG_ATOMICS +#endif + #if defined(OPENSSL_THREADS) && !defined(CRYPTO_TDEBUG) && !defined(OPENSSL_SYS_WINDOWS) # if defined(OPENSSL_SYS_UNIX) ---- vendor/openssl-src-300.5.4+3.5.4/openssl/crypto/threads_pthread.c.orig 2025-05-09 22:37:37.000000000 +0200 -+++ vendor/openssl-src-300.5.4+3.5.4/openssl/crypto/threads_pthread.c 2025-05-21 14:44:18.563852000 +0200 +--- vendor/openssl-src-300.6.0+3.6.2/openssl/crypto/threads_pthread.c.orig 2025-05-09 22:37:37.000000000 +0200 ++++ vendor/openssl-src-300.6.0+3.6.2/openssl/crypto/threads_pthread.c 2025-05-21 14:44:18.563852000 +0200 @@ -50,6 +50,10 @@ __tsan_mutex_post_lock((x), 0, 0) # define BROKEN_CLANG_ATOMICS #endif +#if defined(__FreeBSD__) && (defined(__i386__) || (defined(__powerpc__) && defined(__ILP32__))) +#define BROKEN_CLANG_ATOMICS +#endif + #if defined(OPENSSL_THREADS) && !defined(CRYPTO_TDEBUG) && !defined(OPENSSL_SYS_WINDOWS) # if defined(OPENSSL_SYS_UNIX)