Bug 222819 - make fetch-urlall-list failed for ports with DIST_SUBDIR
Summary: make fetch-urlall-list failed for ports with DIST_SUBDIR
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Ports Framework (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Port Management Team
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-06 10:52 UTC by Po-Chuan Hsieh
Modified: 2018-08-01 19:36 UTC (History)
2 users (show)

See Also:


Attachments
p (526 bytes, patch)
2017-10-06 13:50 UTC, Mathieu Arnold
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Po-Chuan Hsieh freebsd_committer freebsd_triage 2017-10-06 10:52:32 UTC
% cd /usr/ports/www/gallery2
% cat distinfo
SHA256 (gallery2/gallery-2.3.2-full.tar.gz) = 810ed73c456a3299ba50d9fcca6725d0654641c078c9d7c278d4875bad2af3fc
SIZE (gallery2/gallery-2.3.2-full.tar.gz) = 14569436
% make fetch-urlall-list
mkdir: /usr/ports/distfiles/gallery2: Permission denied
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/www/gallery2
*** Error code 1

Stop.
make: stopped in /usr/ports/www/gallery2
Comment 1 Mathieu Arnold freebsd_committer freebsd_triage 2017-10-06 13:50:05 UTC
Created attachment 186953 [details]
p

let me know if this fixes the problem.
Comment 2 Po-Chuan Hsieh freebsd_committer freebsd_triage 2017-10-06 14:48:22 UTC
Thanks! It fixes the problem.
Comment 3 Po-Chuan Hsieh freebsd_committer freebsd_triage 2017-12-16 06:11:59 UTC
@mat: will you commit this fix?
Comment 4 Mathieu Arnold freebsd_committer freebsd_triage 2017-12-16 08:53:17 UTC
Sorry, forgot about it.
Comment 5 commit-hook freebsd_committer freebsd_triage 2017-12-16 08:53:40 UTC
A commit references this bug:

Author: mat
Date: Sat Dec 16 08:53:08 UTC 2017
New revision: 456460
URL: https://svnweb.freebsd.org/changeset/ports/456460

Log:
  Fix a edge case in the fetch related targets.

  This would have given an error when:

  - The port uses DIST_SUBDIR
  - That sub-directory does not exist
  - The current user does not have permission to write in DISTDIR.

  Something like:

  $ sudo rmdir /usr/ports/distfiles/gallery2
  $ make fetch-urlall-list
  mkdir: /usr/ports/distfiles/gallery2: Permission denied
  *** Error code 1

  PR:		222819
  Reported by:	sunpoet
  Sponsored by:	Absolight

Changes:
  head/Mk/Scripts/do-fetch.sh
Comment 6 Po-Chuan Hsieh freebsd_committer freebsd_triage 2017-12-16 13:29:23 UTC
Thank you!