LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   sbopkg, is there a way to rename the tarballs downloaded from info file specifications? (https://www.linuxquestions.org/questions/slackware-14/sbopkg-is-there-a-way-to-rename-the-tarballs-downloaded-from-info-file-specifications-4175650217/)

Geist 03-15-2019 03:31 AM

sbopkg, is there a way to rename the tarballs downloaded from info file specifications?
 
Going for a git build of a package but I don't wanna rename everything to 40sd0f8sw0fweorwoefu20rjsof2eu02ruw0rfsldf230igf-git when it's still the same major/minor number, but merely a nightly build.

So, a way to rename the tarball to software-2.0.0.tar.gz instead of software-2.0.0awwjlasdjflsahlsdjflasdfsf-git.tar.gz would be nice.

I guess I could technically rename the file in the slackbuild itself but I thought I'd ask for an info file URL solution first.

ponce 03-15-2019 03:35 AM

maybe it's me, but I'm not getting it: can you please make an actual example?

Geist 03-15-2019 03:43 AM

Alright, let's take Blender as an example.

info file:
Code:


PRGNAM="Blender"
VERSION="2.79b"
HOMEPAGE="http://blender.org"

DOWNLOAD="http://download.blender.org/source/blender-2.79b.tar.gz"

#nightly git
#https://builder.blender.org/download/blender-2.79-57b5852bc8b8-linux-glibc224-x86_64.tar.bz2

MD5SUM="cef9a203857dc65076e05c41fc7a7d03"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="ffmpeg jack-audio-connection-kit opencollada python-requests valgrind numpy3 SDL2 openimageio freealut"
MAINTAINER="Christoph Willing"
EMAIL="chris.willing@linux.com"

If I were to put this url into the DOWNLOAD variable, then what sbopkg would download would be named "blender-2.79-57b5852bc8b8-linux-glibc224-x86_64.tar.bz2"
But the slackbuild usually expects the tarball to be progname-version, in this case it's a much more complicated name.

Now, some slackbuilds deal with that (like the Blender one), but this is just an example cause I'm currently dealing with some blender problems regarding python, it seems (GUI is all messed up, lots of not found bits and pieces)

I just wished for this functionality before, hence me asking, Blender is just an example, the build file accepts it happily, but in the past some build files didn't.

ponce 03-15-2019 03:57 AM

this example surely won't work, as you are trying to substitute a tarball with sources with one containing a binary.

but I suppose the answer to your question is to create a local repository and modify in it all the slackbuilds that you want to customize accordingly, and not just the DOWNLOAD variable in the *.info file: you need to modify, at least, also the MD5SUM, and the VERSION (both in the *.info file and the *.SlackBuild)...
also you may need to edit additional things in the SlackBuild: usually a version-bump is ok but it may happen that something changes between one version of the software and the other so that the SlackBuild may need some intervention (there's no general rule, it depends on the software).

chris.willing 03-15-2019 04:02 AM

Quote:

Originally Posted by Geist (Post 5974071)
Alright, let's take Blender as an example.

info file:
Code:


PRGNAM="Blender"
VERSION="2.79b"
HOMEPAGE="http://blender.org"

DOWNLOAD="http://download.blender.org/source/blender-2.79b.tar.gz"

#nightly git
#https://builder.blender.org/download/blender-2.79-57b5852bc8b8-linux-glibc224-x86_64.tar.bz2

MD5SUM="cef9a203857dc65076e05c41fc7a7d03"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="ffmpeg jack-audio-connection-kit opencollada python-requests valgrind numpy3 SDL2 openimageio freealut"
MAINTAINER="Christoph Willing"
EMAIL="chris.willing@linux.com"

If I were to put this url into the DOWNLOAD variable, then what sbopkg would download would be named "blender-2.79-57b5852bc8b8-linux-glibc224-x86_64.tar.bz2"
But the slackbuild usually expects the tarball to be progname-version, in this case it's a much more complicated name.

Now, some slackbuilds deal with that (like the Blender one), but this is just an example cause I'm currently dealing with some blender problems regarding python, it seems (GUI is all messed up, lots of not found bits and pieces)

I just wished for this functionality before, hence me asking, Blender is just an example, the build file accepts it happily, but in the past some build files didn't.

What you're trying to do with that example won't work because the Blender (note capital B spelling) SlackBuild is intended to build blender from a source code tarball, whereas your download url is for a prebuilt blender.

You'd be better off modifying the SlackBuild for blender (note all lower case spelling) which repackages a prebuilt download.

chris

Geist 03-15-2019 04:04 AM

@Ponce:
Oops, well, it was about the process anyway, and I guess there's no quick hacky shortcut then. Thanks~!

@chris.willing:
Yeah, that's what I ended up doing. Thank you, too.


All times are GMT -5. The time now is 11:21 AM.