LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   installpkg question (http://www.linuxquestions.org/questions/slackware-14/installpkg-question-4175444355/)

fbr 01-06-2013 07:40 AM

installpkg question
 
Hi,

Brand new to slackware as this question will probably attest to. When I attempt to use installpkg on a tar.gz I get the following message:

Quote:

Cannot install zim-0.58.tar.gz: file does not end in .tgz, .tbz, .tlz, or .txz
Not sure what I'm supposed to do but this is a pretty common format for application tarballs, so I'm sure there must be a simple solution, but I don't know what it is.

Any help or advice will be appreciated - Thanks

Alien Bob 01-06-2013 07:47 AM

What you are trying to "install" is apparently a source tarball.
Slackware is not a from-source distribution - you need to have a binary Slackware package first, which you build out of the program's sources.

Check out the Slackware Documentation Project: http://docs.slackware.com/start to find a lot of information for the new and aspiring Slacker.
Perhaps this will explain the process of creating a Slackware package: http://docs.slackware.com/slackware:slackbuild_scripts

Eric

BCarey 01-06-2013 09:32 AM

Although I have never done this myself, my understanding is that Salix packages are backwards compatible with Slackware, so if you don't yet want to learn how to build the package on slackware you could try to use installpkg on the version/architecture appropriate zim tgz in salix repository. They also post their sources and Slackbuilds so you could use those to build your own.

Brian

knudfl 01-06-2013 10:11 AM

This zim.SlackBuild works OK with zim-0.58
https://github.com/aclemons/slackbuilds/tree/master/zim

→ Edit line 27, zim.SlackBuild to : VERSION=${VERSION:-0.58}

hitest 01-06-2013 10:23 AM

Quote:

Originally Posted by fbr (Post 4863885)
Hi,

Brand new to slackware as this question will probably attest to. When I attempt to use installpkg on a tar.gz I get the following message:



Not sure what I'm supposed to do but this is a pretty common format for application tarballs, so I'm sure there must be a simple solution, but I don't know what it is.

Any help or advice will be appreciated - Thanks

There is a utility not included with Slackware called src2pkg that will take source files and create a slackware package for you. It does not resolve dependency issues.
This may help you out.

http://distro.ibiblio.org/amigolinux/download/src2pkg/

1. Install the utility as you would any slackware package: # installpkg src2pkgpackagename
2. Set-up src2pkg # src2pkg --setup
3. Then you can create slackware packages using src2pkg in the directory where your source file is located. # src2pkg nameofsourcefile
4. Newly created slackware packages are put in /tmp

fbr 01-06-2013 01:18 PM

Ok - I read the article in the Slack Documents Project page and the attached linked tutorial package on building slackbuild scripts and it appears to me to be beyond my present capabilities. I was able to download and install src2pkg following hitest's instructions (many thanks!). However, after I installed zim I received the following error message on startup.
Quote:

bash-4.2$ zim&
[1] 20032
bash-4.2$ WARNING: Can not import 'xdg.Mime' - falling back to 'mimetypes'
WARNING: Filesystem encoding is set to ASCII or Latin1, using UTF-8 instead
ERROR: Could not find data files in path:
/home/francis/.local/share/zim /usr/share/zim /usr/share/zim /usr/local/share/zim

Try setting XDG_DATA_DIRS

[1]+ Exit 1 zim
I tried to look into XDG and it appears to be a reference to some kind of enviroment variable but I'm really not sure what action is needed at this point?

irgunII 01-07-2013 11:02 AM

You're making it more complicated that it actually is. The instructions for it all may *look* a little daunting, but it's really not, not if you actually try it. Instructions here:

*****
Open up your prefered file manager (I use krusader, but konqueror or dolphin work well enough)

Create a new directory called 'build' (w/out the quotes of course).

Open up your favorite browser

Look on slackbuilds.org for the app you're wanting.

Open that app in a new tab or window

Download the tarball that is underneath 'Download Slackbuild:'

Get to your 'build' directory in the file manager and you'll see the tarball you just downloaded

Right-click on that tarball and choose 'extract here'

Delete that tarball (it's very small file-size so you can get it any time easily even with dial-up)

Now download the source tarball underneath 'Source Downloads:' and put it into the directory you just extracted

Open up konsole and type 'su -' (no quotes, su <space> dash) and hit enter, then enter your root password and hit enter again

CD to your directory of the app (for instance 'cd /home/you/build/new-app and hit enter)

Now type 'ls' (this will 'list' all that is in that directory)

You want to now type './new-app.SlackBuild' (no quotes and 'new-app' being the real name of the app)

Hit enter and it will begin building your new app.

When it's done, type 'installpkg /tmp/new-app.blahblah.txz' (or whatever it is, no quotes)

Your new app is now installed and awaiting your use
*****

Reading all that and the actual *doing* of it all is a huge difference. 'Doing' it is far faster, and once you've done it a few times, it's even simpler and you'll begin to use your own shortcuts to make it even faster. That is the way *I* do the builds. There may be faster/simpler/other ways of course, but that way above works for *me* and I'm used to it and I'm a two-finger typer and have an extremely poor memory (it's also why I can't become a programmer :( ) and I do not know even how to write a simple bash script...so if I can do it, you can too.

fbr 01-07-2013 04:32 PM

Quote:

Look on slackbuilds.org for the app you're wanting.

Open that app in a new tab or window

Download the tarball that is underneath 'Download Slackbuild:'
The application I built (zim) is not available through slackbuilds.org. I installed a source tarball using src2pkg. Other than the slackbuild 'knudfl' mentions in his post I have not run into any other slackbuilds for zim.

I have since removed my previous install. My next attempt will be to grab the slackbuild knudfl refers to and try to install using the procedure you posted. Hopefully, I won't receive the error message this time.

& my thanks for your explanation.

knudfl 01-07-2013 09:43 PM

Quote:

Other than the slackbuild 'knudfl' mentions in his post
I have not run into any other slackbuilds for zim.
The second hit with Google .. zim slackbuild .. ( 7,000 hits )
is another version, but requires an "extra" build tool : 'Requiredbuilder'.
http://vlcore.vectorlinux.com/src/ve...zim.SlackBuild


.


All times are GMT -5. The time now is 02:39 PM.