FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > ArchLinux > ArchLinux User Repository

 
 
LinkBack Thread Tools
 
Old 03-20-2012, 04:44 PM
Maximilian Bräutigam
 
Default PKGBUILD with depending _pkgver

Hi all,

recently, I wrote an ebuild where pkgver=2.4.2 but in the download link
a 242 is needed. Thus, I decided to avoid any redundancy and to write
_pkgver="${pkgver//./}". The PKGBUILD is working fine but
aur.archlinux.org is expanding the download link to "2.4.2//./}".


Is there a way to avoid both the redundancy and the wrong interpretation
at aur.archlinux.org?


This is the package we are talking about:
https://aur.archlinux.org/packages.php?ID=34230

Kind regards,
Max
 
Old 03-20-2012, 06:08 PM
小龙 陈
 
Default PKGBUILD with depending _pkgver

As far as I know, you'll have to write the package version twice.
The AUR reads the PKGBUILD's directly, not with bash (security
concerns). Right now, the AUR only supports variables with the
name only (i.e. $blah or ${blah}).

Regards,
Xiao-Long Chen

> Date: Tue, 20 Mar 2012 18:44:43 +0100
> From: m@xbra.de
> To: aur-general@archlinux.org
> Subject: [aur-general] PKGBUILD with depending _pkgver
>
> Hi all,
>
> recently, I wrote an ebuild where pkgver=2.4.2 but in the download link
> a 242 is needed. Thus, I decided to avoid any redundancy and to write
> _pkgver="${pkgver//./}". The PKGBUILD is working fine but
> aur.archlinux.org is expanding the download link to "2.4.2//./}".
>
> Is there a way to avoid both the redundancy and the wrong interpretation
> at aur.archlinux.org?
>
> This is the package we are talking about:
> https://aur.archlinux.org/packages.php?ID=34230
>
> Kind regards,
> Max
 
Old 03-20-2012, 08:52 PM
Martti Kühne
 
Default PKGBUILD with depending _pkgver

On Tue, Mar 20, 2012 at 06:44:43PM +0100, Maximilian Bräutigam wrote:
> Is there a way to avoid both the redundancy and the wrong
> interpretation at aur.archlinux.org?
>
> This is the package we are talking about:
> https://aur.archlinux.org/packages.php?ID=34230

suggestion: use the parameter expansion in the source url only?

source=("http://my.domain.org/my/package-${pkgver//./}.tar.gz")
...or would this be too obvious?
saves you ... a line of code.

cheers!
mar77i
 
Old 03-20-2012, 09:34 PM
rafael ff1
 
Default PKGBUILD with depending _pkgver

2012/3/20 Martti Kühne <mysatyre@gmail.com>:
> On Tue, Mar 20, 2012 at 06:44:43PM +0100, Maximilian Bräutigam wrote:
>> Is there a way to avoid both the redundancy and the wrong
>> interpretation at aur.archlinux.org?
>>
>> This is the package we are talking about:
>> https://aur.archlinux.org/packages.php?ID=34230
>
> suggestion: use the parameter expansion in the source url only?
>
> source=("http://my.domain.org/my/package-${pkgver//./}.tar.gz")
> ...or would this be too obvious?
> saves you ... a line of code.
>
> cheers!
> mar77i

This will display a weird source URL line in AUR interface, and that's
what the author of the thread want's to avoid. Therefore, not that
obvious.

Rafael
 
Old 03-21-2012, 08:22 AM
Martti Kühne
 
Default PKGBUILD with depending _pkgver

On Tue, Mar 20, 2012 at 07:34:52PM -0300, rafael ff1 wrote:
> This will display a weird source URL line in AUR interface, and that's
> what the author of the thread want's to avoid. Therefore, not that
> obvious.


in the end, it's the aur's problem, not the packager's.

cheers!
mar77i
 
Old 03-21-2012, 01:18 PM
rafael ff1
 
Default PKGBUILD with depending _pkgver

2012/3/21 Martti Kühne <mysatyre@gmail.com>:
> On Tue, Mar 20, 2012 at 07:34:52PM -0300, rafael ff1 wrote:
>> This will display a weird source URL line in AUR interface, and that's
>> what the author of the thread want's to avoid. Therefore, not that
>> obvious.
>
>
> in the end, it's the aur's problem, not the packager's.
>
> cheers!
> mar77i

Sort of. If the maintainer knows this issue, he/she can avoid it. So,
IMO, the problem is the maintainer's, in the end.

Of course this is not a big issue, but if i can choose to solve this
issue with one more line in the PKGBUILD, I prefer to do it than mess
the displayed source url.

Rafael
 

Thread Tools




All times are GMT. The time now is 03:35 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org