[aur-general] Search-URL in PKGBUILD

Eli Schwartz eschwartz at archlinux.org
Wed Jun 3 13:38:44 UTC 2020

On 6/3/20 8:26 AM, Ralf Mardorf wrote:
> On Wed, 3 Jun 2020 08:11:32 -0400, Eli Schwartz via aur-general wrote:
>> On 6/3/20 8:06 AM, Ralf Mardorf wrote:
>>> https://aur.archlinux.org/packages/perl-cpanel-json-xs/#comment-749091
>> What is a "search-URL"?
> I don't know the correct term.
> source=('http://search.cpan.org/CPAN/authors/id/R/RU/RURBAN/Cpanel-JSON-XS-4.19.tar.gz')
>                 ^^^^^^
>                 ^^^^^^

So a "search-URL" is a perl concept. That's something I did not know,
because I'm not a perl person.

To translate this into concepts that don't depend on an understanding of

This package downloads source code from the search.cpan.org website.

> It seemingly should redirect, but I get a HTTP 403 forbidden. I always
> need to edit this and other packages with such URLs.
> source=("https://cpan.metacpan.org/authors/id/R/RU/RURBAN/Cpanel-JSON-XS-${pkgver}.tar.gz")

... and apparently at least you are getting 403 forbidden errors. Which
is interesting, because at least I'm getting 301 "moved permanently"
redirects, to the cpan.metacpan.org website.

My conclusion is:

a) speak to the operators of this website and find out why you're being
b) a PKGBUILD should use the second url, because "moved permanently"
   means people should not be using the old, legacy site; also, it saves
   a tiny bit of bandwidth and performs fewer network connections to use
   the authoritative site directly instead of first querying another
   site and being told "no really, you should be looking there instead"

As for the package, the AUR maintainer updated it to use the
cpan.metacpan.org website, and threw in an https for free.

(Note that both search.cpan.org and cpan.metacpan.org support both
http:// and https:// and, for me, are accessible over either one.)

Eli Schwartz
Bug Wrangler and Trusted User

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1601 bytes
Desc: OpenPGP digital signature
URL: <https://lists.archlinux.org/pipermail/aur-general/attachments/20200603/bba864c7/attachment.sig>

More information about the aur-general mailing list