LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 03-16-2020, 08:33 PM   #1
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Rep: Reputation: 76
Version number mismatch in slackbuilds script.


Hi: I've downloaded sources and script for the application nted from slackbuilds dot org. The following are the filenames:
Code:
nted.tar.gz                           ;this is the script.
nted_1.10.18-12.debian.tar.xz         24K
nted_1.10.18.orig.tar.gz              4.0M
Now, in the script I have the following line:
Code:
VERSION=${VERSION:-1.10.18_12}
As you can see the version string in the script does not match any of the strings in the filenames. Notice the mismatch between the hyphen and the underscore (18-12 and 18_12). In which of the two source files should the version number match the version number in the script? I think the script should match the number in the second file listed and I have to replace the underscore in the script by a hyphen. What do you think?

Last edited by stf92; 03-17-2020 at 11:16 AM.
 
Old 03-16-2020, 08:53 PM   #2
average_user
Member
 
Registered: Dec 2010
Location: Warsaw, Poland
Distribution: Slackware
Posts: 560

Rep: Reputation: 220Reputation: 220Reputation: 220
Why do you want to change anything? Can you build it? multimedia/nted was updated to 1.10.18_12 by B.Watson in 2018:

Code:
commit a4b56a1f7676a024e0512180c1d7746702bbb849
Author: B. Watson <yalhcru@gmail.com>
Date:   Thu Sep 6 14:55:39 2018 -0400

    multimedia/nted: Updated for version 1.10.18_12.

    Signed-off-by: B. Watson <yalhcru@gmail.com>
I don't think you should pay much attention to the version form. Template https://slackbuilds.org/templates/au...ate.SlackBuild just shows dots, anyway.
 
Old 03-16-2020, 09:43 PM   #3
upnort
Senior Member
 
Registered: Oct 2014
Distribution: Slackware
Posts: 1,893

Rep: Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162
Many SBo scripts are like that. The maintainers have a reason for doing that because often developers are not careful with how software is named and sometimes version strings conflict with Slackware package naming conventions.

Study the entire script. Notice that VERSION is later parsed into two additional variables, MAINVER and DEBVER.
 
1 members found this post helpful.
Old 03-16-2020, 09:50 PM   #4
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Quote:
Originally Posted by upnort View Post
Many SBo scripts are like that. The maintainers have a reason for doing that because often developers are not careful with how software is named and sometimes version strings conflict with Slackware package naming conventions.
Well, then what would your answer be to post #1? ("I think the script should match the number in the second file listed and I have to replace the underscore in the script by a hyphen. What do you think?").

Last edited by stf92; 03-16-2020 at 09:53 PM.
 
Old 03-16-2020, 09:55 PM   #5
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
I Just update my own when I find one that has not been (blender for example, the one that is using the self contained tarball) that takes changing the vers and some of the format for the file within the script itself, sometimes. I just fix whatever needs fixing run it then install it then go on about my day.

Last edited by BW-userx; 03-16-2020 at 09:57 PM.
 
Old 03-16-2020, 10:23 PM   #6
upnort
Senior Member
 
Registered: Oct 2014
Distribution: Slackware
Posts: 1,893

Rep: Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162Reputation: 1162
Quote:
What do you think?
The code is free/libre. Do whatever you want. I often change builds scripts to my fancy.
 
1 members found this post helpful.
Old 03-16-2020, 11:10 PM   #7
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
Quote:
Originally Posted by stf92 View Post
Well, then what would your answer be to post #1? ("I think the script should match the number in the second file listed and I have to replace the underscore in the script by a hyphen. What do you think?").
Slackware packages are required to follow a specific naming convention:

NAME-VERSION-ARCH-BUILD

The NAME is allowed to contain hyphens, but none of the other components may. Sometimes, the upstream developers' naming does not follow the Slackware convention, and in those cases you would end up with an invalid Slackware package filename, breaking Slackware package management tools. That is why it has been renamed to not match upstream exactly. I recommend you leave it as is.

Anyway, to answer your question, no, I don't think the Slackware version number should be changed to match upstream, as that would result in an invalid package name.

Last edited by montagdude; 03-16-2020 at 11:11 PM.
 
5 members found this post helpful.
Old 03-16-2020, 11:54 PM   #8
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
To give an actual example of montagdude's post, if you do decide to rename the version to contain a hyphen, the filename would be nted-1.10.18-12-x86_64-1_SBo.tgz

Slackware's package tools basically take the filename, reverse it and then start checking for hyphens. So the first hyphen it finds, it knows everything before that is the BUILD. The characters between the first and second hyphens is the ARCH, the characters between the second and third hyphens is the VERSION, and anything beyond the third hyphen is the package name. This allows package names to include hyphens without breaking the package naming scheme. So, if we were to colorize this package names in Slackware to the below, it would look like this.

NAME-VERSION-ARCH-BUILD

The normal package would be broken out like this:

nted-1.10.18_12-x86_64-1_SBo

But if we swap that underscore to a hyphen, the it now looks like this:

nted-1.10.18-12-x86_64-1_SBo

This will prevent the slack-desc from working, as it is required to match the package name and if you try and update it if 1.10.19-1 comes out, Slackware won't recognize it for upgrade since it will be trying to match the package name nted-1.10.18 against nted-1.10.19, and they obviously won't match.

This is why we keep hyphens out of versions in Slackware.
 
3 members found this post helpful.
Old 03-17-2020, 01:50 AM   #9
ehartman
Senior Member
 
Registered: Jul 2007
Location: Delft, The Netherlands
Distribution: Slackware
Posts: 1,674

Rep: Reputation: 888Reputation: 888Reputation: 888Reputation: 888Reputation: 888Reputation: 888Reputation: 888
Quote:
Originally Posted by stf92 View Post
nted_1.10.18-12.debian.tar.xz 24K
Note that this -12 is specific for Debian (and rpm too) style of packages, it - in fact - is the Debian build of the package. As package names follow a different convention in Slackware, you cannot use that - in a Slackbuild script.
In fact the number says: this is version 1.10.18, with build 12 for Debian.
In Slackware that would be nted-1.10.18-architecture-12_debian.txz
Note that I had to exchange the first _ for a - too.
 
2 members found this post helpful.
Old 03-17-2020, 11:33 AM   #10
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
I'll run the script, without touching anything and see if the resulting package works when installed. I mean, if the programs run correctly. If they do, then I won't worry about other considerations. Thanks montagdude for answering my question.

Last edited by stf92; 03-17-2020 at 11:38 AM.
 
Old 03-17-2020, 01:30 PM   #11
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Quote:
Originally Posted by average_user View Post
Why do you want to change anything? Can you build it? multimedia/nted was updated to 1.10.18_12 by B.Watson in 2018:

Code:
commit a4b56a1f7676a024e0512180c1d7746702bbb849
Author: B. Watson <yalhcru@gmail.com>
Date:   Thu Sep 6 14:55:39 2018 -0400

    multimedia/nted: Updated for version 1.10.18_12.

    Signed-off-by: B. Watson <yalhcru@gmail.com>
How did you get these data? Is 'commit' a command? I did not find it in the web. Neither in my OS (arch).
 
Old 03-17-2020, 02:40 PM   #12
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by stf92 View Post
How did you get these data? Is 'commit' a command? I did not find it in the web. Neither in my OS (arch).
This is from the changelog link for nted on SBo.
 
Old 03-17-2020, 04:05 PM   #13
stf92
Senior Member
 
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442

Original Poster
Rep: Reputation: 76
Hum... In post #7 I have both the author and his email URL. I would very much like to know how average_user got those data. He seems to have started with the MD5 checksum for one of the files. Ahhh, thanks for your illustrative posts.

Last edited by stf92; 03-17-2020 at 04:23 PM.
 
Old 03-17-2020, 04:12 PM   #14
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Quote:
Originally Posted by stf92 View Post
Hum... In post #7 I have both the author and his email URL. I would very much like to know how average_user got those data. He seems to have started with the MD5 checksum for one of the files.
After 4000 posts here on LQ, I invite you to learn about git. The graphical interface to git (cgit) will show you the commit information plus a lot more: https://git.slackbuilds.org/slackbui...d7746702bbb849
 
Old 03-17-2020, 05:33 PM   #15
average_user
Member
 
Registered: Dec 2010
Location: Warsaw, Poland
Distribution: Slackware
Posts: 560

Rep: Reputation: 220Reputation: 220Reputation: 220
Yeah I used Git, this repository specifically https://github.com/SlackBuildsOrg/slackbuilds because that is the one I send PRs to so I have it cloned locally and the following command:
Code:
git show a4b56a1f
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mismatch between OS version and Flash Plugin version? Too many Flash Plugins? drmjh Linux - Software 2 11-23-2009 06:37 PM
Use SlackBuilds.org or my own hosting to offer up SlackBuilds? hollywoodb Slackware 6 11-30-2006 08:56 PM
ABI version mismatch with server version rjpilla Ubuntu 1 10-03-2006 10:03 PM
help, gcc version and kernel version mismatch akanitkar Linux - Newbie 1 05-06-2006 07:02 AM
Kernel version Source Version mismatch after recompile chuckleberry Linux - Software 1 06-20-2005 06:37 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:39 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration