Page MenuHomeFreeBSD

D2466.id5263.diff
No OneTemporary

D2466.id5263.diff

Index: lang/rust/Makefile
===================================================================
--- lang/rust/Makefile
+++ lang/rust/Makefile
@@ -2,8 +2,7 @@
# $FreeBSD$
PORTNAME= rust
-PORTVERSION= 0.12.0
-PORTREVISION= 1
+DISTVERSION= 1.0.0-beta.4
CATEGORIES= lang
MASTER_SITES= http://static.rust-lang.org/dist/:src \
http://static.rust-lang.org/stage0-snapshots/:bootstrap
@@ -23,17 +22,26 @@
ONLY_FOR_ARCHS= amd64
ONLY_FOR_ARCHS_REASON= requires prebuilt bootstrap compiler
-RUST_SOURCE= ${DISTNAME}${EXTRACT_SUFX}
+# FIXME: The bootstrapped rustc adds -L/usr/local/lib in front of
+# the LDFLAGS. When stage0's rustc is linked, it picks the installed
+# librust*so and fails.
+CONFLICTS_BUILD=rust
+
+RUST_SOURCE= rustc-${DISTVERSION}-src${EXTRACT_SUFX}
RUST_BOOT= rust-stage0-${RUST_BOOT_SIG}.tar.bz2
-RUST_BOOT_SIG= 2014-10-04-749ff5e-freebsd-x86_64-f39d94487d29b3d48217b1295ad2cda8c941e694
+RUST_BOOT_SIG= 2015-03-27-5520801-freebsd-x86_64-0910bbad35e213f679d0433884fd51398eb3bc8d
+
+WRKSRC= ${WRKDIR}/rustc-${DISTVERSION}
-USES= gmake perl5 python:2
+USES= gmake python:2,build
HAS_CONFIGURE= yes
-CONFIGURE_ARGS= --disable-valgrind --disable-docs \
- --enable-clang --mandir=${MANPREFIX}/man
+CONFIGURE_ARGS= --disable-valgrind --disable-docs --mandir=${MANPREFIX}/man
USE_LDCONFIG= yes
-USE_PERL5= build
-MAKE_ARGS= ARCH=x86_64
+
+# Use LLVM from ports, instead of the copy shipped with rust.
+LLVM_VER= 36
+BUILD_DEPENDS+= llvm${LLVM_VER}>=0:${PORTSDIR}/devel/llvm${LLVM_VER}
+CONFIGURE_ARGS+=--llvm-root=${LOCALBASE}/llvm${LLVM_VER}
.if defined(BATCH) || defined(PACKAGE_BUILDING)
MAKE_ARGS+= VERBOSE=1
@@ -58,9 +66,31 @@
@${MKDIR} ${WRKSRC}/dl
${LN} -sf ${DISTDIR}/${RUST_BOOT} ${WRKSRC}/dl
+# In case the previous "make stage" failed, this ensures rust's
+# install.sh won't backup previously staged files before reinstalling
+# new ones. Otheriwe, the staging directory is polluted with unneeded
+# files.
+pre-install:
+ @if test -f ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rustc; then \
+ ${SED} -E -e 's,^(dir|file:),${STAGEDIR},' \
+ < ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rustc \
+ | xargs ${RM}; \
+ fi
+ @${RM} \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/components \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rustc \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/rust-installer-version \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/uninstall.sh
+
post-install:
- @${RM} ${STAGEDIR}${PREFIX}/lib/rustlib/manifest
- @${STRIP_CMD} `${GREP} -v -e '^@dir' -e '^man' -e 'rlib$$' \
- -e '^.*\.a$$' ${PLIST} | ${SED} 's:^:${STAGEDIR}${PREFIX}/:'`
+ @${RM} ${STAGEDIR}${PREFIX}/lib/rustlib/install.log
+ @${REINPLACE_CMD} -e 's|${STAGEDIR}||' \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rustc
+ @${RM} ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rustc.bak
+ @${STRIP_CMD} \
+ ${STAGEDIR}${PREFIX}/bin/rustc \
+ ${STAGEDIR}${PREFIX}/bin/rustdoc \
+ ${STAGEDIR}${PREFIX}/lib/*.so \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/*/lib/*.so
.include <bsd.port.post.mk>
Index: lang/rust/distinfo
===================================================================
--- lang/rust/distinfo
+++ lang/rust/distinfo
@@ -1,4 +1,4 @@
-SHA256 (rust-0.12.0.tar.gz) = 883e66b24d90d9957c5c538469fcde6f0668e5fb6448beecfc60884060e769b7
-SIZE (rust-0.12.0.tar.gz) = 21223176
-SHA256 (rust-stage0-2014-10-04-749ff5e-freebsd-x86_64-f39d94487d29b3d48217b1295ad2cda8c941e694.tar.bz2) = 3f486b75a92c96b4bb63cb043037e6ff58bf5adde9d29e9e197959d6959de0b2
-SIZE (rust-stage0-2014-10-04-749ff5e-freebsd-x86_64-f39d94487d29b3d48217b1295ad2cda8c941e694.tar.bz2) = 12701560
+SHA256 (rustc-1.0.0-beta.4-src.tar.gz) = 54e5868dd55a5c171327c72d662b5931a962b0cf160022d11c189ea232e0bd91
+SIZE (rustc-1.0.0-beta.4-src.tar.gz) = 22077195
+SHA256 (rust-stage0-2015-03-27-5520801-freebsd-x86_64-0910bbad35e213f679d0433884fd51398eb3bc8d.tar.bz2) = a422bd36bc81c9b0dbf0f3b6f5aae34cae6772b7bdffb6c46797cb2931b5e210
+SIZE (rust-stage0-2015-03-27-5520801-freebsd-x86_64-0910bbad35e213f679d0433884fd51398eb3bc8d.tar.bz2) = 15611104
Index: lang/rust/files/patch-configure
===================================================================
--- lang/rust/files/patch-configure
+++ /dev/null
@@ -1,25 +0,0 @@
---- configure.orig 2014-01-20 12:44:20.637789551 +0800
-+++ configure 2014-01-20 12:45:23.726260411 +0800
-@@ -424,7 +424,6 @@
- step_msg "looking for build programs"
-
- probe_need CFG_PERL perl
--probe_need CFG_CURLORWGET curl wget
- probe_need CFG_PYTHON python2.7 python2.6 python2 python
-
- python_version=$($CFG_PYTHON -V 2>&1)
-@@ -547,14 +546,6 @@
- fi
- fi
-
--# Force freebsd to build with clang; gcc doesn't like us there
--if [ $CFG_OSTYPE = unknown-freebsd ]
--then
-- step_msg "on FreeBSD, forcing use of clang"
-- CFG_ENABLE_CLANG=1
-- putvar CFG_ENABLE_CLANG
--fi
--
- if [ -z "$CFG_ENABLE_CLANG" -a -z "$CFG_GCC" ]
- then
- err "either clang or gcc is required"
Index: lang/rust/files/patch-src_librustc__back_target_freebsd__base.rs
===================================================================
--- /dev/null
+++ lang/rust/files/patch-src_librustc__back_target_freebsd__base.rs
@@ -0,0 +1,12 @@
+--- src/librustc_back/target/freebsd_base.rs.orig 2015-05-07 14:37:17 UTC
++++ src/librustc_back/target/freebsd_base.rs
+@@ -19,9 +19,6 @@ pub fn opts() -> TargetOptions {
+ morestack: true,
+ has_rpath: true,
+ pre_link_args: vec!(
+- "-L/usr/local/lib".to_string(),
+- "-L/usr/local/lib/gcc46".to_string(),
+- "-L/usr/local/lib/gcc44".to_string(),
+ ),
+
+ .. Default::default()
Index: lang/rust/pkg-plist
===================================================================
--- lang/rust/pkg-plist
+++ lang/rust/pkg-plist
@@ -1,91 +1,80 @@
+bin/rust-gdb
bin/rustc
bin/rustdoc
+lib/libarena-4e7c5e5c.so
+lib/libflate-4e7c5e5c.so
+lib/libfmt_macros-4e7c5e5c.so
lib/libgetopts-4e7c5e5c.so
+lib/libgraphviz-4e7c5e5c.so
+lib/liblog-4e7c5e5c.so
+lib/librbml-4e7c5e5c.so
+lib/librustc-4e7c5e5c.so
+lib/librustc_back-4e7c5e5c.so
+lib/librustc_borrowck-4e7c5e5c.so
+lib/librustc_driver-4e7c5e5c.so
+lib/librustc_lint-4e7c5e5c.so
lib/librustc_llvm-4e7c5e5c.so
+lib/librustc_privacy-4e7c5e5c.so
+lib/librustc_resolve-4e7c5e5c.so
+lib/librustc_trans-4e7c5e5c.so
+lib/librustc_typeck-4e7c5e5c.so
lib/librustdoc-4e7c5e5c.so
-lib/libnative-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libstd-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libfourcc-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/liblog-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libcollections-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/librbml-4e7c5e5c.rlib
+lib/libserialize-4e7c5e5c.so
+lib/libstd-4e7c5e5c.so
+lib/libsyntax-4e7c5e5c.so
+lib/libterm-4e7c5e5c.so
+lib/libtest-4e7c5e5c.so
+lib/rustlib/components
+lib/rustlib/etc/gdb_load_rust_pretty_printers.py
+lib/rustlib/etc/gdb_rust_pretty_printing.py
+lib/rustlib/manifest-rustc
+lib/rustlib/rust-installer-version
+lib/rustlib/uninstall.sh
lib/rustlib/x86_64-unknown-freebsd/lib/liballoc-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libuuid-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libtime-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libarena-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libarena-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libcollections-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libcompiler-rt.a
+lib/rustlib/x86_64-unknown-freebsd/lib/libcore-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libflate-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libflate-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libfmt_macros-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libgetopts-4e7c5e5c.rlib
lib/rustlib/x86_64-unknown-freebsd/lib/libgetopts-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/librustc_llvm-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/librustdoc-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libgraphviz-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libgraphviz-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/liblibc-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/liblog-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/liblog-4e7c5e5c.so
lib/rustlib/x86_64-unknown-freebsd/lib/libmorestack.a
-lib/rustlib/x86_64-unknown-freebsd/lib/libnative-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libcore-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libhexfloat-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librand-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/librbml-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/librbml-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc-4e7c5e5c.so
lib/rustlib/x86_64-unknown-freebsd/lib/librustc_back-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/librustrt-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libunicode-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libgetopts-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libflate-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libsync-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/librlibc-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libflate-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_bitflags-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_borrowck-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_driver-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_lint-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_llvm-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_privacy-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_resolve-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_trans-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustc_typeck-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/librustdoc-4e7c5e5c.so
lib/rustlib/x86_64-unknown-freebsd/lib/libserialize-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libregex-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/liburl-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libregex_macros-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libgreen-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libgraphviz-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libserialize-4e7c5e5c.so
+lib/rustlib/x86_64-unknown-freebsd/lib/libstd-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libstd-4e7c5e5c.so
lib/rustlib/x86_64-unknown-freebsd/lib/libsyntax-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libdebug-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libnum-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libnative-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/librand-4e7c5e5c.rlib
lib/rustlib/x86_64-unknown-freebsd/lib/libterm-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libtest-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libarena-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libcompiler-rt.a
-lib/rustlib/x86_64-unknown-freebsd/lib/libarena-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libtime-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/liblog-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libregex-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/librbml-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libglob-4e7c5e5c.so
lib/rustlib/x86_64-unknown-freebsd/lib/libterm-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libserialize-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libdebug-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libnum-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libsemver-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libglob-4e7c5e5c.rlib
+lib/rustlib/x86_64-unknown-freebsd/lib/libtest-4e7c5e5c.rlib
lib/rustlib/x86_64-unknown-freebsd/lib/libtest-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libgreen-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/librustrt-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libsemver-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libfmt_macros-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libgraphviz-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libuuid-4e7c5e5c.rlib
-lib/rustlib/x86_64-unknown-freebsd/lib/libsync-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/libstd-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/liburl-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/librustc-4e7c5e5c.so
-lib/rustlib/x86_64-unknown-freebsd/lib/liblibc-4e7c5e5c.rlib
-lib/librustc_back-4e7c5e5c.so
-lib/libflate-4e7c5e5c.so
-lib/libregex-4e7c5e5c.so
-lib/libgraphviz-4e7c5e5c.so
-lib/libsyntax-4e7c5e5c.so
-lib/libarena-4e7c5e5c.so
-lib/libtime-4e7c5e5c.so
-lib/liblog-4e7c5e5c.so
-lib/librbml-4e7c5e5c.so
-lib/libterm-4e7c5e5c.so
-lib/libserialize-4e7c5e5c.so
-lib/libdebug-4e7c5e5c.so
-lib/libtest-4e7c5e5c.so
-lib/librustrt-4e7c5e5c.so
-lib/libfmt_macros-4e7c5e5c.so
-lib/libsync-4e7c5e5c.so
-lib/libstd-4e7c5e5c.so
-lib/librustc-4e7c5e5c.so
-man/man1/rustdoc.1.gz
+lib/rustlib/x86_64-unknown-freebsd/lib/libunicode-4e7c5e5c.rlib
man/man1/rustc.1.gz
-@dir lib/rustlib/x86_64-unknown-freebsd/lib
-@dir lib/rustlib/x86_64-unknown-freebsd
-@dir lib/rustlib
+man/man1/rustdoc.1.gz
+%%PORTDOCS%%%%DOCSDIR%%/COPYRIGHT
+%%PORTDOCS%%%%DOCSDIR%%/LICENSE-APACHE
+%%PORTDOCS%%%%DOCSDIR%%/LICENSE-MIT
+%%PORTDOCS%%%%DOCSDIR%%/README.md

File Metadata

Mime Type
text/plain
Expires
Mon, Mar 9, 7:23 PM (13 h, 40 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29454237
Default Alt Text
D2466.id5263.diff (13 KB)

Event Timeline