Index | Thread | Search

From:
Edd Barrett <edd@theunixzoo.co.uk>
Subject:
Re: Add devel/rust-analyzer
To:
Sebastien Marie <semarie@kapouay.eu.org>
Cc:
Laurent Cheylus <foxy@free.fr>, ports@openbsd.org, tb@openbsd.org
Date:
Fri, 19 Jan 2024 16:16:00 +0000

Download raw body.

Thread
Hi,

> I am unsure to properly understand here. You need rust,-src and rustfmt
> to build the port now ?

You're right, that's bogus. Fixed.

> post-build:
> 	cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${LOCALBASE}/bin/asciidoctor \
> 		docs/user/manual.adoc

Fixed, and using -safe.

> Please install both manual.html and manual.adoc. AsciiDoc format is
> readable in a terminal.

Fixed.

Diff to previous. OK?

diff -urNa /tmp/rust-analyzer/Makefile ./Makefile
--- /tmp/rust-analyzer/Makefile	Fri Jan 19 11:16:07 2024
+++ ./Makefile	Fri Jan 19 15:48:07 2024
@@ -14,9 +14,9 @@
 
 RUN_DEPENDS =	lang/rust,-src \
 		lang/rust,-rustfmt
-BUILD_DEPENDS =	${RUN_DEPENDS} \
-		textproc/ruby-rouge \
+BUILD_DEPENDS =	textproc/ruby-rouge \
 		textproc/asciidoctor
+TEST_DEPENDS =	lang/rust,-rustfmt
 
 WANTLIB += ${MODCARGO_WANTLIB} m
 
@@ -34,12 +34,14 @@
 
 # generate manual.html
 post-build:
-	asciidoctor ${WRKSRC}/docs/user/manual.adoc
+	cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} \
+		${LOCALBASE}/bin/asciidoctor --safe docs/user/manual.adoc
 
 DOCDIR =	${PREFIX}/share/doc/rust-analyzer
 post-install:
 	${INSTALL_DATA_DIR} ${DOCDIR}
 	${INSTALL_DATA} ${WRKSRC}/docs/user/manual.html ${DOCDIR}
+	${INSTALL_DATA} ${WRKSRC}/docs/user/manual.adoc ${DOCDIR}
 
 .include "crates.inc"
 
diff -urNa /tmp/rust-analyzer/pkg/PLIST ./pkg/PLIST
--- /tmp/rust-analyzer/pkg/PLIST	Fri Jan 19 11:13:23 2024
+++ ./pkg/PLIST	Fri Jan 19 15:16:31 2024
@@ -1,3 +1,4 @@
 @bin bin/rust-analyzer
 share/doc/rust-analyzer/
+share/doc/rust-analyzer/manual.adoc
 share/doc/rust-analyzer/manual.html

-- 
Best Regards
Edd Barrett

https://www.theunixzoo.co.uk