LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   Question about installing a package manager (https://www.linuxquestions.org/questions/linux-from-scratch-13/question-about-installing-a-package-manager-743247/)

ReyJavikVI 07-27-2009 08:29 PM

Question about installing a package manager
 
I've just started chapter 6. I decided I'll install dpkg/apt instead of coming up with my own system. Should I do that now or when everything is in place? I'm using this hint, but specific tips or instructions would be helpful too.

weibullguy 07-29-2009 03:03 PM

Package managers such as dpkg or RPM keep a database of installed packages. Based on my experience playing around with packages managers on my CLFS systems, the base system packages need to be in that database or the package manager attempts to pull them in later to satisfy dependencies. Scanning the hint, it looks like the intent is to install dpkg after building the base system. However, it also looks like the intent is really to create your own deb files rather than use pre-built deb packages from the internet. There may be a discussion about convincing dpkg that base system packages are installed. I just may not have seen it.

ReyJavikVI 07-29-2009 04:33 PM

I'm sorry, but I didn't really understand what you said. Should I install the package manager before or after chapter 6?

And what's the base system? Is it the tools, or is it everything installed in part III?

weibullguy 07-30-2009 01:53 AM

I guess you're going to make me read the entire hint. When you're finished with the LFS book, you have a base system. At this point implement the hint. When you're finished with the hint, you can start installing packages from BLFS using dpkg to create .debs.

ReyJavikVI 07-30-2009 10:07 AM

Sorry, it's not that I want to make you read the entire hint, it's just that I didn't exactly understand what "base system" meant. Thanks for your help.

ProtoformX 08-02-2009 11:06 PM

Quote:

Originally Posted by ReyJavikVI (Post 3625568)
Sorry, it's not that I want to make you read the entire hint, it's just that I didn't exactly understand what "base system" meant. Thanks for your help.

I usually do this at the start of chapter 6 have you have charooted into the $LFS system, I install pkgtool though, I love it so much! but lets not go into package manager wars.

I do this at the beginning of chapter 6 because it allows me to build a database of even the base system, so it i need to change one minor thing its easy to rebuild a known package cause i can just uninstall that one and not worry about what flags i used to build it with.

ReyJavikVI 08-03-2009 08:24 AM

I thought the same thing, but apparently to install dpkg you have to finish LFS first. Oh well.

potuz 08-06-2009 06:15 PM

I don't think you need to finish LFS, that's a matter of taste. You can start installing pkgtool as soon as you chrooted. I'd rather have a stable and checked base system (weibullguy's answer) before adding anything else though.

Remember to add (e)glibc, gcc and such to your package manager "ignore" list, importing a prebuilt c library into a LFS system defeats the purpose of building your own :)

R.

sanitynotvanity 08-13-2009 10:08 AM

even better...dont have a package manager! LoL.

thats what i did. tho mainly because i couldn't decide how to implement it. Most (but not all) of the packages have the ability to be uninstalled if you still have the source.

as its LFS you will need the source code to install anything anyway...

ProtoformX 08-13-2009 10:28 AM

Quote:

Originally Posted by sanitynotvanity (Post 3641957)
even better...dont have a package manager! LoL.

thats what i did. tho mainly because i couldn't decide how to implement it. Most (but not all) of the packages have the ability to be uninstalled if you still have the source.

as its LFS you will need the source code to install anything anyway...

This is true, but if you wanted to build your own distro off of LFS then you will still require a package manager.

sanitynotvanity 08-13-2009 10:32 AM

Quote:

Originally Posted by ProtoformX (Post 3641981)
This is true, but if you wanted to build your own distro off of LFS then you will still require a package manager.

Good point!

ReyJavikVI 08-14-2009 09:56 PM

When I try to install apt using dpkg, I get that the package architecture doesn't match the system's (I don't have the exact message right now). I'm sure the package and the system are both i386, but the odd thing is that the error message didn't say my system arch. It said something like this:
Code:

package architecture doesn't match system ()
Running uname -a says that I am using i686.

ReyJavikVI 08-16-2009 01:38 PM

OK, I found out that I can use --force-architecture and install dpkg through dpkg and then the problem should be solved. But it seems that it doesn't recognize the libraries I installed from source. For example, it tells me that it needs coreutils installed, and it's obviously installed, just not from a .deb. How to solve this?

ReyJavikVI 08-22-2009 08:07 AM

Anyone?

weibullguy 08-23-2009 02:02 PM

Like *all* package managers dpkg keeps a database of installed packages. I believe dpkg uses a text file for this purpose. Like I said in my other post, you need to add the base system packages to this database so dpkg doesn't try to pull in these for dependencies. I don't use dpkg, never have, and probably never will. I'm sure if use the great Google, you'll be bale to find a discussion of how to edit this database.


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