Sander van Dijk
a.h.vandijk at gmail.com
Sat Feb 17 12:50:51 UTC 2007
On 2/17/07, Joel Brooks <jbrooks at oddelement.com> wrote:
> i'm trying to make a port for a package (liblockfile from debian).
> the package name at the download source contains an underscore (_) character.
> the source line in the Pkgfile is:
> when i do a pkgmk in my port directory, i get the following:
> =======> ERROR: Source file
> '/usr/ports/oddelement/liblockfile/1.06.1.tar.gz' not found (use
> option -d to download).
> note the file name part of the error message only contains the
> $version. the $name is gone.
> I think it has something to do with this line in pkgmk:
> local FILE="`echo $1 | sed 's|^.*://.*/||g'`"
> (line 36)
> when i simulate this on the command line, i get this:
> # echo http://ftp.debian.org/debian/pool/main/libl/liblockfile/1.06.1.tar.gz
> |sed 's|^.*://.*/||g'
> it seems that what is happening is that the sed line is stripping the
> $name part of the source line at the underscore.
No, this has nothing to do with pkgmk; try this on a shell for example:
The reason for the difference is that '-' is not a valid character for
a variable name, while '_' is. This following example might make
things more obvious:
More information about the CRUX