Annotation of pkgsrc/lang/rust/options.mk, Revision 1.11.2.1
1.11.2.1! bsiegert 1: # $NetBSD: options.mk,v 1.11 2021/02/25 08:54:05 wiz Exp $
1.1 nia 2:
1.5 adam 3: PKG_OPTIONS_VAR= PKG_OPTIONS.rust
1.9 jperkin 4: PKG_SUPPORTED_OPTIONS+= rust-cargo-static
1.1 nia 5:
6: .include "../../mk/bsd.fast.prefs.mk"
7:
8: # The bundled LLVM current has issues building on SunOS.
9: .if ${OPSYS} != "SunOS" && ${OPSYS} != "Darwin"
1.2 nia 10: PKG_SUPPORTED_OPTIONS+= rust-llvm
1.3 nia 11: # There may be compatibility issues with base LLVM.
12: . if !empty(HAVE_LLVM)
13: PKG_SUGGESTED_OPTIONS+= rust-llvm
14: . endif
1.1 nia 15: .endif
16:
1.11.2.1! bsiegert 17: # Bundle OpenSSL and curl into the cargo binary when producing
! 18: # bootstraps on NetBSD.
! 19: .if ${OPSYS} == "NetBSD" && ${BUILD_TARGET} == "dist"
1.8 he 20: PKG_SUGGESTED_OPTIONS+= rust-cargo-static
1.9 jperkin 21: .endif
1.8 he 22:
1.1 nia 23: .include "../../mk/bsd.options.mk"
24:
25: #
26: # Use the internal copy of LLVM.
27: # This contains some extra optimizations.
28: #
29: .if !empty(PKG_OPTIONS:Mrust-llvm)
30: BUILD_DEPENDS+= cmake-[0-9]*:../../devel/cmake
31: .include "../../devel/cmake/buildlink3.mk"
32: .else
33: .include "../../lang/llvm/buildlink3.mk"
34: CONFIGURE_ARGS+= --enable-llvm-link-shared
35: CONFIGURE_ARGS+= --llvm-root=${BUILDLINK_PREFIX.llvm}
1.6 adam 36: # XXX: fix for Rust 1.41.0 https://github.com/rust-lang/rust/issues/68714
37: MAKE_ENV+= LIBRARY_PATH=${BUILDLINK_PREFIX.llvm}/lib
1.1 nia 38: .endif
1.8 he 39:
40: #
41: # Link cargo statically against "native" libraries.
42: # (openssl and curl specifically).
43: #
44: .if !empty(PKG_OPTIONS:Mrust-cargo-static)
45: CONFIGURE_ARGS+= --enable-cargo-native-static
46: .else
47: BUILDLINK_API_DEPENDS.nghttp2+= nghttp2>=1.41.0
48: BUILDLINK_API_DEPENDS.curl+= curl>=7.67.0
49: .include "../../www/curl/buildlink3.mk"
50: .include "../../security/openssl/buildlink3.mk"
51: .endif
CVSweb <webmaster@jp.NetBSD.org>