Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F167319805
D7050.id18074.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
D7050.id18074.diff
View Options
Index: lang/rust/Makefile
===================================================================
--- lang/rust/Makefile
+++ lang/rust/Makefile
@@ -3,6 +3,7 @@
PORTNAME= rust
PORTVERSION?= 1.9.0
+PORTREVISION= 1
CATEGORIES= lang
MASTER_SITES= http://static.rust-lang.org/dist/:src \
http://static.rust-lang.org/stage0-snapshots/:bootstrap \
@@ -60,19 +61,23 @@
USES= compiler gmake libedit python:2,build
HAS_CONFIGURE= yes
-CONFIGURE_ARGS= --disable-valgrind --disable-docs \
+CONFIGURE_ARGS= --disable-valgrind \
${CHOSEN_COMPILER_TYPE:Mclang:C/.+/--enable-&/} \
--mandir=${MANPREFIX}/man \
--release-channel=${RUST_CHANNEL}
+PORTDOCS= *
+
.if defined(BATCH) || defined(PACKAGE_BUILDING)
MAKE_ARGS+= VERBOSE=1
.endif
-OPTIONS_DEFINE= GDB LLNEXTGEN PORT_LLVM
+OPTIONS_DEFINE= DOCS GDB LLNEXTGEN PORT_LLVM
+OPTIONS_SUB= yes
GDB_DESC= Install ports gdb (necessary for debugging rust programs)
LLNEXTGEN_DESC= Build with grammar verification
+DOCS_CONFIGURE_ENABLE= docs
GDB_RUN_DEPENDS= ${LOCALBASE}/bin/gdb:devel/gdb
LLNEXTGEN_BUILD_DEPENDS= LLnextgen:devel/llnextgen
@@ -141,6 +146,16 @@
${STAGEDIR}${PREFIX}/lib/rustlib/rust-installer-version \
${STAGEDIR}${PREFIX}/lib/rustlib/uninstall.sh
+pre-install-DOCS-on:
+ @for f in manifest-rust-docs; do \
+ if test -f ${STAGEDIR}${PREFIX}/lib/rustlib/$$f; then \
+ ${SED} -E -e 's,^(dir|file:),${STAGEDIR},' \
+ < ${STAGEDIR}${PREFIX}/lib/rustlib/$$f \
+ | ${XARGS} ${RM}; \
+ fi; \
+ done
+ @${RM} ${STAGEDIR}${PREFIX}/lib/rustlib/manifest-rust-docs
+
post-install:
@for f in manifest-rustc manifest-rust-std-${RUST_TARGET}; do \
${REINPLACE_CMD} -e 's|${STAGEDIR}||' \
@@ -156,4 +171,12 @@
${STAGEDIR}${PREFIX}/lib/*.so \
${STAGEDIR}${PREFIX}/lib/rustlib/*/lib/*.so
+post-install-DOCS-on:
+ @for f in manifest-rust-docs; do \
+ ${REINPLACE_CMD} -e 's|${STAGEDIR}||' \
+ ${STAGEDIR}${PREFIX}/lib/rustlib/$$f; \
+ ${RM} ${STAGEDIR}${PREFIX}/lib/rustlib/$$f.bak; \
+ done
+ @${RMDIR} ${STAGEDIR}${PREFIX}/share/doc/rust/html/extra
+
.include <bsd.port.mk>
Index: lang/rust/pkg-plist
===================================================================
--- lang/rust/pkg-plist
+++ lang/rust/pkg-plist
@@ -39,6 +39,7 @@
lib/rustlib/etc/debugger_pretty_printers_common.py
lib/rustlib/etc/gdb_load_rust_pretty_printers.py
lib/rustlib/etc/gdb_rust_pretty_printing.py
+%%PORTDOCS%%lib/rustlib/manifest-rust-docs
lib/rustlib/manifest-rust-std-%%RUST_TARGET%%
lib/rustlib/manifest-rustc
lib/rustlib/rust-installer-version
@@ -93,7 +94,3 @@
lib/rustlib/%%RUST_TARGET%%/lib/libtest-%%RUST_VSN_HASH%%.so
man/man1/rustc.1.gz
man/man1/rustdoc.1.gz
-%%PORTDOCS%%%%DOCSDIR%%/COPYRIGHT
-%%PORTDOCS%%%%DOCSDIR%%/LICENSE-APACHE
-%%PORTDOCS%%%%DOCSDIR%%/LICENSE-MIT
-%%PORTDOCS%%%%DOCSDIR%%/README.md
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Aug 21, 9:14 PM (19 h, 46 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37056519
Default Alt Text
D7050.id18074.diff (2 KB)
Attached To
Mode
D7050: Add DOCS OPTION to lang/rust
Attached
Detach File
Event Timeline
Log In to Comment