You are not logged in.

#1 2017-06-06 10:56:18

fft
Member
Registered: 2017-06-06
Posts: 4

[SOLVED] PKGBUILD review request: rpmlint-git

There is rpmlint package at AUR, but it is out of date for more than year. I will propose to delete it, after rpmlint-git will be added to AUR.
rpmlint is tool for checking *.rpm packages, like namcap.

Please review PKGBUILD.

PKGBUILD:

# Maintainer: fft <anonim288@gmail.com>

pkgname=rpmlint-git
pkgver=1.9.r50.g3251ad2
pkgrel=1
pkgdesc='A tool for checking common errors in rpm packages.'
arch=('any')
url="https://github.com/rpm-software-management/rpmlint"
license=('GPL2')
makedepends=('git')
checkdepends=('python-pytest' 'flake8')
depends=('python>=2.6' 'rpm-org>=4.4.2.2' 'cpio' 'desktop-file-utils' 'sed')
source=("${pkgname}::git+https://github.com/rpm-software-management/rpmlint.git#branch=master")
sha256sums=('SKIP')

pkgver() {
    cd ${pkgname}
    git describe --long --tags| sed 's/rpmlint-\([0-9\.]*\)-\(.*\)/\1.r\2/;s/-/./g'
}

check() {
    cd ${pkgname}
    make check
}

package() {
    cd ${pkgname}
    make COMPILE_PYC=1 DESTDIR="${pkgdir}" install
}

Last edited by fft (2017-06-20 08:21:51)

Offline

#2 2017-06-06 13:41:58

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,911

Re: [SOLVED] PKGBUILD review request: rpmlint-git

you probably want to list python2 without a version number as dependency.
The version requirement for rpm-org is also unneeded on archlinux .

being out of date is normally not  a valid reason for a delete request, though an oprhan request and you taking over and updatin git would be.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#3 2017-06-07 09:07:45

fft
Member
Registered: 2017-06-06
Posts: 4

Re: [SOLVED] PKGBUILD review request: rpmlint-git

This is requirements from INSTALL file of rpmlint.
AFAIK, python2 not required - any of python2 and python3 are suitable.

Sorry, but why version requirements unneeded?

Yes, I understand, that out of date is not a reason for deleting. I think, that it is orphaned, because it is out of date for a very long time.

Offline

#4 2017-06-08 11:00:49

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,911

Re: [SOLVED] PKGBUILD review request: rpmlint-git

Python 2 and 3 are not compatible, you have to choose which one to use.
On arch linux python is always python3 , and python 2 packages always have python2 in their name .
If a program supports both python2 and python3 , use python3 .
(python2 is now at 2.7.13 and it's development has stopped.)

Arch linux updates through a rolling release method, that means every AL user normally has latest available version installed .
Checking for specific versions is only done in some special cases.


The aur page for rpmlint shows shaman as maintainer . They haven 't updated the package for almost 2 years, but it isn't orphaned .


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#5 2017-06-09 01:47:54

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: [SOLVED] PKGBUILD review request: rpmlint-git

fft wrote:

This is requirements from INSTALL file of rpmlint.
AFAIK, python2 not required - any of python2 and python3 are suitable.

In that case, it probably uses /usr/bin/python, in which case you will need the default python, which is not the python2 package.


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

#6 2017-06-13 12:33:29

fft
Member
Registered: 2017-06-06
Posts: 4

Re: [SOLVED] PKGBUILD review request: rpmlint-git

I removed version matching in depends:


# Maintainer: fft <anonim288@gmail.com>

pkgname=rpmlint-git
pkgver=1.9.r43.ge9e447c
pkgrel=1
pkgdesc='A tool for checking common errors in rpm packages.'
arch=('any')
url="https://github.com/rpm-software-management/rpmlint"
license=('GPL2')
makedepends=('git')
checkdepends=('python-pytest' 'flake8')
depends=('python' 'rpm-org' 'cpio' 'desktop-file-utils' 'sed')
source=("${pkgname}::git+https://github.com/rpm-software-management/rpmlint.git#branch=master")
sha256sums=('SKIP')

pkgver() {
    cd ${pkgname}
    git describe --long --tags| sed 's/rpmlint-\([0-9\.]*\)-\(.*\)/\1.r\2/;s/-/./g'
}

check() {
    cd ${pkgname}
    make check
}

package() {
    cd ${pkgname}
    make COMPILE_PYC=1 DESTDIR="${pkgdir}" install
}

Is it look ok for now?

Offline

#7 2017-06-13 20:38:51

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: [SOLVED] PKGBUILD review request: rpmlint-git

#branch=master is unnecessary as that is the default behavior of `git clone` and I don't see why you went out of your way to specify the source repo as having a local directory name of "rpmlint-git" instead of the default "rpmlint", but these are both minor nits.

Why do you specify sed in the depends array? sed is in both base and base-devel, and is a core system utility that everyone automatically has.
And the INSTALL file specifically says you need sed in order to install it, but not to run it. So it should only be a makedepends, except that it is already in base-devel...


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

#8 2017-06-14 08:51:40

fft
Member
Registered: 2017-06-06
Posts: 4

Re: [SOLVED] PKGBUILD review request: rpmlint-git

1. Prefer to leave explicit branch specification. In this repo there is no difference, but AFAIK master is not always default branch after git clone (https://stackoverflow.com/a/3302018).
2. I specified local directory name for clone just for easier later usage ( in  'cd ${pkgname}')
3. Removed sed from dependency, thank you.


Current PKGBUILD:

# Maintainer: fft <anonim288@gmail.com>

pkgname=rpmlint-git
pkgver=1.9.r43.ge9e447c
pkgrel=1
pkgdesc='A tool for checking common errors in rpm packages.'
arch=('any')
url="https://github.com/rpm-software-management/rpmlint"
license=('GPL2')
makedepends=('git')
checkdepends=('python-pytest' 'flake8')
depends=('python' 'rpm-org' 'cpio' 'desktop-file-utils')
source=("${pkgname}::git+https://github.com/rpm-software-management/rpmlint.git#branch=master")
sha256sums=('SKIP')

pkgver() {
    cd ${pkgname}
    git describe --long --tags| sed 's/rpmlint-\([0-9\.]*\)-\(.*\)/\1.r\2/;s/-/./g'
}

check() {
    cd ${pkgname}
    make check
}

package() {
    cd ${pkgname}
    make COMPILE_PYC=1 DESTDIR="${pkgdir}" install
}

Offline

#9 2017-06-14 12:07:28

eschwartz
Fellow
Registered: 2014-08-08
Posts: 4,097

Re: [SOLVED] PKGBUILD review request: rpmlint-git

1) This doesn't make any sense. In the unlikely event that some git repo is using some other naming convention for the default branch, you probably want that instead. There is certainly no need to explicitly define the branch in a PKGBUILD that you know doesn't need it.

(I still have yet to come across a PKGBUILD that needed to specify the default branch, though I have seen a few that specify a non-default branch.)


Managing AUR repos The Right Way -- aurpublish (now a standalone tool)

Offline

Board footer

Powered by FluxBB