slkbuild does not allow dashes or underscores allowed in

You think you have found a bug? Let us know about it.
User avatar
zAchAry
Posts: 804
Joined: 11. May 2010, 09:02
Location: Israel

slkbuild does not allow dashes or underscores allowed in

Post by zAchAry »

MOC 2.5.0-beta1 Released http://moc.daper.net/node/848

It has this character "-".

I can do this:
pkgname=moc
pkgver=2.5.0
pkgver2=beta1

ftp://ftp.daper.net/pub/soft/moc/unstab ... r2.tar.bz2

Which is, frankly, not good.
Image
Help to make Slackware easier Donate to Salix
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: slkbuild does not allow dashes or underscores allowed in

Post by mimosa »

Just do:

Code: Select all

pkgver=2.x.x.betax
Why would you want to package a beta of it, anyway?
User avatar
zAchAry
Posts: 804
Joined: 11. May 2010, 09:02
Location: Israel

Re: slkbuild does not allow dashes or underscores allowed in

Post by zAchAry »

Just do:

Code: Select all

pkgver=2.x.x.betax
It does not work.

The following SLKBUILD is not working also

Code: Select all

pkgname=moc
pkgver=2.5.0
pkgsta=beta1
pkgrel=ar
source=(ftp://ftp.daper.net/pub/soft/moc/unstable/$pkgname-$pkgver-$pkgsta.tar.bz2)
docs=("AUTHORS COPYING ChangeLog INSTALL LICENSE NEWS README README_equalizer REVISION THANKS TODO")
url=http://moc.daper.net

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"moc (A console audio player)"
"You just need to select a file from some directory using the menu"
"similar to Midnight Commander, and MOC will start playing all files in"
"this directory beginning from the chosen file. There is no need to"
"create play lists like in other players."
)


build() {
	cd $startdir/src/$pkgname-$pkgver-$pkgsta
        ./configure \
          --prefix=/usr \
          --libdir=/usr/lib${LIBDIRSUFFIX} \
          --localstatedir=/var \
          --mandir=/usr/man \
          --sysconfdir=/etc \
          --build=$arch-slackware-linux
	make || return 1
	make DESTDIR=$startdir/pkg install
} 

Code: Select all

Length: 570468 (557K) (unauthoritative)

100%[======================================>] 570,468     33.4K/s   in 21s     

2012-10-20 09:26:18 (26.2 KB/s) - “moc-2.5.0-beta1.tar.bz2” saved [570468]

build-moc.sh has been created
tar -xf moc-2.5.0-beta1.tar.bz2
./build-moc.sh: line 171: cd: /home/build/salix/moc-2.5.0-: No such file or directory
./build-moc.sh: line 173: ./configure: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
build() failed.
Why would you want to package a beta of it, anyway?
Examine bug fixes and new features.
Image
Help to make Slackware easier Donate to Salix
User avatar
fredg
Posts: 232
Joined: 3. Oct 2009, 16:50
Location: Lyon, France
Contact:

Re: slkbuild does not allow dashes or underscores allowed in

Post by fredg »

Your $pkgsta variable is not defined in slkbuild.

As mimosa said,

Code: Select all

pkgver=2.x.x.betax
Then, in the 1st line:
Write it without variable (what you get when you decompress it):

Code: Select all

cd $SRC/$pkgname-2.x.x-betax
++
User avatar
gapan
Salix Wizard
Posts: 6241
Joined: 6. Jun 2009, 17:40

Re: slkbuild does not allow dashes or underscores allowed in

Post by gapan »

To answer the thread title: Of course it doesn't allow dashes in version numbers. That would have been a bug.
Image
Image
User avatar
zAchAry
Posts: 804
Joined: 11. May 2010, 09:02
Location: Israel

Re: slkbuild does not allow dashes or underscores allowed in

Post by zAchAry »

Thank you mimosa and fredg.
gapan wrote:To answer the thread title: Of course it doesn't allow dashes in version numbers. That would have been a bug.
I would say, it is a problem since in this situation you need to force the locations like doc/ and src/ directories:

Code: Select all

./
usr/
usr/lib/
usr/lib/moc/
usr/lib/moc/decoder_plugins/
usr/lib/moc/decoder_plugins/libflac_decoder.la
usr/lib/moc/decoder_plugins/libwavpack_decoder.la
usr/lib/moc/decoder_plugins/libspeex_decoder.la
usr/lib/moc/decoder_plugins/libmusepack_decoder.so
usr/lib/moc/decoder_plugins/libvorbis_decoder.la
usr/lib/moc/decoder_plugins/libspeex_decoder.so
usr/lib/moc/decoder_plugins/libsndfile_decoder.la
usr/lib/moc/decoder_plugins/libflac_decoder.so
usr/lib/moc/decoder_plugins/libsndfile_decoder.so
usr/lib/moc/decoder_plugins/libffmpeg_decoder.so
usr/lib/moc/decoder_plugins/libmp3_decoder.la
usr/lib/moc/decoder_plugins/libvorbis_decoder.so
usr/lib/moc/decoder_plugins/libaac_decoder.la
usr/lib/moc/decoder_plugins/libffmpeg_decoder.la
usr/lib/moc/decoder_plugins/libaac_decoder.so
usr/lib/moc/decoder_plugins/libmusepack_decoder.la
usr/lib/moc/decoder_plugins/libwavpack_decoder.so
usr/lib/moc/decoder_plugins/libmp3_decoder.so
usr/src/
usr/src/moc-2.5.0/
usr/src/moc-2.5.0/SLKBUILD
usr/man/
usr/man/man1/
usr/man/man1/mocp.1.gz
usr/doc/
usr/doc/moc-2.5.0/
usr/doc/moc-2.5.0/TODO
usr/doc/moc-2.5.0/THANKS
usr/doc/moc-2.5.0/README
usr/doc/moc-2.5.0/keymap.example
usr/doc/moc-2.5.0/NEWS
usr/doc/moc-2.5.0/REVISION
usr/doc/moc-2.5.0/INSTALL
usr/doc/moc-2.5.0/ChangeLog
usr/doc/moc-2.5.0/config.example
usr/doc/moc-2.5.0/README_equalizer
usr/doc/moc-2.5.0/AUTHORS
usr/doc/moc-2.5.0/COPYING
usr/share/
usr/share/moc/
usr/share/moc/themes/
usr/share/moc/themes/nightly_theme
usr/share/moc/themes/moca_theme
usr/share/moc/themes/transparent-background
usr/share/moc/themes/example_theme
usr/share/moc/themes/green_theme
usr/share/moc/themes/black_theme
usr/share/moc/themes/darkdot_theme
usr/share/moc/themes/red_theme
usr/share/moc/themes/yellow_red_theme
usr/bin/
usr/bin/mocp
install/
install/slack-desc
This is very messy.

What do I need to edit in order to put the SLKBUILD in /usr/src/moc-2.5.0-beta1/ instead of /usr/src/moc-2.5.0/?

Code: Select all

pkgname=moc
pkgver=2.5.0
pkgrel=ar
source=(ftp://ftp.daper.net/pub/soft/moc/unstable/$pkgname-$pkgver-beta1.tar.bz2)
docs=("AUTHORS COPYING ChangeLog INSTALL LICENSE NEWS README README_equalizer REVISION THANKS TODO")
url=http://moc.daper.net

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"moc (A console audio player)"
"You just need to select a file from some directory using the menu"
"similar to Midnight Commander, and MOC will start playing all files in"
"this directory beginning from the chosen file. There is no need to"
"create play lists like in other players."
)


build() {
	cd $startdir/src/$pkgname-$pkgver-beta1
        ./configure \
          --prefix=/usr \
          --libdir=/usr/lib${LIBDIRSUFFIX} \
          --localstatedir=/var \
          --mandir=/usr/man \
          --docdir=/usr/doc/$pkgname-$pkgver-beta1 \
          --sysconfdir=/etc \
          --build=$arch-slackware-linux
	make || return 1
	make DESTDIR=$startdir/pkg install
} 
Last edited by zAchAry on 20. Oct 2012, 09:25, edited 1 time in total.
Image
Help to make Slackware easier Donate to Salix
User avatar
gapan
Salix Wizard
Posts: 6241
Joined: 6. Jun 2009, 17:40

Re: slkbuild does not allow dashes or underscores allowed in

Post by gapan »

You're obviously not familiar with packaging rules which explicitly forbid the use of dashes in package versions.
Image
Image
User avatar
zAchAry
Posts: 804
Joined: 11. May 2010, 09:02
Location: Israel

Re: slkbuild does not allow dashes or underscores allowed in

Post by zAchAry »

Would you be kind to explain, instead?
Image
Help to make Slackware easier Donate to Salix
User avatar
gapan
Salix Wizard
Posts: 6241
Joined: 6. Jun 2009, 17:40

Re: slkbuild does not allow dashes or underscores allowed in

Post by gapan »

Explanation: Read the packaging rules.
Image
Image
User avatar
zAchAry
Posts: 804
Joined: 11. May 2010, 09:02
Location: Israel

Re: slkbuild does not allow dashes or underscores allowed in

Post by zAchAry »

Why did you decide to participate in this thread, then?
Image
Help to make Slackware easier Donate to Salix
Post Reply