LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Building your own slackware packages (https://www.linuxquestions.org/questions/slackware-14/building-your-own-slackware-packages-328317/)

CrEsPo 05-29-2005 03:31 PM

Building your own slackware packages
 
Where can I find a good guide that can direct me in creating my own slackware packages? This will be my first creation so I'm looking for something that goes into a little bit of detail for me to understand what is going on.

I usually install from source, but after having slackware installed for a little bit my tar directory is getting to be a huge mess. I can only imagine the pain down the line when a bunch of updates come out one after another.

reddazz 05-29-2005 03:46 PM

You can use checkinstall. Take a look at the documents section on the website, the readme file is a really good guide to get you started. You can also read the documentation available at linuxpackages.

cathectic 05-29-2005 04:46 PM

Alternatively, you could read through some of Pat's SlackBuild scripts (look under /source) to see how he builds packages from source.

win32sux 05-29-2005 09:52 PM

stay away from checkinstall... nothing beats making your own build scripts, like patrick does... and like cathectic says, reading patrick's scripts is a GREAT way to understand how things are done...

at linuxpackages.net there's some documentation, for example:

http://www.linuxpackages.net/howto.p...=Package+Howto

http://www.linuxpackages.net/howto.p...erfect+Package

reddazz 05-29-2005 10:11 PM

Quote:

Originally posted by win32sux
stay away from checkinstall... nothing beats making your own build scripts, like patrick does... and like cathectic says, reading patrick's scripts is a GREAT way to understand how things are done...

Can you give more info about why we should stay away from checkinstall. It works fine for personal packages so I don't see anything wrong with using it.

CrEsPo 05-29-2005 10:12 PM

Thanks for the tips guys. I just realized I'm going to have a very busy week.

Discrete and english test tomorrow, calculus test and soccer practice tuesday, break on wedsnday, chemistry test and soccer practice thursday, and a university program orientation friday :(.

So I think the only time I'll have to try this out is probably next weekend :(. Ugh, I got my hopes up of trying it out soon too :(.

slackMeUp 05-29-2005 10:35 PM

I'd go with checkinstall... I've never had a problem with it.

Sure you could make your own build scripts, like pat, but checkinstall is dead easy to use.

win32sux 05-29-2005 11:37 PM

Quote:

Originally posted by reddazz
Can you give more info about why we should stay away from checkinstall. It works fine for personal packages so I don't see anything wrong with using it.
i suggested he should stay away from checkinstall because of this:
Quote:

Originally posted by CrEsPo
I'm looking for something that goes into a little bit of detail for me to understand what is going on.
checkinstall does NOT fit that description... OTOH, reading the official build scripts and then making your own DOES fit that description... especially if the person already has some experience compiling and installing software from source:
Quote:

Originally posted by CrEsPo
I usually install from source
considering all of this, i feel it would be counter-productive to go for an automated package builder like checkinstall...


jong357 05-29-2005 11:40 PM

I'm with win32sux on this... If it works for you then fine. I, however, always have problems with it. For some reason it always resets my hostname to "f".... That pretty much renders your system useless. Nothing will open at all. It's either reboot or rerun the startup script that sets the hostname. Ofcourse, if you happen to not already have a terminal up, even thats not an option because the terminal won't open. You can't do anything but reboot. Maybe you could fix it from another VC....

It also likes to louse up symlinks on me. I'll get doinst.sh's like this:

Code:

( cd sr/lib ; rm -rf blah )
( cd sr/lib ; ln -sf blah blah )
( cd tc/samba ;

You get the point. It cuts of the beginning directory by a letter or two. That results in a bunch of broken symlinks in /

Also, what happens if the package drops a config file on you. One that you already have and spent some time tweaking out? It just gets replaced. So, your going to explodepkg on it, rename the config to .new and add quite a few lines to doinst.sh... If your going to do all that, you should have just used makepkg in the first place. Actually, even thats not an option because by the time the package is made, checkinstall already hosed your config file on the system.

Or what if the actuall source code install NEEDS to run additional commands in order to register itself with your system such as scrollkeeper, gconftool, gdk-pixbuf-query-loaders or countless other binaries designed to "activate" your new software? Checkinstall isn't going to do that. Not if you give the slack-pak to someone and tell them to install it. The only reason why checkinstall works in that regard is because it actually installs the software first, then installs to a package directory. So, if you ever use those slak-paks on a different system, they are bogus packages that won't work... I could go on and on actually...

I just think it's a pretty shoddy way to handle things. Pat kinda hints at the same thing on his FTP site in the readme. Sure, it's usefull if it decides to work for you. Otherwise it's not worth much... It just doesn't feel right using it either, even if it did work. I don't like anything automated on a slackware box. Slack runs really stable and I prefer to make packages by hand with 'makepkg' just so I know exactally what is happening. Once you start giving up control and trusting things like checkinstall, swaret, slapget et. all, your just asking for trouble. Thats the main reason why I switched to Slack from Redhat, Suse, Mandrake ect... I got tired of the OS devs trying to make software 'easy' and automated. In the process, it's easy to screw things up. Actually, that's the whole reason why I stopped using Windows.

Well, anyway.... That's my reason/s... :D Go ahead and try checkinstall and if it works, then great. You still might want to try the "proper" way of making packages at some point even if checkinstall does end up working for you.. Otherwise, your not really using Slack... If you don't take into account ALL aspects of package management, you might as well start installing RPM's on Slackware... ;) Thats my take on it anyways...

win32sux 05-29-2005 11:45 PM

Quote:

Originally posted by jong357
It just doesn't feel right using it either, even if it did work. I don't like anything automated on a slackware box. Slack runs really stable and I prefer to make packages by hand with 'makepkg' just so I know exactally what is happening. Once you start giving up control and trusting things like checkinstall, swaret, slapget et. all, your just asking for trouble.
i agree with you 100% bro... ;)

win32sux 05-29-2005 11:48 PM

Quote:

Checkinstall? Swaret? A jedi craves not these things.

jong357 05-30-2005 12:04 AM

I'm a slackware purist if you will. I just hate to see people getting complacent with such a core concept as packages.... Makes me sad... :( I purposefully stay away from the slaptget posts cause I wanna say, "DUH!!!! What did you think was going to happen?".. ;) Don't anyone get mad at me here.. If you like checkinstall then thats great. It's your system and you can do whatever works for you. This is almost a vi versus emacs thing... I can feel it in the air...

I'm against Dropline Gnome for the same reasons I stated earlier... So, I build my own Gnome now that Pat chucked it. But yea, the linuxpackages.net link is probably a decent starting point.

http://www.linuxpackages.net/howto.p...erfect+Package

But actually, I think this link is the best place to learn about how to make packages..

ftp://ftp.slackware.com/pub/slackware/slackware_source/ ;)

After looking at a few build scripts, it doesn't take a rocket scientist to understand what is happening with them.

Ops.. Both those links are listed already... My mom always told me that using 'makepkg' would make me go blind.... :tisk:

reddazz 05-30-2005 12:43 AM

I simply wanted justification for staying away from checkinstall, but so far nobody has convinced me of the technical demerits of using it. What win32sux and jong357 have expressed in their posts seems to be just personal preference. If automated tools work fine for a particular purpose, I see no harm in using them regardless of the Linux distribution being used.

jong357 05-30-2005 12:57 AM

Well, I stay away from checkinstall not because of personal prefrence, but because it absolutlely does NOT work in the slightest, as I have already stated. But yea, if you find something easy and enjoyable to use because it's automated then checkinstall fits that bill quite nicely. Again... IF it works in the first place....

Berhanie 05-30-2005 01:35 AM

Quote:

Can you give more info about why we should stay away from checkinstall. It works fine for personal packages so I don't see anything wrong with using it.
redazz, try this:
Code:

find /usr/man -type f -regex '.*[^z]$'
If you've used checkinstall in the past, you're probably going to find a lot of ungzipped man pages (along with gzipped versions of the same files).

Also,
Code:

ls -ld /bin /sbin /usr/bin /usr/sbin
Are the ownerships root:bin or root:root?


All times are GMT -5. The time now is 02:09 AM.