Bug 270858 - lang/nim: Fix invalid path to documentation in compiler source code
Summary: lang/nim: Fix invalid path to documentation in compiler source code
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Fernando Apesteguía
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-15 08:31 UTC by Bartek Jasicki
Modified: 2023-04-19 16:43 UTC (History)
2 users (show)

See Also:
ports: maintainer-feedback+


Attachments
invalid_doc_paths.patch (776 bytes, patch)
2023-04-15 08:31 UTC, Bartek Jasicki
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bartek Jasicki 2023-04-15 08:31:19 UTC
Created attachment 241505 [details]
invalid_doc_paths.patch

By default, the file compiler/commands.nim contains a hard-coded path "../doc" to two documentation files, which are loaded during compilation into a code. While during compilation of Nim itself it isn't a problem, trying to use later the compiler source code in any project can cause issues as the documentation is in different place. The patch updates the paths in the compiler/commands.nim file to the new location "/usr/local/share/doc/nim" after build the package.
Comment 1 Neal Nelson 2023-04-19 13:29:14 UTC
Comment on attachment 241505 [details]
invalid_doc_paths.patch

It doesn't seem to break anything, so let's go for it.
Comment 2 Fernando Apesteguía freebsd_committer freebsd_triage 2023-04-19 16:42:52 UTC
Committed with minor changes,

Thanks!
Comment 3 commit-hook freebsd_committer freebsd_triage 2023-04-19 16:43:09 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=931d277e9f7db6872299f8b948b7c403d194c9c1

commit 931d277e9f7db6872299f8b948b7c403d194c9c1
Author:     Neal Nelson <ports@nicandneal.net>
AuthorDate: 2023-04-19 15:41:26 +0000
Commit:     Fernando Apesteguía <fernape@FreeBSD.org>
CommitDate: 2023-04-19 16:37:51 +0000

    lang/nim: Fix invalid path to documentation in compiler source code

    Use /usr/local/share/doc/nim instead of ../doc.

    PR:             270858
    Reported by:    thindil@laeran.pl.eu.org

 lang/nim/Makefile | 2 ++
 1 file changed, 2 insertions(+)