Bug 224042 - textproc/py-docutils: symlinks broken for non default flavored package
Summary: textproc/py-docutils: symlinks broken for non default flavored package
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: freebsd-python mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-02 20:46 UTC by Peter Wullinger
Modified: 2017-12-03 08:31 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (python)


Attachments
poudriere build log (89.14 KB, text/x-log)
2017-12-02 21:10 UTC, Peter Wullinger
no flags Details
Proposed patch (604 bytes, patch)
2017-12-02 21:28 UTC, Antoine Brodin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Wullinger 2017-12-02 20:46:29 UTC
After upgrading to the flavored ports tree, my locally build packages (both on the live system as well as via poudriere) give me incorrectly linked binaries:

lrwxr-x---  1 root  wheel    11 Dec  2 21:34 rst2html-2.7 -> rst2html.py
-rwxr-x---  1 root  wheel   602 Dec  2 21:34 rst2html.py-2.7
-rwxr-x---  1 root  wheel   722 Dec  2 21:34 rst2html4.py-2.7
-rwxr-x---  1 root  wheel  1147 Dec  2 21:34 rst2html5.py-2.7
lrwxr-x---  1 root  wheel    12 Dec  2 21:34 rst2latex-2.7 -> rst2latex.py
-rwxr-x---  1 root  wheel   799 Dec  2 21:34 rst2latex.py-2.7
lrwxr-x---  1 root  wheel    10 Dec  2 21:34 rst2man-2.7 -> rst2man.py
-rwxr-x---  1 root  wheel   608 Dec  2 21:34 rst2man.py-2.7
lrwxr-x---  1 root  wheel    21 Dec  2 21:34 rst2odt_prepstyles-2.7 -> rst2odt_prepstyles.py
-rwxr-x---  1 root  wheel  1706 Dec  2 21:34 rst2odt_prepstyles.py-2.7
lrwxr-x---  1 root  wheel    10 Dec  2 21:34 rst2odt-2.7 -> rst2odt.py
-rwxr-x---  1 root  wheel   772 Dec  2 21:34 rst2odt.py-2.7
lrwxr-x---  1 root  wheel    16 Dec  2 21:34 rst2pseudoxml-2.7 -> rst2pseudoxml.py
-rwxr-x---  1 root  wheel   609 Dec  2 21:34 rst2pseudoxml.py-2.7
lrwxr-x---  1 root  wheel     9 Dec  2 21:34 rst2s5-2.7 -> rst2s5.py
-rwxr-x---  1 root  wheel   645 Dec  2 21:34 rst2s5.py-2.7
lrwxr-x---  1 root  wheel    12 Dec  2 21:34 rst2xetex-2.7 -> rst2xetex.py
-rwxr-x---  1 root  wheel   879 Dec  2 21:34 rst2xetex.py-2.7
lrwxr-x---  1 root  wheel    10 Dec  2 21:34 rst2xml-2.7 -> rst2xml.py
-rwxr-x---  1 root  wheel   610 Dec  2 21:34 rst2xml.py-2.7
lrwxr-x---  1 root  wheel    14 Dec  2 21:34 rstpep2html-2.7 -> rstpep2html.py
-rwxr-x---  1 root  wheel   678 Dec  2 21:34 rstpep2html.py-2.7

It looks like automatic renaming with flavored ports breaks the existing symlink logic.

Bug #224030 seems to be related, so the root cause might be a more overarching infrastructure problem.
Comment 1 Antoine Brodin freebsd_committer 2017-12-02 21:00:54 UTC
This seems to be a bug either in  textproc/py-docutils or USES=concurrent,  they both create some symlinks so they may walk on each other.
Comment 2 Peter Wullinger 2017-12-02 21:10:55 UTC
Created attachment 188477 [details]
poudriere build log

poudriere build log from one of the problematic builds.

Looks to like USES=concurrent renames the symlink targets without changing the symlinks:

Move: bin/rst2xetex.py --> bin/rst2xetex.py-2.7
Move: bin/rst2man.py --> bin/rst2man.py-2.7
Move: bin/rst2odt.py --> bin/rst2odt.py-2.7
Move: bin/rstpep2html.py --> bin/rstpep2html.py-2.7
Move: bin/rst2s5.py --> bin/rst2s5.py-2.7
Move: bin/rst2latex.py --> bin/rst2latex.py-2.7
Move: bin/rst2pseudoxml.py --> bin/rst2pseudoxml.py-2.7
Move: bin/rst2odt_prepstyles.py --> bin/rst2odt_prepstyles.py-2.7
Move: bin/rst2html.py --> bin/rst2html.py-2.7
Move: bin/rst2html5.py --> bin/rst2html5.py-2.7
Move: bin/rst2html4.py --> bin/rst2html4.py-2.7
Move: bin/rst2xml.py --> bin/rst2xml.py-2.7
Move: bin/rst2html --> bin/rst2html-2.7
Move: bin/rst2latex --> bin/rst2latex-2.7
Move: bin/rst2man --> bin/rst2man-2.7
Move: bin/rst2odt --> bin/rst2odt-2.7
Move: bin/rst2odt_prepstyles --> bin/rst2odt_prepstyles-2.7
Move: bin/rst2pseudoxml --> bin/rst2pseudoxml-2.7
Move: bin/rst2s5 --> bin/rst2s5-2.7
Move: bin/rst2xetex --> bin/rst2xetex-2.7
Move: bin/rst2xml --> bin/rst2xml-2.7
Move: bin/rstpep2html --> bin/rstpep2html-2.7
Comment 3 Antoine Brodin freebsd_committer 2017-12-02 21:28:14 UTC
Created attachment 188478 [details]
Proposed patch

Please try attached patch.
Comment 4 Peter Wullinger 2017-12-03 08:24:52 UTC
(In reply to Antoine Brodin from comment #3)
> Please try attached patch.

lrwxr-xr-x  1 root   wheel     15 Dec  3 09:14 rst2html -> rst2html.py-2.7
lrwxr-xr-x  1 root   wheel     15 Dec  3 09:14 rst2html-2.7 -> rst2html.py-2.7
lrwxr-xr-x  1 root   wheel     15 Dec  3 09:14 rst2html.py -> rst2html.py-2.7
-rwxr-xr-x  1 root   wheel    602 Dec  3 09:14 rst2html.py-2.7

Yep, that looks as it should be (if I understand USES=concurrent properly).

"rst2html.py-2.7" looks weird, but I'm pretty hopeful that this is a non-issue.

Result of build with default Python 3.6:

lrwxr-xr-x  1 root   wheel    15 Dec  2 20:58 rst2html -> rst2html.py-3.6
lrwxr-xr-x  1 root   wheel    11 Dec  2 20:58 rst2html-3.6 -> rst2html.py
lrwxr-xr-x  1 root   wheel    15 Dec  2 20:58 rst2html.py -> rst2html.py-3.6
-rwxr-xr-x  1 root   wheel   602 Dec  2 20:58 rst2html.py-3.6

Seems also what should happen.

Thanks a lot.
Comment 5 commit-hook freebsd_committer 2017-12-03 08:30:31 UTC
A commit references this bug:

Author: antoine
Date: Sun Dec  3 08:29:35 UTC 2017
New revision: 455393
URL: https://svnweb.freebsd.org/changeset/ports/455393

Log:
  Fix the symlinks when using a non default version of python

  PR:		224042
  Reported and tested by:	 Peter Wullinger

Changes:
  head/textproc/py-docutils/Makefile