Bug 237351

Summary: ports-mgmt/pkg: pkg install -f <make package file> crashes
Product: Ports & Packages Reporter: heas
Component: Individual Port(s)Assignee: Baptiste Daroussin <bapt>
Status: Closed FIXED    
Severity: Affects Some People CC: pkg, w.schwarzenfeld
Priority: --- Keywords: crash
Version: LatestFlags: koobs: maintainer-feedback+
koobs: merge-quarterly?
Hardware: Any   
OS: Any   

Description heas 2019-04-17 20:21:21 UTC
pkg 1.10.5
fbsd 11.2-RELEASE-p9
current ports tree as of today (via portsnap)

make package in devel/readline or lang/python36 followed by pkg install -f <file.txz> produces a coredump.

# pkg install -f python36-3.6.8_2.txz
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Updating database digests format: 100%
Child process pid=95662 terminated abnormally: Segmentation fault
# file pkg.core.95662
pkg.core.95662: ELF 64-bit LSB core file x86-64, version 1 (FreeBSD), FreeBSD-style, from 'tall -f python36-3.6.8_2.txz'

unxz the file and gzip it, produces different results depending upon the fielname.

# pkg install -f python36-3.6.8_2.tar.gz
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
pkg: No packages available to install matching 'python36-3.6.8_2.tar.gz' have been found in the repositories
# mv python36-3.6.8_2.tar.gz python36-3.6.8_2.tgz
# pkg install -f python36-3.6.8_2.tgz
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Child process pid=95678 terminated abnormally: Segmentation fault
# file pkg.core.95678
pkg.core.95678: ELF 64-bit LSB core file x86-64, version 1 (FreeBSD), FreeBSD-style, from 'tall -f python36-3.6.8_2.tgz'
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2019-04-19 04:14:28 UTC
Thank you for your report. You may want to report this to upstream at  https://github.com/freebsd/pkg/issues including a backtrace of the crash
Comment 2 Baptiste Daroussin freebsd_committer 2019-04-19 13:36:32 UTC
Thank you for reporting,

Fixed in git!
Comment 3 heas 2019-04-19 16:49:58 UTC
Works, afaict.  Except that a package name of <whatever>.tar.{gz,xz} is not recognized.
 
pkg: No packages available to install matching '/usr/ports/lang/python36/python36-3.6.8_2.tar.gz' have been found in the repositories
Comment 4 Kubilay Kocak freebsd_committer freebsd_triage 2019-04-20 06:29:06 UTC
Fixed in ports r499379