Skip to content
This repository was archived by the owner on Oct 31, 2023. It is now read-only.

Commit ecdb575

Browse files
committed
Merge pull request #53 from jrstjohn/remove-pkgfile
Remove pkgfile and other cleanup/maintenance
2 parents bc854ae + e6ac27b commit ecdb575

37 files changed

Lines changed: 173 additions & 2390 deletions

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,4 @@ pkgtools.tar.gz
55
.*.swp
66
*.files.*
77
scripts/*.pyc
8-
modules/pkgfile.so
9-
modules/*.o
10-
modules/build
118
tags

Makefile

Lines changed: 2 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,18 @@
11
INSTALL = install
22
INSTALL_DATA = $(INSTALL) -Dm644
33
INSTALL_PROGRAM = $(INSTALL) -Dm755
4-
INSTALL_CRON = $(INSTALL) -Dm744
5-
64
prefix = /usr
75
exec_prefix = $(prefix)
86
confdir = /etc
97
bindir = $(exec_prefix)/bin
108
libdir = $(prefix)/lib
119
sharedir = $(prefix)/share/pkgtools
12-
cachedir = /var/cache/pkgtools/lists
1310
profiledir = $(confdir)/profile.d
14-
crondir = $(confdir)/cron.daily
1511
mandir = $(prefix)/share/man
1612

1713
.PHONY: all
1814

19-
all: pkgfile.so
15+
all: install
2016

2117
install:
2218
# Common functions needed by all scripts
@@ -29,18 +25,6 @@ install:
2925
$(INSTALL) -d $(DESTDIR)$(sharedir)/newpkg/presets/
3026
$(INSTALL) -m644 other/newpkg_presets/* $(DESTDIR)$(sharedir)/newpkg/presets/
3127

32-
# pkgfile
33-
$(INSTALL) -d $(DESTDIR)$(cachedir)
34-
$(INSTALL_PROGRAM) scripts/pkgfile.py $(DESTDIR)$(bindir)/pkgfile
35-
$(INSTALL_DATA) confs/pkgfile.conf $(DESTDIR)$(confdir)/pkgtools/pkgfile.conf
36-
$(INSTALL_CRON) other/pkgfile.cron $(DESTDIR)$(crondir)/pkgfile
37-
# install pkgfile.so module
38-
(cd modules; python3 ./setup.py install --root=$(DESTDIR))
39-
# Loads shell hooks
40-
$(INSTALL_PROGRAM) other/pkgfile-hook.sh $(DESTDIR)$(profiledir)/pkgfile-hook.sh
41-
$(INSTALL_DATA) other/pkgfile-hook.zsh $(DESTDIR)$(sharedir)/pkgfile-hook.zsh
42-
$(INSTALL_DATA) other/pkgfile-hook.bash $(DESTDIR)$(sharedir)/pkgfile-hook.bash
43-
4428
# spec2arch
4529
$(INSTALL_PROGRAM) scripts/spec2arch $(DESTDIR)$(bindir)/spec2arch
4630
$(INSTALL_DATA) confs/spec2arch.conf $(DESTDIR)$(confdir)/pkgtools/spec2arch.conf
@@ -64,15 +48,7 @@ install:
6448

6549
uninstall:
6650
rm -Rf $(DESTDIR)$(sharedir)
67-
rm $(DESTDIR)$(bindir)/{newpkg,pkgfile,spec2arch,pkgconflict,whoneeds,pkgclean,pip2arch}
68-
rm $(DESTDIR)$(crondir)/pkgfile
69-
rm $(DESTDIR)$(profiledir)/pkgfile-hook.*
51+
rm $(DESTDIR)$(bindir)/{newpkg,spec2arch,pkgconflict,whoneeds,pkgclean,pip2arch}
7052
rm -Rf $(DESTDIR)$(confdir)/pkgtools
7153
rm $(DESTDIR)$(mandir)/man8/spec2arch.8
7254
rm $(DESTDIR)$(mandir)/man5/spec2arch.conf.5
73-
74-
pkgfile.so:
75-
(cd modules; python3 ./setup.py build)
76-
77-
clean:
78-
(rm -rf modules/build)

PKGBUILD

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,22 @@
11
# Maintainer: Daenyth <Daenyth+Arch AT gmail DOT com>
22
# Contributor: Daenyth <Daenyth+Arch AT gmail DOT com>
33
pkgname=pkgtools
4-
pkgver=23
4+
pkgver=24
55
pkgrel=1
66
pkgdesc="A collection of scripts for Arch Linux packages"
7-
arch=('i686' 'x86_64')
8-
url="http://bbs.archlinux.org/viewtopic.php?pid=384196"
7+
arch=('any')
8+
url="https://bbs.archlinux.org/viewtopic.php?pid=384196"
99
license=('GPL')
10-
source=(v$pkgver::http://github.com/Daenyth/pkgtools/tarball/v$pkgver)
10+
depends=('bash>=4' 'pcre' 'libarchive' 'python' 'namcap' 'pkgfile')
11+
optdepends=('abs: Provides PKGBUILD prototypes for newpkg')
12+
provides=('newpkg')
1113
backup=('etc/pkgtools/newpkg.conf' 'etc/pkgtools/pkgfile.conf' 'etc/pkgtools/spec2arch.conf')
1214
install=pkgtools.install
13-
provides=(newpkg pkgfile)
14-
depends=('bash>=4' 'pcre' 'libarchive' 'python')
15-
optdepends=('cron: For pkgfile --update entry'
16-
'abs: Provides proto packaging files for newpkg')
17-
md5sums=('5361111e31741f8d7ff8ca45c7996b6b')
15+
source=("${pkgname}-v${pkgver}.tar.gz::https://github.com/Daenyth/pkgtools/tarball/v$pkgver")
16+
md5sums=('f139c3940e1038cac4e29e985089e8a8')
1817

19-
build() {
20-
cd "$srcdir/Daenyth-$pkgname"-*
18+
package() {
19+
cd "Daenyth-$pkgname"-*
2120

22-
make
23-
make DESTDIR="$pkgdir" install
21+
make DESTDIR="$pkgdir" install
2422
}
25-
26-
# vim:set ts=2 sw=2 et:

PKGBUILD-git

Lines changed: 20 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,30 @@
11
# Contributor: Daenyth <Daenyth+Arch AT gmail DOT com>
22
pkgname=pkgtools-git
3-
pkgver=20110902
3+
_pkgname=pkgtools
4+
pkgver=20140211.bc854ae
45
pkgrel=1
56
pkgdesc="A collection of scripts for Arch Linux packages"
6-
arch=('i686' 'x86_64')
7-
url="http://github.com/Daenyth/pkgtools"
7+
arch=('any')
8+
url="https://github.com/Daenyth/pkgtools"
89
license=('GPL')
9-
source=()
10-
depends=('bash>=4' 'libarchive' 'pcre' 'python')
11-
makedepends=(git)
12-
provides=(pkgtools)
13-
conflicts=(pkgtools)
10+
depends=('bash>=4' 'libarchive' 'pcre' 'python' 'namcap' 'pkgfile')
11+
makedepends=('git')
12+
optdepends=('abs: Provides PKGBUILD prototypes for newpkg')
13+
provides=('pkgtools' 'newpkg')
14+
conflicts=('pkgtools')
1415
backup=('etc/pkgtools/newpkg.conf' 'etc/pkgtools/pkgfile.conf' 'etc/pkgtools/spec2arch.conf')
15-
install=pkgtools.install
16-
optdepends=('cron: For pkgfile --update entry'
17-
'abs: Provides proto packaging files for newpkg')
1816
options=('!strip')
17+
install=pkgtools.install
18+
source=("git+https://github.com/Daenyth/${_pkgname}.git")
19+
sha1sums=('SKIP')
1920

20-
_gitroot="git://github.com/Daenyth/pkgtools.git"
21-
_gitname="pkgtools"
22-
23-
build() {
24-
cd ${srcdir}
25-
msg "Connecting to GIT server...."
26-
27-
if [ -d ${srcdir}/$_gitname ] ; then
28-
cd $srcdir/$_gitname && git pull origin
29-
msg "The local files are updated."
30-
else
31-
git clone $_gitroot
32-
fi
33-
34-
msg "GIT checkout done or server timeout"
35-
msg "Starting make..."
36-
37-
[[ -d $srcdir/$_gitname-build ]] && rm -r ${srcdir}/$_gitname-build
38-
cp -r ${srcdir}/$_gitname ${srcdir}/$_gitname-build
39-
cd ${srcdir}/$_gitname-build
21+
pkgver() {
22+
cd "${_pkgname%-git}"
23+
echo "$(date +%Y%m%d).$(git rev-parse --short master)"
24+
}
4025

41-
make
42-
make DESTDIR=${pkgdir} install
26+
package() {
27+
cd "${_pkgname%-git}"
28+
git submodule update --init
29+
make DESTDIR="${pkgdir}" install
4330
}
44-
# vim:set ts=2 sw=2 et:

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
This is a collection of scripts for Arch Linux packages.
2+
3+
This repository contains the following scripts:
4+
- newpkg
5+
- spec2arch
6+
- pkgconflict
7+
- whoneeds
8+
- pkgclean
9+
- maintpkg
10+
- pip2arch

confs/pkgfile.conf

Lines changed: 0 additions & 30 deletions
This file was deleted.

doc/makeman

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)