Page 1 of 2

How to make slackware repo?

Posted: 03 May 2014, 07:52
by freestyler
Just wondering what is required to make a slackware repository? Is there some sort of index file(s)?
Also how does USM determine required dependencies?

Re: How to make slackware repo?

Posted: 03 May 2014, 18:50
by brokenman
I think alienbob has a script to create a slackware repo. Take a look at any slackware repo to see the file layout.

What is important for USM is the PACKAGES.TXT and MANIFEST files which are a record of all files contained within the repo. USM resolves dependencies by running 'ldd' against executables and seeing what is not found. It then searches through the database files (some of these database files do not exist in slackware repo's, they are created by me) until it finds the mother of the missing library. It loops through this process until all mother packages are found, no mother package is found or someother error is encountered.

Re: How to make slackware repo?

Posted: 04 May 2014, 01:19
by freestyler
Thanks!
I gotta say I'm really impressed with USM, Its a really nice piece of code and Ive really enjoyed watching it evolve. Hats off!
off the topic..
I noticed that gtk_terminal only gets used for updating databases, how about:

Code: Select all

export GTK_TERMINAL='<window window_position="1" title="'$(gettext "Updating")'" allow-shrink="false" icon-name="usm">
That way it gives a more integrated look and feel :)
Out of curiousity, what does gettext do?

Re: How to make slackware repo?

Posted: 04 May 2014, 14:22
by brokenman
Thanks Freestyler.

I'll take a look at the code for the terminal. The problem was that there is no real usable tailbox in gtkdialog where the window scrolls automatically as the text is shown. For this reason I went for the terminal display which also meant I could reuse the code from the CLI part instead of rewriting it.

gettext is a package that allows for i81n (internationalization) support ... meaning translations to different languages. Instead of a direct 'echo' it first goes via gettext which checks which LOCALE you are using and gets the text from /usr/share/locales instead. I've left the files intact for Japanese in the slackware package.

Re: How to make slackware repo?

Posted: 04 May 2014, 16:01
by freestyler
ahh cool, Ill defiantly remember to use gettext for future coding.

Thanks for pointing me in the alien bob direction, really helped me out, found some other useful stuff too.
I got a sweet slackware repo on the way. I spent all day working on scripts to compile the entire SBo database for Porteus and finally got a real nice setup, still tweaking the compilation order. I'll share the scripts once ive finished testing it, there is almost 3500 packages in my queue and I want to make sure nothing get's missed. When its finished you will be able to clone the slackbuild database, download the source, build and install required dependencies in correct order from one command.
Ive also started pumping out my own slackbuild scripts for less common packages which is a bit of a pain but will make it really easy for the future.
Hopefully it will come in handy one day.

3 or 4 more computers would be handy...

Re: How to make slackware repo?

Posted: 05 May 2014, 14:39
by brokenman
Sounds awesome. Also sounds like a lot of work.

If it helps any take a look in USM /var/usm/slacky/ and you will find LIBS.TXT and OPTIFEST. OPTIFEST (optimized manifest) is a record of all the libraries that a package contains. LIBS.TXT is a record of all the libraries a package needs.
These two are the key to dep resolution. It would be better if everybody followed the slacky standard and included a line each slackbuild called REQUIRED: but i don't think this will ever happen.

Re: How to make slackware repo?

Posted: 05 May 2014, 15:53
by freestyler
Yeah its quite a bit of work but it's mostly automated now, I'm going through one category at a time to make sure everything gets built properly and in the right order. I ended up modifying spopkg and using queue files. Its at the point where I type in one command and wait a few hours and check the logfile for errors, then correct them/make slackbuild for any missing packages.

What would be the best way to make LIBS.TXT and OPTIFEST? do you have a script?

Re: How to make slackware repo?

Posted: 05 May 2014, 20:15
by brokenman
My system is also automated. It is a set of scripts that do an rsync of the repo and then generate necessary files if the repo has any changes. I can upload the script set somewhere if you want it.

Re: How to make slackware repo?

Posted: 06 May 2014, 01:32
by freestyler
That would be so awesome!

Re: How to make slackware repo?

Posted: 06 May 2014, 05:25
by freestyler
I feel like Scrooge McDuck but instead of money, I'm bathing in slackware packages

Re: How to make slackware repo?

Posted: 06 May 2014, 05:52
by freestyler
Image

Re: How to make slackware repo?

Posted: 06 May 2014, 14:37
by brokenman
https://www.dropbox.com/sh/qku8qbrpsqt1ap0/t6cTkFLtVn

I have all slackware repos cloned onto a local HD. The first script I run is the check-changelog2.sh script. The paths are custom for my machine.

Re: How to make slackware repo?

Posted: 06 May 2014, 15:17
by freestyler
Thanks for helping out and sharing your scripts brokenman, I really appreciate it.

Re: How to make slackware repo?

Posted: 07 May 2014, 05:50
by freestyler
Just tested the scripts and they work great, The only problem is that it reads every file like .md5 etc. I will change it so it only reads the slackware packages
Thanks again.

Re: How to make slackware repo?

Posted: 07 May 2014, 11:04
by ponce