You are not logged in.
Hi!
I'm trying to compile motor and get very strange errors.
PKGBUILD:
# Contributor: Roman Kyrylych <Roman>
pkgname=motor
pkgver=3.4.0
pkgrel=1
pkgdesc="A text mode based programming environment for Linux"
url="http://thekonst.net/en/motor"
license="GPL"
depends=('gcc' 'ncurses')
makedepends=()
conflicts=()
replaces=()
backup=()
install=
source=(http://thekonst.net/download/$pkgname-$pkgver.tar.bz2)
md5sums=('0fcf7ce0386b269e8bdbb7a86e9bee19')
build() {
cd $startdir/src/$pkgname-$pkgver
./configure --prefix=/usr
make || return 1
sed -i -e "s@-C $(datadir)@-C $startdir/pkg$(datadir)@g" $startdir/src/$pkgname-$pkgver/share/Makefile.*
make DESTDIR=$startdir/pkg install
}
makepkg -c:
. . .
make[1]: Leaving directory `/var/abs/local/motor/src/motor-3.4.0'
==> Removing info/doc files...
==> Compressing man pages...
==> Stripping debugging symbols from libraries...
==> Stripping symbols from binaries...
==> Generating .PKGINFO file...
==> Generating .FILELIST file...
==> Compressing package...
==> Cleaning up...
==> Finished making: motor (Tue Aug 29 17:29:56 EEST 2006)
Then I run gensync to update my repo, then pacman -Sy motor:
:: Synchronizing package databases...
:: current is up to date
:: extra is up to date
:: community is up to date
romashka [/mnt/storage1/packages/] 100% LOCAL
Targets: motor-3.4.0-1
Total Package Size: 0.4 MB
Proceed with upgrade? [Y/n]
checking package integrity...
error: archive motor-3.4.0-1.pkg.tar.gz is corrupted
pacman -A /mnt/storage1/packages/motor-3.4.0-1.pkg.tar.gz:
loading package data... done.
checking for file conflicts... done.
installing motor... done.
Question #1: why pacman -A works but pacman -Sy don't???
My repo update script works flawless with other packages.
namcap /mnt/storage1/packages/motor-3.4.0.pkg.tar.gz:
motor E: File (usr/share/motor/templates/library/) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/Parserules) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/Makefile.func) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/Debug) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/[value name].spec.tmpl) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/Settings) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/configure.in.tmpl) has rk/users permissions.
motor E: File (usr/share/motor/templates/library/static/Folders) has rk/users permissions.
motor E: File (usr/share/motor/templates/terminal program/) has rk/users permissions.
motor E: File (usr/share/motor/templates/terminal program/C/) has rk/users permissions.
motor E: File (usr/share/motor/templates/terminal program/C/Parserules) has rk/users permissions.
. . .
motor E: File (usr/share/motor/templates/terminal program/perl/[value name].pl.tmpl) has rk/users permissions.
motor E: File (usr/share/motor/templates/terminal program/perl/Folders) has rk/users permissions.
Question #2: why these files has permissions of ordinary user ('rk') when I was compiling from root??? I was logged as 'rk' by secure shell.
I could post the entire package but it is 0.4MB.
Can some gurus here explain why these strange things happen?
EDIT: corrected copy-paste mistake in PKGBUILD.
to live is to die
Offline
Anyone has any ideas?
to live is to die
Offline
You probably built it/installed it previously and it is stored in your cache (look at /var/cache/pacman/pkg/).
You can remove the old package by hand or remove all the packages with pacman -Scc.
In the future, to avoid this. Change the pkgrel variable when you build a package.
Offline
You probably built it/installed it previously and it is stored in your cache (look at /var/cache/pacman/pkg/).
Yes. Thanks for pointing this out, I'll remember this. But this is not the source of the problem in my case.
You can remove the old package by hand or remove all the packages with pacman -Scc.
In my case this does not help. Nothing in output changed at all. And anyway this cache issue is not related to question #2.
In the future, to avoid this. Change the pkgrel variable when you build a package.
This is not a good solution when you make few compile tries before releasing pkgrel 1 to AUR. But I'll try to avoid this - will delete the package from cache each time before the next compile try.
to live is to die
Offline
Yes. Thanks for pointing this out, I'll remember this. But this is not the source of the problem in my case.
I am pretty sure it was. pacman -A doesn't look at the packages repository information (.db.tar.gz) which contains the md5sum of the packages, whereas pacman -S does.
For the pkgrel. I agree, change it only if you have already made the previous pkgrel public
Offline
Romashka wrote:Yes. Thanks for pointing this out, I'll remember this. But this is not the source of the problem in my case.
I am pretty sure it was. pacman -A doesn't look at the packages repository information (.db.tar.gz) which contains the md5sum of the packages, whereas pacman -S does.
Yes, but I mean that the problem was not related to installing old package version from cache instead of new from local repo.
I solved the first problem by first deleting and then regenerating my local repo .db.tar.gz. Then 'pacman -Sy motor' does not complain about corrupted archive.
The summary - gensync does not update package info for packages which have the same pkgver&pkgrel. Now I'll remember this. 8)
But the second question is still valid.
EDIT: Note that namcap complains about user permissions only for /usr/share/motor/templates/* which is the only one directory that is written in wrong place by make, that's why I used sed to change Makefile.*.
The most interesting thing here is why these files have permissions of user rk (logged via secure shell) and not root (logged using 'su -' and then started makepkg)?
to live is to die
Offline
And yet another thing - makepkg with fakeroot installed does not work for me (at least when logged via secure shell):
[rk@server motor]$ makepkg -f
==> Entering fakeroot environment
==> Making package: motor 3.4.0-1 (Fri Sep 1 19:12:18 EEST 2006)
==> Checking Runtime Dependencies...
==> Checking Buildtime Dependencies...
==> Retrieving Sources...
mkdir: cannot create directory `src': Permission denied
/usr/bin/makepkg: line 454: cd: /var/abs/local/motor/src: No such file or directory
==> Using local copy of motor-3.4.0.tar.bz2
cp: cannot create regular file `./motor-3.4.0.tar.bz2': Permission denied
==> Validating source files with MD5sums
motor-3.4.0.tar.bz2 ... FAILED
==> ERROR: One or more files did not pass the validity check!
to live is to die
Offline
make sure your user has permission to write in the folder where you are running makepkg.
Offline
make sure your user has permission to write in the folder where you are running makepkg.
Thanks, Snowman. :oops: How could I do such stupid mistake? :oops:
Any ideas on question #2 from first post?
to live is to die
Offline
I still cannot understand why the situation from Q#2 happened, but anyway motor is already in AUR (how did I not noticed it?).
to live is to die
Offline